Skip to content

Commit efa9610

Browse files
committed
typed exceptions for PRE/POST failures
1 parent ba26d03 commit efa9610

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

S32-exceptions/misc.t

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -175,4 +175,7 @@ throws_like 'constant * = 3;', X::Syntax::Missing, what => /constant/;
175175

176176
throws_like 'class A {...}; grammar B { ... }', X::Package::Stubbed, packages => <A B>;
177177

178+
throws_like 'my sub a { PRE 0 }; a()', X::Phaser::PrePost, what => 'Precondition', condition => /0/;
179+
throws_like 'my sub a { POST 0 }; a()', X::Phaser::PrePost, what => 'Postcondition', condition => /0/;
180+
178181
done;

0 commit comments

Comments
 (0)