Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 40 lines (25 sloc) 0.928 kb
5cd88fc [t] move rulecode.t to spec/; cleanup
moritz authored
1 use v6;
2
3 use Test;
4
5 =begin pod
6
7 This file was derived from the perl5 CPAN module Perl6::Rules,
8 version 0.3 (12 Apr 2004), file t/rulecode.t.
9
10 It has (hopefully) been, and should continue to be, updated to
11 be valid perl6.
12
13 =end pod
14
70df7d9 @moritz simplify interpolating-closure.t, and add tests for RT #102860
moritz authored
15 plan 6;
5cd88fc [t] move rulecode.t to spec/; cleanup
moritz authored
16
3a41ccc Fix all currently broken smartlinks to S05
Coleoid authored
17 # L<S05/Extensible metasyntax (C<< <...> >>)/unambiguously calls a routine instead>
e27dccc [t/spec] smartlinks and a simplification
moritz authored
18
70df7d9 @moritz simplify interpolating-closure.t, and add tests for RT #102860
moritz authored
19 my regex abc { a b c }
5cd88fc [t] move rulecode.t to spec/; cleanup
moritz authored
20
21 my $var = "";
22 ok("aaabccc" ~~ m/aa <{ $var ?? $var !! rx{abc} }> cc/, 'Rule block second');
23
70df7d9 @moritz simplify interpolating-closure.t, and add tests for RT #102860
moritz authored
24 $var = rx/<&abc>/;
5cd88fc [t] move rulecode.t to spec/; cleanup
moritz authored
25 ok("aaabccc" ~~ m/aa <{ $var ?? $var !! rx{<.null>} }> cc/, 'Rule block first');
26
27 $var = rx/xyz/;
70df7d9 @moritz simplify interpolating-closure.t, and add tests for RT #102860
moritz authored
28 #?rakudo todo 'dunno'
9ebc638 @coke fudge for niecza
coke authored
29 #?niecza todo 'dunno'
5cd88fc [t] move rulecode.t to spec/; cleanup
moritz authored
30 ok("aaabccc" !~~ m/aa <{ $var ?? $var !! rx{abc} }> cc/, 'Rule block fail');
31
70df7d9 @moritz simplify interpolating-closure.t, and add tests for RT #102860
moritz authored
32 $var = rx/<&abc>/;
5cd88fc [t] move rulecode.t to spec/; cleanup
moritz authored
33 ok("aaabccc" ~~ m/aa <{ $var ?? $var !! rx{abc} }> cc/, 'Rule block interp');
34
70df7d9 @moritz simplify interpolating-closure.t, and add tests for RT #102860
moritz authored
35 # RT #102860
36 ok 'abc' ~~ /<{ '.+' }>/, 'interpolating string with meta characters';
37 is $/.Str, 'abc', '... gives the right match';
38
5cd88fc [t] move rulecode.t to spec/; cleanup
moritz authored
39 # vim: ft=perl6
Something went wrong with that request. Please try again.