6 use Test::More tests => 29;
14 use Mouse::Util::TypeConstraints;
17 can_ok('Foo', 'meta');
18 isa_ok(Foo->meta, 'Mouse::Meta::Class');
20 ok(Foo->meta->has_method('meta'), '... we got the &meta method');
21 ok(Foo->isa('Mouse::Object'), '... Foo is automagically a Mouse::Object');
24 Foo->meta->has_method()
25 } '... has_method requires an arg';
27 can_ok('Foo', 'does');
29 foreach my $function (qw(
38 ok(!Foo->meta->has_method($function), '... the meta does not treat "' . $function . '" as a method');
41 foreach my $import (qw(
47 ok(!Mouse::Object->can($import), "no namespace pollution in Mouse::Object ($import)" );
49 local $TODO = $import eq 'blessed' ? "no automatic namespace cleaning yet" : undef;
50 ok(!Foo->can($import), "no namespace pollution in Mouse::Object ($import)" );