X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2F030_roles%2F008_role_conflict_edge_cases.t;h=67c1e3d2256b45fac7f426bcf27b1f89361d381e;hb=fde8e43f95fe996fbc2a778aa259feeb04552171;hp=98f9a51a6ff2d3866e2d5f83e1e80a2c8a2d247a;hpb=73e9153a57c2adfd533a0ac5a3ad843ebfd4c7e7;p=gitmo%2FMouse.git diff --git a/t/030_roles/008_role_conflict_edge_cases.t b/t/030_roles/008_role_conflict_edge_cases.t index 98f9a51..67c1e3d 100644 --- a/t/030_roles/008_role_conflict_edge_cases.t +++ b/t/030_roles/008_role_conflict_edge_cases.t @@ -1,15 +1,14 @@ #!/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 tests => 32; +use Test::More; use Test::Exception; -use lib 't/lib'; -use Test::Mouse; -use MooseCompat; - =pod Check for repeated inheritance causing @@ -92,15 +91,10 @@ ok(Role::Base2->meta->has_override_method_modifier('foo'), '... have the method ok(Role::Derived3->meta->has_override_method_modifier('foo'), '... have the method foo as expected'); ok(Role::Derived4->meta->has_override_method_modifier('foo'), '... have the method foo as expected'); ok(My::Test::Class2->meta->has_method('foo'), '... have the method foo as expected'); -{ -local $TODO = 'Not a Mouse::Meta::Method::Overriden'; -isa_ok(My::Test::Class2->meta->get_method('foo'), 'Mouse::Meta::Method::Overridden'); -} +isa_ok(My::Test::Class2->meta->get_method('foo'), 'Mouse::Meta::Method'); ok(My::Test::Class2::Base->meta->has_method('foo'), '... have the method foo as expected'); -{ -local $TODO = 'Not a Class::MOP::Method'; -isa_ok(My::Test::Class2::Base->meta->get_method('foo'), 'Class::MOP::Method'); -} +isa_ok(My::Test::Class2::Base->meta->get_method('foo'), 'Mouse::Meta::Method'); + is(My::Test::Class2::Base->foo, 'My::Test::Class2::Base', '... got the right value from method'); is(My::Test::Class2->foo, 'My::Test::Class2::Base -> Role::Base::foo', '... got the right value from method'); @@ -150,15 +144,10 @@ ok(Role::Base3->meta->has_around_method_modifiers('foo'), '... have the method f ok(Role::Derived5->meta->has_around_method_modifiers('foo'), '... have the method foo as expected'); ok(Role::Derived6->meta->has_around_method_modifiers('foo'), '... have the method foo as expected'); ok(My::Test::Class3->meta->has_method('foo'), '... have the method foo as expected'); -{ -local $TODO = 'Not a Class::MOP::Method::Wrapped'; -isa_ok(My::Test::Class3->meta->get_method('foo'), 'Class::MOP::Method::Wrapped'); -} +isa_ok(My::Test::Class3->meta->get_method('foo'), 'Mouse::Meta::Method'); ok(My::Test::Class3::Base->meta->has_method('foo'), '... have the method foo as expected'); -{ -local $TODO = 'Not a Class::MOP::Method'; -isa_ok(My::Test::Class3::Base->meta->get_method('foo'), 'Class::MOP::Method'); -} +isa_ok(My::Test::Class3::Base->meta->get_method('foo'), 'Mouse::Meta::Method'); + is(My::Test::Class3::Base->foo, 'My::Test::Class3::Base', '... got the right value from method'); is(My::Test::Class3->foo, 'Role::Base::foo(My::Test::Class3::Base)', '... got the right value from method'); @@ -200,3 +189,5 @@ ok(Role::Derived8->meta->has_attribute('foo'), '... have the attribute foo as ex ok(My::Test::Class4->meta->has_attribute('foo'), '... have the attribute foo as expected'); is(My::Test::Class4->new->foo, 'Role::Base::foo', '... got the right value from method'); + +done_testing;