X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2F22_internal_copy.t;h=c2ed42aa17b1fae3f8c1cc1d13e54e9d34f72fc2;hb=56fef624741395b3db3fbd62d4fa2f2aaec590de;hp=e75ac0c92cf18409463f6e61e1864d3eff32c305;hpb=98ac82afade6822238f9a0aee8900bc9365096e3;p=dbsrgits%2FDBM-Deep.git diff --git a/t/22_internal_copy.t b/t/22_internal_copy.t index e75ac0c..c2ed42a 100644 --- a/t/22_internal_copy.t +++ b/t/22_internal_copy.t @@ -3,12 +3,11 @@ ## use strict; use Test::More tests => 13; -use File::Temp qw( tempfile tempdir ); +use t::common qw( new_fh ); use_ok( 'DBM::Deep' ); -my $dir = tempdir( CLEANUP => 1 ); -my ($fh, $filename) = tempfile( 'tmpXXXX', UNLINK => 1, DIR => $dir ); +my ($fh, $filename) = new_fh(); my $db = DBM::Deep->new( $filename ); ## @@ -49,7 +48,7 @@ is( $db->{copy}{subkey3}, 'subvalue3', "After the second copy, we're still good" my $max_keys = 1000; -my ($fh2, $filename2) = tempfile( 'tmpXXXX', UNLINK => 1, DIR => $dir ); +my ($fh2, $filename2) = new_fh(); { my $db = DBM::Deep->new( $filename2 );