Skip to content

Commit

Permalink
Test default message in Failure.new without $! set.
Browse files Browse the repository at this point in the history
  • Loading branch information
skids committed Oct 11, 2015
1 parent 552fa60 commit db83a45
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion S04-exceptions/fail.t
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,15 @@ use v6;

use Test;

plan 27;
plan 28;

# L<S04/Exceptions/The fail function>

given (Failure.new()) {
.defined;
is .exception.message, "Failed", 'Default message for Failure is "Failed" without $!';
}

{
# "use fatal" is not standard, so we don't have to disable it here
my $was_after_fail = 0;
Expand Down

0 comments on commit db83a45

Please sign in to comment.