use strict;
use warnings;
-use Test::More tests => 84;
+use Test::More;
use Test::Exception;
-
{
+ package Thing::Meta::Attribute;
+ use Mouse;
+
+ extends 'Mouse::Meta::Attribute';
+ around illegal_options_for_inheritance => sub {
+ return (shift->(@_), qw/trigger/);
+ };
+
package Thing;
use Mouse;
# this one will work here ....
has 'fail' => (isa => 'CodeRef', is => 'bare');
- has 'other_fail' => (is => 'bare');
+ has 'other_fail' => (metaclass => 'Thing::Meta::Attribute', is => 'bare', trigger => sub { });
package Bar;
use Mouse;
ok(Bar->meta->has_attribute('gloum'), '... Bar has a gloum attr');
ok(Bar->meta->has_attribute('bling'), '... Bar has a bling attr');
ok(Bar->meta->has_attribute('bunch_of_stuff'), '... Bar does have a bunch_of_stuff attr');
-{
-local $TODO = 'not supported';
-ok(!Bar->meta->has_attribute('blang'), '... Bar does not have a blang attr');
-}
+ok(!Bar->meta->has_attribute('blang'), '... Bar has a blang attr');
ok(Bar->meta->has_attribute('fail'), '... Bar has a fail attr');
-{
-local $TODO = 'not supported';
ok(!Bar->meta->has_attribute('other_fail'), '... Bar does not have an other_fail attr');
-}
isnt(Foo->meta->get_attribute('foo'),
Bar->meta->get_attribute('foo'),
ok(Bar->meta->get_attribute('bling')->has_handles,
'... Bar::foo should handles');
-
+done_testing;