« t/lib/Test/Simple/sample_tests/death.plx
↑ Summary
t/lib/Test/Simple/sample_tests/death_with_handler.plx »
| 1 | 1 | require Test::Simple; | |
| 2 | 1 | ▶ | use Carp; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 3 | |||
| 4 | 1 | push @INC, 't/lib'; | |
| 5 | 1 | require Test::Simple::Catch; | |
| 6 | 1 | my($out, $err) = Test::Simple::Catch::caught(); | |
| 7 | |||
| 8 | 1 | Test::Simple->import(tests => 5); | |
| 9 | |||
| 10 | 1 | ok(1); | |
| 11 | 1 | ok(1); | |
| 12 | 1 | ok(1); | |
| 13 | 1 | eval { | |
| 14 | 1 | die "Foo"; | |
| 15 | }; | ||
| 16 | 1 | ok(1); | |
| 17 | 1 | eval "die 'Bar'"; | |
| 18 | 1 | ok(1); | |
| 19 | |||
| 20 | 1 | eval { | |
| 21 | 1 | croak "Moo"; | |
| 22 | }; | ||