]> git.vpit.fr Git - perl/modules/Variable-Temp.git/blobdiff - t/12-destroy.t
Use set_temp() in tests instead of temp()
[perl/modules/Variable-Temp.git] / t / 12-destroy.t
index 48217413507919fcae3c54859f228bc5f4ba52e2..5fdc85339f961bf611c6fe354b30b24afaf5cbda 100644 (file)
@@ -3,7 +3,7 @@
 use strict;
 use warnings;
 
-use Variable::Temp 'temp';
+use Variable::Temp 'set_temp';
 
 use Test::More tests => 16;
 
@@ -22,7 +22,7 @@ my $x_temp2_is_destroyed = 0;
  });
  is $x_is_destroyed, 0;
 
temp $x = VPIT::TestHelpers::Guard->new(sub {
set_temp $x => VPIT::TestHelpers::Guard->new(sub {
   is $x_is_destroyed,       0;
   is $x_temp2_is_destroyed, 1;
   ++$x_temp1_is_destroyed;
@@ -31,7 +31,7 @@ my $x_temp2_is_destroyed = 0;
  is $x_temp1_is_destroyed, 0;
  is $x_temp2_is_destroyed, 0;
 
temp $x = VPIT::TestHelpers::Guard->new(sub {
set_temp $x => VPIT::TestHelpers::Guard->new(sub {
   is $x_is_destroyed,       0;
   is $x_temp1_is_destroyed, 0;
   ++$x_temp2_is_destroyed;