2 # This is automatically generated by author/import-moose-test.pl.
3 # DO NOT EDIT THIS FILE. ANY CHANGES WILL BE LOST!!!
4 use t::lib::MooseCompat;
12 use Mouse::Meta::Class;
14 my $meta = Mouse::Meta::Class->create('Banana');
17 $SIG{__WARN__} = sub { $warn = "@_" };
19 $meta->add_attribute('foo');
20 like $warn, qr/Attribute \(foo\) of class Banana has no associated methods/,
21 'correct error message';
24 $meta->add_attribute('bar', is => 'bare');
25 is $warn, '', 'add attribute with no methods and is => "bare"';