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;
15 use Mouse::Util::TypeConstraints;
17 coerce 'Baz' => from 'HashRef' => via { Baz->new($_) };
26 use Mouse::Util::TypeConstraints;
28 coerce 'Bar' => from 'HashRef' => via { Bar->new($_) };
46 my $foo = Foo->new(bar => { baz => { hello => 'World' } });
48 isa_ok($foo->bar, 'Bar');
49 isa_ok($foo->bar->baz, 'Baz');
50 is($foo->bar->baz->hello, 'World', '... this all worked fine');