Variable-Magic
view release on metacpan or search on metacpan
die "tomato";
}};
like $@, expect('tomato', undef, "\nBEGIN.*"),
'die in BEGIN in eval triggers hints hash destructor';
SKIP: {
my $count = 1;
my ($stat, $out, $err) = capture_perl <<' CODE';
use Variable::Magic qw<wizard cast>; { BEGIN { $^H |= 0x020000; cast %^H, wizard free => sub { die q[cucumber] } } }
CODE
skip CAPTURE_PERL_FAILED($out) => $count unless defined $stat;
like $err, expect('cucumber', '-e', "\nExecution(?s:.*)"),
'die in free callback at compile time and not in eval string';
--$count;
}
# Uvar
SKIP:
( run in 1.321 second using v1.01-cache-2.11-cpan-49f99fa48dc )