use strict;
use warnings;
-use Test::More tests => 4;
+use Test::More;
use Test::Exception;
-BEGIN {
- use_ok('Moose');
-}
{
package AClass;
has 'foo' => (is => 'rw', isa => 'Maybe[Str]', trigger => sub {
die "Pulling the Foo trigger\n"
});
-
- has 'bar' => (is => 'rw', isa => 'Maybe[Str]');
-
+
+ has 'bar' => (is => 'rw', isa => 'Maybe[Str]');
+
has 'baz' => (is => 'rw', isa => 'Maybe[Str]', trigger => sub {
die "Pulling the Baz trigger\n"
- });
+ });
__PACKAGE__->meta->make_immutable; #(debug => 1);
lives_ok { AClass->new(bar => 'bar') } '... no triggers called';
-
-
+done_testing;