Skip to content

Commit

Permalink
Tweaks for PR#475 (new Exception code.)
Browse files Browse the repository at this point in the history
Tweak one test that was expecting .payload to behave like .message
Comment out another that checks an error on something that cannot fail anymore
  (unless someone can figure out a way to make it.)
  • Loading branch information
skids committed Jul 22, 2015
1 parent bcc7651 commit c2a8e0e
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
12 changes: 9 additions & 3 deletions S04-exceptions/fail.t
Expand Up @@ -2,7 +2,7 @@ use v6;

use Test;

plan 27;
plan 26;

# L<S04/Exceptions/The fail function>

Expand Down Expand Up @@ -104,8 +104,14 @@ plan 27;

# RT #115436
{
throws-like 'Failure.new("foo").()', X::TypeCheck,
"type check for creating Failure object with '.new' (1)";
# We now allow more things in Failure.new than when the original RT
# was filed.
#
# Leaving this here in case anyone can figure out some esoteric way to
# get an X::TypeCheck when Failure.new takes almost any arglist
# throws-like 'Failure.new("foo").()', X::TypeCheck,
# "type check for creating Failure object with '.new' (1)";

}

# vim: ft=perl6
2 changes: 1 addition & 1 deletion S06-macros/unquoting.t
Expand Up @@ -82,7 +82,7 @@ plan 6;
};
my $cookies;
throws-like { $cookies!!; }, Exception,
payload => 'Null check failed for $cookies';
message => 'Null check failed for $cookies';
}

# vim: ft=perl6

0 comments on commit c2a8e0e

Please sign in to comment.