This is an automatically generated mail to inform you that tests are now 
available in t/spec/S12-subset/subtypes.t

commit 2859f31b0fc228bae3cdbfeac1a9688189582b7d
Author: kyle <k...@c213334d-75ef-0310-aa23-eaa082d1ae64>
Date:   Mon Oct 26 21:48:36 2009 +0000

    [t/spec] Test for RT 65700, subtyped attributes in instantiation
    
    git-svn-id: http://svn.pugscode.org/p...@28910 
c213334d-75ef-0310-aa23-eaa082d1ae64

diff --git a/t/spec/S12-subset/subtypes.t b/t/spec/S12-subset/subtypes.t
index 385621d..7eac46d 100644
--- a/t/spec/S12-subset/subtypes.t
+++ b/t/spec/S12-subset/subtypes.t
@@ -2,7 +2,7 @@ use v6;
 
 use Test;
 
-plan 49;
+plan *;
 
 =begin description
 
@@ -163,4 +163,22 @@ ok 42 ~~ NW1,   'subset declaration without where clause 
accepts right value';
 ok 4.2 !~~ NW1, 'subset declaration without where clause rejects wrong value';
 ok "x" !~~ NW1, 'subset declaration without where clause rejects wrong value';
 
+# RT #65700
+{
+    subset Small of Int where { $^n < 10 }
+    class RT65700 {
+        has Small $.small;
+    }
+    dies_ok { RT65700.new( small => 20 ) }, 'subset type is enforced as 
attribute in new() (1)';
+    lives_ok { RT65700.new( small => 2 ) }, 'subset type enforced as attribute 
in new() (2)';
+
+    my subset Teeny of Int where { $^n < 10 }
+    class T { has Teeny $.teeny }
+    #?rakudo 2 todo 'RT 65700'
+    dies_ok { T.new( small => 20 ) }, 'my subset type is enforced as attribute 
in new() (1)';
+    lives_ok { T.new( small => 2 ) }, 'my subset type enforced as attribute in 
new() (2)';
+}
+
+done_testing;
+
 # vim: ft=perl6

Reply via email to