Ready for 0.01
[p5sagit/B-Hooks-EndOfScope-WithFallback.git] / t / 01-eval.t
CommitLineData
58b07c77 1use strict;
2use warnings;
4befcbc3 3use Test::More;
58b07c77 4
4befcbc3 5use B::Hooks::EndOfScope::WithFallback;
58b07c77 6
7our $called;
8
9sub foo {
10 BEGIN { on_scope_end { $called = 1 } }
11
12 # uncomment this to make the test pass
13 eval '42';
14}
15
16BEGIN {
17 ok($called, 'callback invoked');
18}
4befcbc3 19
20done_testing;