6 use Test::More tests => 9;
19 use Moose::Util::TypeConstraints;
24 isa => subtype('ArrayRef' => where {
25 (blessed($_) && $_->isa('Customer') || return) for @$_; 1 }),
28 } '... successfully created attr';
32 my $customer = Customer->new;
33 isa_ok($customer, 'Customer');
35 my $firm = Firm->new(customers => [ $customer ]);
36 isa_ok($firm, 'Firm');
38 can_ok($firm, 'customers');
43 '... got the right dereferenced value'
48 my $firm = Firm->new();
49 isa_ok($firm, 'Firm');
51 can_ok($firm, 'customers');
56 '... got the right dereferenced value'