Skip to content

Commit

Permalink
nom fudge
Browse files Browse the repository at this point in the history
  • Loading branch information
coke committed Aug 8, 2011
1 parent fe922ea commit 7805860
Show file tree
Hide file tree
Showing 8 changed files with 20 additions and 1 deletion.
5 changes: 4 additions & 1 deletion S02-builtin_data_types/lists.t
Expand Up @@ -12,6 +12,7 @@ use Test;
plan 29;

# Indexing lists
#?rakudo todo 'nom regression'
{
my $foo = 42;

Expand All @@ -28,6 +29,7 @@ plan 29;
}

# List construction does not create new containers
#?rakudo todo 'nom regression'
{
my $foo = 42;

Expand All @@ -36,6 +38,7 @@ plan 29;
"list construction should not create new containers";
}

#?rakudo todo 'nom regression'
{
my $foo = 42;
#?pugs todo 'unspecced'
Expand Down Expand Up @@ -149,8 +152,8 @@ plan 29;
# RT #66304
{
my $rt66304 = (1, 2, 4);
#?rakudo todo 'nom regression'
isa_ok $rt66304, Seq, 'List assigned to scalar is-a Seq';
#?rakudo todo 'exact list type'
is( $rt66304.WHAT, (1, 2, 4).WHAT,
'List.WHAT is the same as .WHAT of list assigned to scalar' );
dies_ok { $rt66304[1] = 'ro' }, 'literal List element is immutable';
Expand Down
1 change: 1 addition & 0 deletions S06-operator-overloading/methods.t
Expand Up @@ -11,6 +11,7 @@ class A {
};

# RT #69612
#?rakudo todo 'nom regression'
is A.new(:attrs({ foo => "bar" }))<foo>,
'bar', 'custom postcircumfix{ } is tied to the right class';

Expand Down
2 changes: 2 additions & 0 deletions S32-basics/warn.t
Expand Up @@ -7,6 +7,7 @@ BEGIN { @*INC.push('t/spec/packages') };

use Test::Util;

#?rakudo todo 'nom regression'
is_run 'use v6; warn; say "alive"',
{
status => 0,
Expand All @@ -15,6 +16,7 @@ is_run 'use v6; warn; say "alive"',
},
'warn() without arguments';

#?rakudo todo 'nom regression'
is_run 'use v6; warn("OH NOEZ"); say "alive"',
{
status => 0,
Expand Down
2 changes: 2 additions & 0 deletions S32-io/note.t
Expand Up @@ -22,6 +22,7 @@ is_run( 'note "multiple", " ", "params"',
},
'note multiple parameters' );

#?rakudo todo 'nom regression'
is_run( 'my @a = ("array", " of ", "params"); note @a',
{
status => 0,
Expand All @@ -38,6 +39,7 @@ is_run( 'my $a = <stringify args>; note $a',
},
'note an array reference' );

#?rakudo todo 'nom regression'
is_run( '"method form".note',
{
status => 0,
Expand Down
4 changes: 4 additions & 0 deletions S32-scalar/undef.t
Expand Up @@ -188,9 +188,12 @@ Perl6-specific tests
{
my Array $an_ary;
ok(!defined($an_ary), "my Array");
#?rakudo todo 'nom regression'
ok((try { !defined($an_ary[0]) }), "my Array subscript - Mu");
try { $an_ary.push("blergh") };
#?rakudo todo 'nom regression'
ok((try { defined($an_ary.pop) }), "push");
#?rakudo todo 'nom regression'
ok((try { !defined($an_ary.pop) }), "comes to shove");
}

Expand Down Expand Up @@ -330,6 +333,7 @@ lives_ok { uc(eval("")) }, 'can use eval("") in further expressions';
{
sub def { my $x = [] } #OK not used
ok def() ~~ Array, 'sub returns array';
#?rakudo todo 'nom regression'
lives_ok { undefine def }, 'attempt to undefine returned array lives';
ok def() ~~ Array, 'sub still returns array';

Expand Down
1 change: 1 addition & 0 deletions integration/advent2009-day11.t
Expand Up @@ -33,6 +33,7 @@ is $bob.name, 'Bob', 'dog walker has a name';
is $bob.dog_name, 'Fido', 'dog name can be accessed by delegation';

# RT 75180
#?rakudo todo 'nom regression'
is Dog.^methods(:local).map({.name}).sort.join('|'),
'bark|name', 'can introspect Dog';

Expand Down
5 changes: 5 additions & 0 deletions integration/error-reporting.t
Expand Up @@ -13,12 +13,14 @@ is_run "use v6;\n'a' =~ /foo/", {
err => rx/line \s+ 2>>/
}, 'Parse error contains line number';

#?rakudo todo 'nom regression'
is_run "my \$x = 2 * 3;\ndie \$x", {
status => { $_ != 0 },
out => '',
err => all(rx/6/, rx/'line 2'>>/),
}, 'Runtime error contains line number';

#?rakudo todo 'nom regression'
is_run "use v6;\n\nsay 'Hello';\nsay 'a'.my_non_existent_method_6R5();",
{
status => { $_ != 0 },
Expand All @@ -27,6 +29,7 @@ is_run "use v6;\n\nsay 'Hello';\nsay 'a'.my_non_existent_method_6R5();",
}, 'Method not found error mentions method name and line number';

# RT #75446
#?rakudo todo 'nom regression'
is_run 'use v6;
sub bar {
pfff();
Expand All @@ -48,11 +51,13 @@ bar()',
diag "Error message: $e";
ok $e ~~ /:i 'type check'/,
'subset type check fail mentions type check';
#?rakudo todo 'nom regression'
ok $e ~~ /:i constraint/,
'subset type check fail mentions constraint';
}

# RT #76112
#?rakudo todo 'nom regression'
is_run 'use v6;
class A { has $.x is rw };
A.new.x(42);',
Expand Down
1 change: 1 addition & 0 deletions integration/weird-errors.t
Expand Up @@ -6,6 +6,7 @@ use Test::Util;
plan 5;

# this used to segfault in rakudo
#?rakudo todo 'nom regression'
is_run(
'try { 1/0 }; my $x = $!.WHAT; say ~$x',
{ status => 0, out => -> $o { $o.chars > 2 }},
Expand Down

0 comments on commit 7805860

Please sign in to comment.