X-Git-Url: http://git.vpit.fr/?a=blobdiff_plain;f=t%2F35-stash.t;h=2dd9f44d8de1140239f6728648ff9ee2d05abd5a;hb=ae89b589d2187cf0ed57bbb6132b9d4a8da29abb;hp=d8b8168ac6e79e1b8036896dbcd71b242eb4fe2a;hpb=b30ad18085c2c1d922eff05ee4801c38ad465807;p=perl%2Fmodules%2FVariable-Magic.git diff --git a/t/35-stash.t b/t/35-stash.t index d8b8168..2dd9f44 100644 --- a/t/35-stash.t +++ b/t/35-stash.t @@ -96,7 +96,7 @@ cast %Hlagh::, $wiz; is $@, "ok\n", 'stash: function calls compiled fine'; is_deeply \%mg, { fetch => \@calls, - store => ("$]" < 5.011002 ? \@calls : [ map { ($_) x 2 } @calls ]), + store => ("$]" < 5.011_002 ? \@calls : [ map { ($_) x 2 } @calls ]), }, 'stash: function calls'; } @@ -215,6 +215,10 @@ cast %Hlagh::, $wiz; { local %mg; + my @expected_stores = qw; + @expected_stores = map { ($_) x 2 } @expected_stores if "$]" < 5.017_004; + push @expected_stores, 'nevermentioned' if "$]" < 5.017_001; + eval q{ package Hlagh; undef &nevermentioned; @@ -223,11 +227,7 @@ cast %Hlagh::, $wiz; }; is $@, '', 'stash: delete executed fine'; - is_deeply \%mg, { - store => [ - qw - ], - }, 'stash: delete'; + is_deeply \%mg, { store => \@expected_stores }, 'stash: delete'; } END { @@ -296,7 +296,7 @@ $_ => sub { CB } qw); -my $uo_exp = "$]" < 5.011002 ? 2 : 3; +my $uo_exp = "$]" < 5.011_002 ? 2 : 3; $code .= ', data => sub { +{ guard => 0 } }';