Test-Expander/t/Test/Expander/throws_ok.t

17 lines
390 B
Perl
Raw Normal View History

2021-11-01 17:16:06 +01:00
#!/usr/bin/env perl
use v5.14;
use warnings
FATAL => qw(all),
NONFATAL => qw(deprecated exec internal malloc newline once portable redefine recursion uninitialized);
use Test::Builder::Tester tests => 1;
use Test::Expander;
my $title = 'execution';
test_out("ok 1 - $title");
my $expected = 'DIE TEST';
throws_ok(sub { die($expected) }, $expected, $title);
test_test($title);