Skip to content

Commit abc9cbd

Browse files
committed
pugs fudge
1 parent ec8593e commit abc9cbd

File tree

15 files changed

+65
-0
lines changed

15 files changed

+65
-0
lines changed

S02-literals/quoting-unicode.t

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,8 @@ RIGHT SQUARE BRACKET WITH TICK IN BOTTOM CORNER(U+298D/U+298E)';
3434
DOUBLE PRIME QUOTATION MARK(U+301D/U+301E)';
3535
}
3636

37+
#?pugs skip 'hangs'
38+
#?DOES 63
3739
{
3840
my %ps_pe = (
3941
'(' => ')', '[' => ']', '{' => '}', '' => '', '' => '',

S02-types/compact.t

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,11 @@ plan 10;
1111
my uint8 @buffer = ('A' .. 'Z').map({ .ord });
1212
is(@buffer[0], ord('A'), 'basic sanity test (1)');
1313
is(@buffer[25], ord('Z'), 'basic sanity test (2)');
14+
#?pugs todo
1415
is(substr(@buffer, 0, 8), ord('A'), 'substr on compact array (1)');
16+
#?pugs todo
1517
is(substr(@buffer, 200, 8), ord('Z'), 'substr on compact array (2)');
18+
#?pugs skip 'sprintf hangs'
1619
is(
1720
substr(@buffer, 0, 16),
1821
sprintf('%08d%08d', ord('A'), ord('B')),
@@ -22,6 +25,7 @@ plan 10;
2225

2326
#?rakudo skip "Scope not found for PAST::Var"
2427
# buffer acting as a compact array
28+
#?pugs skip 'sprintf hangs'
2529
{
2630
my buf8 $buffer = ('A' .. 'Z').map({sprintf('%08d', .ord)}).cat;
2731
is($buffer[0], ord('A'), 'array indexing on buffer (1)');
@@ -35,6 +39,7 @@ plan 10;
3539

3640
# L<S09/Compact arrays/The size of any buffer type in bytes may be found with the .bytes method>
3741
#?rakudo skip "Scope not found for PAST::Var"
42+
#?pugs skip 'sprintf hangs'
3843
{
3944
my buf8 $buf8 = ('A' .. 'Z').map({sprintf('%08d', .ord)}).cat;
4045
my buf16 $buf16 = ('A' .. 'Z').map({sprintf('%08d', .ord)}).cat;

S03-smartmatch/any-bool.t

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ plan 8;
77
{
88
sub is-true() { True };
99
sub is-false() { False };
10+
#?pugs 2 todo
1011
ok 0 ~~ is-true(), '~~ non-syntactic True';
1112
ok 'a' ~~ is-true(), '~~ non-syntactic True';
1213
nok 0 ~~ is-false(), '~~ non-syntactic True';

S03-smartmatch/array-hash.t

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,16 @@ plan 6;
66
{
77
my %h = (a => 'b', c => Mu);
88
#?niecza todo
9+
#?pugs todo
910
ok (['a'] ~~ %h), 'Array ~~ Hash (exists and True)';
1011
#?niecza todo
12+
#?pugs todo
1113
ok (['c'] ~~ %h), 'Array ~~ Hash (exists but Mu)';
1214
#?niecza todo
15+
#?pugs todo
1316
ok ([<a c>] ~~ %h), 'Array ~~ Hash (both exist)';
1417
#?niecza todo
18+
#?pugs todo
1519
ok ([<c d>] ~~ %h), 'Array ~~ Hash (one exists)';
1620
# note that ?any() evaluates to False
1721
ok !( () ~~ %h), 'Array ~~ Hash (empty list)';

S05-capture/match-object.t

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,28 +6,45 @@ use Test;
66

77
plan 21;
88

9+
#?pugs todo
910
ok 'ab12de' ~~ /\d+/, 'match successful';
1011
is $/.WHAT.gist, Match.gist, 'got right type';
12+
#?pugs todo
1113
ok $/.Bool, '.Bool';
1214
ok $/.defined, '.defined';
15+
#?pugs skip 'Match.Str'
1316
is $/.Str, '12', '.Str';
17+
#?pugs todo
1418
is $/.from, 2, '.from';
19+
#?pugs todo
1520
is $/.to, 4, '.to';
21+
#?pugs skip 'Match.prematch'
1622
is $/.prematch, 'ab', '.prematch';
23+
#?pugs skip 'Match.postmatch'
1724
is $/.postmatch, 'de', '.postmatch';
25+
#?pugs todo
1826
is $/.list.elems, 0, '.list (empty)';
27+
#?pugs skip 'Unimplemented unaryOp: hash'
1928
is $/.hash.elems, 0, '.hash (empty)';
29+
#?pugs skip 'Not a keyed value'
2030
is $/.keys.elems, 0, '.keys (empty)';
31+
#?pugs skip 'Not a keyed value'
2132
is $/.values.elems, 0, '.values (empty)';
33+
#?pugs skip 'Not a keyed value'
2234
is $/.pairs.elems, 0, '.pairs (empty)';
35+
#?pugs skip 'Not a keyed value'
2336
is $/.kv.elems, 0, '.kv (empty)';
2437

2538
nok 'abde' ~~ /\d/, 'no match';
2639
nok $/.Bool, 'failed match is False';
40+
#?pugs skip 'Match.Str'
2741
is $/.Str, '', 'false match stringifies to empty string';
2842

2943
my $c;
3044
#?rakudo 3 skip 'Non-declarative sigil is missing its name at line 1, near "$\x{a2} }/\n"'
45+
#?pugs todo
3146
ok 'abc' ~~ /.{ $c =}/, 'current match state';
47+
#?pugs skip 'Cursor'
3248
is $c.WHAT.gist, Cursor.gist, 'got right type';
49+
#?pugs skip 'Scalar.pos'
3350
ok defined($c.pos), '.pos';

S05-metasyntax/changed.t

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,16 @@ plan 12;
88
{
99
# A dot . now matches any character including newline.
1010
my $str = "abc\ndef";
11+
#?pugs todo
1112
ok($str ~~ /./, '. matches something');
13+
#?pugs todo
1214
ok($str ~~ /c.d/, '. matches \n');
1315

1416
# ^ and $ now always match the start/end of a string, like the old \A and \z.
17+
#?pugs todo
1518
ok($str ~~ /^abc/, '^ matches beginning of string');
1619
ok(!($str ~~ /^de/), '^ does not match \n');
20+
#?pugs todo
1721
ok($str ~~ /def$/, '$ matches end of string');
1822
ok(!($str ~~ /bc$/), '$ does not match \n');
1923

@@ -24,11 +28,13 @@ plan 12;
2428
# A $ no longer matches an optional preceding \n
2529
{
2630
my $str = "abc\ndef\n";
31+
#?pugs todo
2732
ok($str ~~ /def\n$/, '\n$ matches as expected');
2833
ok(!($str ~~ /def$/), '$ does not match \n at end of string');
2934
}
3035

3136
# The \A, \Z, and \z metacharacters are gone.
37+
#?pugs todo
3238
{
3339
eval_dies_ok('/\A/', '\\A is gone');
3440
eval_dies_ok('/\Z/', '\\Z is gone');

S06-routine-modifiers/scoped-named-subs.t

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ eval_dies_ok('myNamedInt()', 'Correct : lexical named sub myNamedInt() should NO
2525
our Str sub ourNamedStr() { return 'string' };
2626
is ourNamedStr(), 'string', 'package-scoped named sub() return Str';
2727
}
28+
#?pugs skip 'Cannot use Undef as a Code object'
2829
{
2930
our &ourNamedStr;
3031
is ourNamedStr(), 'string', 'Correct : package-scoped named sub ourNamedStr() should BE available in the whole package';
@@ -34,6 +35,7 @@ eval_dies_ok('myNamedInt()', 'Correct : lexical named sub myNamedInt() should NO
3435
our Int sub ourNamedInt() { return 55 };
3536
is ourNamedInt(), 55, 'package-scoped named sub() return Int';
3637
}
38+
#?pugs skip 'Cannot use Undef as a Code object'
3739
{
3840
our &ourNamedInt;
3941
is ourNamedInt(), 55, 'Correct : package-scoped named sub ourNamedInt() should BE available in the whole package';

S11-modules/importing.t

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,16 +21,21 @@ plan 16;
2121
is( bop(), 'Foo::bop', 'Foo::bop is the sub we expect' );
2222

2323
multi waz($x) { 'Foo::wazhere' } #OK not used
24+
#?pugs skip 'Cannot cast from VUndef to VCode'
2425
ok( &waz, 'Foo::waz multi is defined (implicitly :DEFAULT)' );
2526
is( waz(), 'Foo::waz', 'Foo::waz is the sub we expect' );
2627
is( waz(1), 'Foo::wazhere', 'Foo::waz imported does not wipe out our other waz multis' );
2728

29+
#?pugs todo
2830
dies_ok { eval 'qux()' }, 'qux() not imported';
31+
#?pugs todo
2932
dies_ok { eval 'gaz()' }, 'gaz() not imported';
3033
}
3134

35+
#?pugs skip 'Undeclared variable'
3236
ok( ! &foo, 'Foo::foo is undefined in outer scope' );
3337

38+
#?pugs todo
3439
{
3540
BEGIN { @*INC.push('t/spec/packages') };
3641
class TestImportInClass {
@@ -44,6 +49,7 @@ ok( ! &foo, 'Foo::foo is undefined in outer scope' );
4449

4550
}
4651

52+
#?pugs todo
4753
eval_dies_ok 'use t::spec::packages::S11-modules::Foo :NoSucTag;',
4854
'die while trying to import a non-existent export tag';
4955

S12-methods/accessors.t

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,11 @@ class A {
3636

3737
my $a = A.new(a => (1, 2, 3, 4), b => [3, 4, 5, 6]);
3838
is $a.test-list-a, 4, '@.a contextualizes as (flat) list (1)';
39+
#?pugs todo
3940
is $a.test-scalar-a, 1, '$.a contextualizes as item (1)';
4041
is $a.test-list-b, 4, '@.a contextualizes as (flat) list (2)';
4142
is $a.test-scalar-b, 1, '$.a contextualizes as item (2)';
43+
#?pugs skip 'Cannot cast into Hash'
4244
is $a.test-hash-a, 2, '%.a contextualizes as hash';
4345

4446
# RT #78678
@@ -54,7 +56,9 @@ is $a.test-hash-a, 2, '%.a contextualizes as hash';
5456
my $o = Child.new(x => 42);
5557
$o.Parent::x = 5;
5658
is $o.parent-x, 5, 'parent attribute is separate from child attribute of the same name (parent)';
59+
#?pugs todo
5760
is $o.child-x, 42, 'parent attribute is separate from child attribute of the same name (child)';
61+
#?pugs todo
5862
is $o.x, 42, '.accessor returns that of the child';
5963

6064
}

S13-overloading/operators.t

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ plan 4;
2020
is 5!, 120, 'Can define recursive postfix operator';
2121
}
2222

23+
#?pugs todo
2324
{
2425
class A does Associative {
2526
method postcircumfix:<{ }>(*@ix) {
@@ -35,6 +36,7 @@ plan 4;
3536
# (even though the ticket title claims it, the actual problem was not related
3637
# to monkey typing/augmenting at all)
3738

39+
#?pugs skip 'Cannot cast from VObject'
3840
{
3941
class B {
4042
has $.x;

0 commit comments

Comments
 (0)