5 use Test::More tests => 2;
6 use t::common qw( new_fh );
10 my ($fh, $filename) = new_fh();
11 my $db = DBM::Deep->new( $filename );
14 # Create structure in memory
19 array1 => [ "elem0", "elem1", "elem2" ],
21 subkey1 => "subvalue1",
22 subkey2 => "subvalue2"
29 $db->import( $struct );
33 # Make sure everything is there
36 ($db->{key1} eq "value1") &&
37 ($db->{key2} eq "value2") &&
39 ($db->{array1}->[0] eq "elem0") &&
40 ($db->{array1}->[1] eq "elem1") &&
41 ($db->{array1}->[2] eq "elem2")
44 ($db->{hash1}->{subkey1} eq "subvalue1") &&
45 ($db->{hash1}->{subkey2} eq "subvalue2")