This is an automatically generated mail to inform you that tests are now 
available in t/spec/S06-multi/syntax.t

commit 17f12a34c378a536e8e9a816a149785bfd2bb5b6
Author: moritz <mor...@c213334d-75ef-0310-aa23-eaa082d1ae64>
Date:   Fri Jul 16 08:07:21 2010 +0000

    [t/spec] tests for RT #75136: declaring a multi just returns the current 
candidate, not the whole set
    
    git-svn-id: http://svn.pugscode.org/p...@31720 
c213334d-75ef-0310-aa23-eaa082d1ae64

diff --git a/t/spec/S06-multi/syntax.t b/t/spec/S06-multi/syntax.t
index fd21d07..6f9a55e 100644
--- a/t/spec/S06-multi/syntax.t
+++ b/t/spec/S06-multi/syntax.t
@@ -2,7 +2,7 @@ use v6;
 
 use Test;
 
-plan 34;
+plan *;
 
 # L<S06/Routine modifiers/>
 # L<S06/Parameters and arguments/>
@@ -114,6 +114,20 @@ ok(~&foo ~~ /foo/,  'a multi stringifies sensibly');
     is 21.$m(), 42, 'can write anonymous methods inside multi subs';
 }
 
+
+# RT #75136
+# a multi declaration should only return the current candidate, not the whole
+# set of candidates.
+{
+    multi sub koala(Int $x) { 42 * $x };
+
+    my $x = multi sub koala(Str $x) { 42 ~ $x }
+    is $x.candidates.elems,
+        1, 'multi sub declaration returns just the current candidate';
+    is $x('moep'), '42moep', 'and that candidate works';
+    dies_ok { $x(23) }, '... and does not contain the full multiness';
+}
+
 done_testing;
 
 # vim: ft=perl6

Reply via email to