X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2Faccessor-default.t;h=3c02d7530d0a9e696d2f0bbd44b13928e805bcbf;hb=9dc13bea0bcd6910d704df85dd8287c53200915b;hp=2cec9c04e0b4ac7a5a4793955dd406a0df5392cc;hpb=b1eebd55fe3d34b6afa73a4880737dc91379b71e;p=gitmo%2FMoo.git diff --git a/t/accessor-default.t b/t/accessor-default.t index 2cec9c0..3c02d75 100644 --- a/t/accessor-default.t +++ b/t/accessor-default.t @@ -13,6 +13,9 @@ use Test::More; has three => (is => 'ro', default => quote_sub q{ {} }); has four => (is => 'ro', builder => '_build_four'); sub _build_four { {} } + has five => (is => 'ro', init_arg => undef, default => sub { {} }); + has six => (is => 'ro', builder => 1); + sub _build_six { {} } } sub check { @@ -31,4 +34,8 @@ check three => map Foo->new->{three}, 1..2; check four => map Foo->new->{four}, 1..2; +check five => map Foo->new->{five}, 1..2; + +check six => map Foo->new->{six}, 1..2; + done_testing;