X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2F040_type_constraints%2Ffailing%2F012_container_type_coercion.t;fp=t-failing%2F040_type_constraints%2F012_container_type_coercion.t;h=798a44845487f98115457070a7effad5160651cc;hb=9864f0e4ba233c5f30ad6dc7c484ced43d883d27;hp=b94c1ed724a6d0ab2844e7182c41655e1dc12450;hpb=8845df4dd6432e3164d078ade741409061adae9f;p=gitmo%2FMouse.git diff --git a/t-failing/040_type_constraints/012_container_type_coercion.t b/t/040_type_constraints/failing/012_container_type_coercion.t similarity index 74% rename from t-failing/040_type_constraints/012_container_type_coercion.t rename to t/040_type_constraints/failing/012_container_type_coercion.t index b94c1ed..798a448 100644 --- a/t-failing/040_type_constraints/012_container_type_coercion.t +++ b/t/040_type_constraints/failing/012_container_type_coercion.t @@ -1,30 +1,25 @@ #!/usr/bin/perl -# This is automatically generated by author/import-moose-test.pl. -# DO NOT EDIT THIS FILE. ANY CHANGES WILL BE LOST!!! -use t::lib::MooseCompat; use strict; use warnings; -use Test::More; -$TODO = q{Mouse is not yet completed}; +use Test::More tests => 9; use Test::Exception; BEGIN { use_ok('Mouse::Util::TypeConstraints'); - use_ok('Mouse::Meta::TypeConstraint'); } my $r = Mouse::Util::TypeConstraints->get_type_constraint_registry; # Array of Ints -my $array_of_ints = Mouse::Meta::TypeConstraint->new( +my $array_of_ints = Mouse::Meta::TypeConstraint::Parameterized->new( name => 'ArrayRef[Int]', parent => find_type_constraint('ArrayRef'), type_parameter => find_type_constraint('Int'), ); -isa_ok($array_of_ints, 'Mouse::Meta::TypeConstraint'); +isa_ok($array_of_ints, 'Mouse::Meta::TypeConstraint::Parameterized'); isa_ok($array_of_ints, 'Mouse::Meta::TypeConstraint'); $r->add_type_constraint($array_of_ints); @@ -33,12 +28,12 @@ is(find_type_constraint('ArrayRef[Int]'), $array_of_ints, '... found the type we # Hash of Ints -my $hash_of_ints = Mouse::Meta::TypeConstraint->new( +my $hash_of_ints = Mouse::Meta::TypeConstraint::Parameterized->new( name => 'HashRef[Int]', parent => find_type_constraint('HashRef'), type_parameter => find_type_constraint('Int'), ); -isa_ok($hash_of_ints, 'Mouse::Meta::TypeConstraint'); +isa_ok($hash_of_ints, 'Mouse::Meta::TypeConstraint::Parameterized'); isa_ok($hash_of_ints, 'Mouse::Meta::TypeConstraint'); $r->add_type_constraint($hash_of_ints); @@ -69,4 +64,4 @@ isa_ok($foo, 'Foo'); is_deeply([ sort @{$foo->bar} ], [ 1, 2, 3 ], '... our coercion worked!'); -done_testing; +