Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
rakudo fudging
  • Loading branch information
coke committed Oct 23, 2011
1 parent 203e22e commit 02c1b47
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 0 deletions.
1 change: 1 addition & 0 deletions S02-lexical-conventions/comments.t
Expand Up @@ -71,6 +71,7 @@ plan 46;

# L<S02/"User-selected Brackets"/"closed by" "same number of"
# "closing brackets">
#?rakudo skip 'nom regression'
{

ok #`<<<
Expand Down
3 changes: 3 additions & 0 deletions S03-operators/inplace.t
Expand Up @@ -6,6 +6,7 @@ use Test;

plan 28;

#?rakudo todo 'nom regression'
{
my @a = (1, 2, 3);
lives_ok({@a .= map: { $_ + 1 }}, '.= runs with block');
Expand All @@ -14,6 +15,7 @@ plan 28;
is(@a[2], 4, 'inplace map [2]');
}

#?rakudo todo 'nom regression'
{
my @b = <foo 123 bar 456 baz>;
#?niecza todo
Expand All @@ -26,6 +28,7 @@ plan 28;
is @b[2], 'baz', 'inplace grep [2]';
}

#?rakudo skip "Method '' not found for invocant of class 'Str'"
{
my $a=3.14;
$a .= Int;
Expand Down
2 changes: 2 additions & 0 deletions S03-operators/nesting.t
Expand Up @@ -7,6 +7,7 @@ plan 26;

ok &infix:<+> === &[+], 'long and short form are the same (+)';
ok &infix:<==> === &[==], 'long and short form are the same (==)';
#?rakudo skip 'nom regression'
is sort( &[<=>], <5 3 2 1 4> ), <1 2 3 4 5>, 'sort works using &[<=>]';

is &[+](1, 2), 3, '&[+] as a function';
Expand Down Expand Up @@ -47,6 +48,7 @@ is (1 R[R[R-]] 2), 1, 'R[R[R-]] works';
is (1 RR[R-] 2), 1, 'RR[R-] works';

# crazy stuff
#?rakudo skip 'nom regression'
{
our sub infix:<blue>($a, $b) {
$a % $b
Expand Down
4 changes: 4 additions & 0 deletions S03-sequence/nonnumeric.t
Expand Up @@ -36,6 +36,7 @@ plan 34;
# character sequence

is ('a' ... 'g').join(', '), 'a, b, c, d, e, f, g', 'finite sequence started with one letter';
#?rakudo skip 'nom regression'
is ('a' ... *).[^7].join(', '), 'a, b, c, d, e, f, g', 'sequence started with one letter';
is ('a', 'b' ... *).[^10].join(', '), 'a, b, c, d, e, f, g, h, i, j', 'sequence started with two different letters';
is (<a b c> ... *).[^10].join(', '), "a, b, c, d, e, f, g, h, i, j", "character sequence started from array";
Expand All @@ -44,7 +45,9 @@ is (<z y> ... 'a').[^10].join(', '), 'z, y, x, w, v, u, t, s, r, q', 'descending
is (<z y m> ... 'a').[^10].join(', '), 'z, y, m, l, k, j, i, h, g, f', 'descending sequence started with three different letters';
is (<a b>, { .succ } ... *).[^7].join(', '), 'a, b, c, d, e, f, g', 'characters xand arity-1';
is ('x' ... 'z').join(', '), 'x, y, z', "sequence ending with 'z' don't cross to two-letter strings";
#?rakudo skip 'hangs'
is ('A' ... 'z').elems, 'z'.ord - 'A'.ord + 1, "sequence from 'A' to 'z' is finite and of correct length";
#?rakudo skip 'hangs'
is ('Ξ±' ... 'Ο‰').elems, 'Ο‰'.ord - 'Ξ±'.ord + 1, "sequence from 'Ξ±' to 'Ο‰' is finite and of correct length";
#?rakudo 2 skip 'Unicode stuff'
is ('β˜€' ... 'β˜•').join(''), 'β˜€β˜β˜‚β˜ƒβ˜„β˜…β˜†β˜‡β˜ˆβ˜‰β˜Šβ˜‹β˜Œβ˜β˜Žβ˜β˜β˜‘β˜’β˜“β˜”β˜•', "sequence from 'β˜€' to 'β˜•'";
Expand All @@ -54,6 +57,7 @@ is ('β˜€' ...^ 'β˜•').join(''), 'β˜€β˜β˜‚β˜ƒβ˜„β˜…β˜†β˜‡β˜ˆβ˜‰β˜Šβ˜‹β˜Œβ˜β˜Ž
# the tricky termination test

ok ('A' ... 'ZZ').munch(1000).elems < 1000, "'A' ... 'ZZ' does not go on forever";
#?rakudo 2 skip 'Decrement out of range'
ok ('ZZ' ... 'A').munch(1000).elems < 1000, "'ZZ' ... 'A' does not go on forever";
ok ('Z' ... 'AA').munch(1000).elems < 1000, "'Z' ... 'AA' does not go on forever";
is ('A' ...^ 'ZZ')[*-1], 'ZY', "'A' ...^ 'ZZ' omits last element";
Expand Down
3 changes: 3 additions & 0 deletions S05-metasyntax/angle-brackets.t
Expand Up @@ -154,6 +154,7 @@ character classes), and those are referenced at the correct spot.

# A leading @ matches like a bare array except that each element is
# treated as a subrule (string or Regex object) rather than as a literal
#?rakudo todo 'nom regression'
{
my @first = <a b c .**4>;
ok('dddd' ~~ /<@first>/, 'strings are treated as a subrule in <@foo>');
Expand All @@ -175,6 +176,7 @@ character classes), and those are referenced at the correct spot.

# A leading { indicates code that produces a regex to be
# interpolated into the pattern at that point as a subrule:
#?rakudo skip 'null PMC'
{
ok('abcdef' ~~ /<{'<al' ~ 'pha>'}>/, 'code interpolation');
}
Expand Down Expand Up @@ -221,6 +223,7 @@ character classes), and those are referenced at the correct spot.
{
ok('1./:"{}=-' ~~ /^[<!alpha> .]+$/, '<!alpha> matches non-letter characters');
ok(!('abcdef' ~~ /<!alpha>./), '<!alpha> does not match letter characters');
#?rakudo 2 skip 'no before'
is(+('.2 1' ~~ /<!before 2> \d/), 1, '<!before>');
is +$/.caps, 0, '<!before 2> does not capture';
}
Expand Down

0 comments on commit 02c1b47

Please sign in to comment.