Intermediate commit prior to radical file format change
[dbsrgits/DBM-Deep.git] / t / 28_transactions.t
CommitLineData
fee0243f 1use strict;
2use Test::More tests => 4;
3use Test::Exception;
4use t::common qw( new_fh );
5
6use_ok( 'DBM::Deep' );
7
8my ($fh, $filename) = new_fh();
9my $db = DBM::Deep->new(
10 file => $filename,
11);
12
13$db->{x} = 'y';
14is( $db->{x}, 'y' );
15$db->begin_work;
16$db->{x} = 'z';
17is( $db->{x}, 'z' );
18$db->rollback;
19is( $db->{x}, 'y' );
20
21# Add a commit test using fork