8 # if make_immutable is removed from the following code the tests pass
14 has foo => ( is => "ro" );
23 my ( $self, @args ) = @_;
24 $self->$next( foo => 42 );
39 my @classes = qw(Foo Bar Gorch Zoink);
42 is( Foo->new->foo, undef, "base class (" . (Foo->meta->is_immutable ? "immutable" : "mutable") . ")" );
43 is( Bar->new->foo, 42, "around new called on Bar->new (" . (Bar->meta->is_immutable ? "immutable" : "mutable") . ")" );
44 is( Gorch->new->foo, 42, "around new called on Gorch->new (" . (Gorch->meta->is_immutable ? "immutable" : "mutable") . ")" );
45 is( Zoink->new->foo, 42, "around new called Zoink->new (" . (Zoink->meta->is_immutable ? "immutable" : "mutable") . ")" );
48 local $SIG{__WARN__} = sub {};
49 ( shift @classes )->meta->make_immutable;