Skip to content

Commit

Permalink
Add a test for smartmatching Signature and Signature
Browse files Browse the repository at this point in the history
  • Loading branch information
amire80 committed Oct 3, 2012
1 parent 5efc2af commit 748aace
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions S03-smartmatch/signature-signature.t
@@ -0,0 +1,16 @@
use v6;
use Test;
plan 5;

#L<S03/Smart matching/Signature-signature>
{
ok (:(Str) ~~ :(Str)), 'signature :(Str) is the same as :(Str)';
ok !(:(Str) ~~ :(Int)), 'signature :(Str) is not the same as :(Int)';
ok (:(Str, Int) ~~ :(Str, Int)), 'signature :(Str, Int) is the same as :(Str, Int)';
ok !(:(Str, Int) ~~ :(Int, Str)), 'signature :(Str, Int) is not the same as :(Int, Str)';
ok !(:(Str, Int) ~~ :(Str, Int, Str)), 'signature :(Str, Int) is not the same as :(Str, Int, Str)';
}

done;

# vim: ft=perl6

0 comments on commit 748aace

Please sign in to comment.