Debian Codegraph @

t2/exception.t

raw
1 use Test2::V0;
2 # HARNESS-DURATION-SHORT
3
4 my $file = __FILE__;
5 my $line = __LINE__ + 1;
6 sub throw { die("xxx") };
7
8 is(
9 dies { throw() },
10 "xxx at $file line $line.\n",
11 "Got exception as expected"
12 );
13
14 done_testing;