Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 37 lines (27 sloc) 0.976 kb
2a013e1 [gsoc_spectest] tests for handling of unknown metasyntax and escaping (a...
Auzon authored
1 use v6;
2 use Test;
3
b80cf7d [t/spec] tests for RT #74832
moritz authored
4 plan 10;
2a013e1 [gsoc_spectest] tests for handling of unknown metasyntax and escaping (a...
Auzon authored
5
6 # L<S05/Simplified lexical parsing of patterns/not all non-identifier glyphs are currently meaningful as metasyntax>
7
8 # testing unknown metasyntax handling
9
10 eval_dies_ok('"aa!" ~~ /!/', '"!" is not valid metasyntax');
11 lives_ok({"aa!" ~~ /\!/}, 'escaped "!" is valid');
12 lives_ok({"aa!" ~~ /'!'/}, 'quoted "!" is valid');
13
14 eval_dies_ok('"aa!" ~~ /\a/', 'escaped "a" is not valid metasyntax');
15 lives_ok({"aa!" ~~ /a/}, '"a" is valid');
16 lives_ok({"aa!" ~~ /'a'/}, 'quoted "a" is valid');
fc2d82c [t] merge braces_in_rules.t into spec/S05-metasyntax/unknown.t
moritz authored
17
18 # used to be a pugs bug
19
21ca56b [t/spec] fudge S05-metasyntax/unknown.t for rakudo; correct a test
moritz authored
20 #?rakudo skip 'calling <foo> from outer scopes'
d0e149b @coke niecza fudging
coke authored
21 #?niecza skip 'Unable to resolve method foo in class Cursor'
21ca56b [t/spec] fudge S05-metasyntax/unknown.t for rakudo; correct a test
moritz authored
22 {
23 my rule foo { \{ };
24 ok '{' ~~ /<foo>/, '\\{ in a rule (+)';
25 ok '!' !~~ /<foo>/, '\\{ in a rule (-)';
26 }
fc2d82c [t] merge braces_in_rules.t into spec/S05-metasyntax/unknown.t
moritz authored
27
b80cf7d [t/spec] tests for RT #74832
moritz authored
28 # RT #74832
29 {
a238bb3 @moritz remove bogus test
moritz authored
30 dies_ok {eval('/ a+ + /')}, 'Cannot parse regex a+ +';
e5d54f6 @moritz fudge a test that nom accidentally passed before
moritz authored
31 #?rakudo todo 'RT 74832'
946cccf @coke niecza fudging
coke authored
32 #?niecza todo
ebfcb8a [t/spec] be more liberal with case of detected error message
moritz authored
33 ok "$!" ~~ /:i quantif/, 'error message mentions quantif{y,ier}';
b80cf7d [t/spec] tests for RT #74832
moritz authored
34 }
35
fc2d82c [t] merge braces_in_rules.t into spec/S05-metasyntax/unknown.t
moritz authored
36 # vim: ft=perl6
Something went wrong with that request. Please try again.