diff --git a/APPENDICES/A02-some-day-maybe/multi-no-match.t b/APPENDICES/A02-some-day-maybe/multi-no-match.t index 05fdad0bd9..a43b89904d 100644 --- a/APPENDICES/A02-some-day-maybe/multi-no-match.t +++ b/APPENDICES/A02-some-day-maybe/multi-no-match.t @@ -7,7 +7,7 @@ use Test; # Since there's yet no existing behaviour for some of such combinations, # X::Multi::NoMatch is thrown. This APPENDIX test file is for such tests. -plan 10; +plan 12; { # RT #129773 throws-like { [].splice: 0, [] }, X::Multi::NoMatch, @@ -39,3 +39,10 @@ dies-ok { 42.lines: | }, throws-like { "".match: Nil }, X::Multi::NoMatch, '.match with Nil matcher does not hang'; + +{ # RT#131339 + throws-like { Pair.new: , , 42 }, X::Multi::NoMatch, + 'Pair.new with wrong positional args does not go to Mu.new'; + throws-like { Pair.new: :42a }, X::Multi::NoMatch, + 'Pair.new with wrong named args does not go to Mu.new'; +} diff --git a/S02-types/pair.t b/S02-types/pair.t index bdc959dc35..59621e17c9 100644 --- a/S02-types/pair.t +++ b/S02-types/pair.t @@ -2,7 +2,7 @@ use v6; use Test; -plan 4 * 19 + 109; +plan 4 * 19 + 107; # L # basic Pair @@ -406,14 +406,6 @@ subtest 'Pair.ACCEPTS' => { is-deeply :bar .ACCEPTS(Foo), False, 'custom class (False)'; } -{ # RT#131339 - throws-like { Pair.new: , , 42 }, X::Multi::NoMatch, - 'Pair.new with wrong positional args does not go to Mu.new'; - throws-like { Pair.new: :42a }, X::Multi::NoMatch, - 'Pair.new with wrong named args does not go to Mu.new'; -} - - subtest 'Pair.invert' => { my @tests = [ a => 42, (42 => 'a',).Seq ], [ 42 => 70, (70 => 42, ).Seq ], [ foo => (bar => meow => 42), ((bar => meow => 42) => 'foo',).Seq ],