X-Git-Url: http://git.vpit.fr/?a=blobdiff_plain;f=t%2F12-destroy.t;h=5fdc85339f961bf611c6fe354b30b24afaf5cbda;hb=HEAD;hp=48217413507919fcae3c54859f228bc5f4ba52e2;hpb=01ee034648a5f1116ca1233b7f987607f0b4576c;p=perl%2Fmodules%2FVariable-Temp.git diff --git a/t/12-destroy.t b/t/12-destroy.t index 4821741..5fdc853 100644 --- a/t/12-destroy.t +++ b/t/12-destroy.t @@ -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;