Convert all tests to done_testing.
[gitmo/Moose.git] / t / 300_immutable / 015_immutable_destroy.t
CommitLineData
47e5ab1a 1use strict;
2use warnings;
a28e50e4 3use Test::More;
47e5ab1a 4
6735458d 5{
47e5ab1a 6 package FooBar;
7 use Moose;
8
6735458d 9 has 'name' => ( is => 'ro' );
47e5ab1a 10
11 sub DESTROY { shift->name }
12
c7514901 13 local $SIG{__WARN__} = sub {};
47e5ab1a 14 __PACKAGE__->meta->make_immutable;
15}
16
8732c62e 17my $f = FooBar->new( name => 'SUSAN' );
47e5ab1a 18
8732c62e 19is( $f->DESTROY, 'SUSAN', 'Did moose overload DESTROY?' );
a28e50e4 20
21done_testing;