Commit | Line | Data |
fde8e43f |
1 | use strict; |
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; |
5 | use warnings; |
6 | use Test::More; |
7 | $TODO = q{Mouse is not yet completed}; |
8 | |
9 | { |
10 | package FooBar; |
11 | use Mouse; |
12 | |
13 | has 'name' => ( is => 'ro' ); |
14 | |
15 | sub DESTROY { shift->name } |
16 | |
17 | local $SIG{__WARN__} = sub {}; |
18 | __PACKAGE__->meta->make_immutable; |
19 | } |
20 | |
21 | my $f = FooBar->new( name => 'SUSAN' ); |
22 | |
23 | is( $f->DESTROY, 'SUSAN', 'Did moose overload DESTROY?' ); |
24 | |
25 | done_testing; |