X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2F040_type_constraints%2Ffailing%2F031_subtype_auto_vivify_parent.t;fp=t%2F040_type_constraints%2Ffailing%2F031_subtype_auto_vivify_parent.t;h=0000000000000000000000000000000000000000;hb=fde8e43f95fe996fbc2a778aa259feeb04552171;hp=e245ab89d670b1688274c6dfb02468c8d9c0a6d2;hpb=0bdc9d38dfd3de07aad929f6629f8fa65d434c27;p=gitmo%2FMouse.git diff --git a/t/040_type_constraints/failing/031_subtype_auto_vivify_parent.t b/t/040_type_constraints/failing/031_subtype_auto_vivify_parent.t deleted file mode 100644 index e245ab8..0000000 --- a/t/040_type_constraints/failing/031_subtype_auto_vivify_parent.t +++ /dev/null @@ -1,31 +0,0 @@ -#!/usr/bin/perl - -use strict; -use warnings; - -use Test::More tests => 4; - -use Mouse::Util::TypeConstraints; - - -{ - package Foo; - - sub new { - my $class = shift; - - return bless {@_}, $class; - } -} - -subtype 'FooWithSize' - => as 'Foo' - => where { $_[0]->{size} }; - - -my $type = find_type_constraint('FooWithSize'); -ok( $type, 'made a FooWithSize constraint' ); -ok( $type->parent, 'type has a parent type' ); -is( $type->parent->name, 'Foo', 'parent type is Foo' ); -isa_ok( $type->parent, 'Mouse::Meta::TypeConstraint::Class', - 'parent type constraint is a class type' );