6 use Test::More tests => 7;
15 use base 'Class::MOP::Class';
18 use base 'Class::MOP::Class';
21 use base 'Foo::Meta', 'Bar::Meta';
27 metaclass->import('Foo::Meta');
29 ok(!$@, '... Foo.meta => Foo::Meta is compatible') || diag $@;
34 metaclass->import('Bar::Meta');
36 ok(!$@, '... Bar.meta => Bar::Meta is compatible') || diag $@;
41 metaclass->import('Bar::Meta');
42 Foo::Foo->meta->superclasses('Foo');
44 ok($@, '... Foo::Foo.meta => Bar::Meta is not compatible') || diag $@;
49 metaclass->import('Foo::Meta');
50 Bar::Bar->meta->superclasses('Bar');
52 ok($@, '... Bar::Bar.meta => Foo::Meta is not compatible') || diag $@;
57 metaclass->import('FooBar::Meta');
58 FooBar->meta->superclasses('Foo');
60 ok(!$@, '... FooBar.meta => FooBar::Meta is compatible') || diag $@;
65 metaclass->import('FooBar::Meta');
66 FooBar2->meta->superclasses('Bar');
68 ok(!$@, '... FooBar2.meta => FooBar::Meta is compatible') || diag $@;