Skip to content

Commit

Permalink
Update 05-messages/03-errors.t simpler and clearer tests for RT#13223…
Browse files Browse the repository at this point in the history
…8 unclosed $< .
  • Loading branch information
ronaldxs committed Apr 8, 2018
1 parent 27e77c8 commit a2a6aad
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions t/05-messages/03-errors.t
Expand Up @@ -79,15 +79,13 @@ subtest 'unclosed hash quote index operator <> message' => {
plan 2;
throws-like "\n\nsay \$<\n\n", X::Comp::AdHoc,
'good error message for unclosed <> hash operator',
message => /:i[:s unable to parse<|w>]
.* <|w>find\s+\'\>\'
.* [:s at line 3]
/;
gist => all(
/:i:s<<unable to parse /, /<<find\h+\'\>\'/, /:s<<at line 3 /
);
todo 'RT #132238 - remove "expecting any of:"';
throws-like "say \$<", X::Comp::AdHoc,
'better and shorter error message for unclosed <> hash operator',
# somewhat tricky does not contain "expecting any of"
gist => /^ [. <!before [:s expecting any of:]>]* $ /;
:gist{ not .match: /:i:s<<expecting any of: / };
}

# vim: ft=perl6 expandtab sw=4

0 comments on commit a2a6aad

Please sign in to comment.