make tests work better with forkprove
[gitmo/Moose.git] / t / bugs / create_anon_recursion.t
CommitLineData
d2470ccf 1use strict;
39bb3aa5 2use warnings;
3
a28e50e4 4use Test::More;
b10dde3a 5use Test::Fatal;
39bb3aa5 6
986a8b22 7BEGIN {
8 plan skip_all => "preloading things makes this test meaningless"
9 if exists $INC{'Moose.pm'};
10}
11
d2470ccf 12use Moose::Meta::Class;
13
14$SIG{__WARN__} = sub { die if shift =~ /recurs/ };
15
b68c3910 16TODO:
17{
18 local $TODO
19 = 'Loading Moose::Meta::Class without loading Moose.pm causes weird problems';
20
21 my $meta;
b10dde3a 22 is( exception {
b68c3910 23 $meta = Moose::Meta::Class->create_anon_class(
24 superclasses => [ 'Moose::Object', ],
25 );
b10dde3a 26 }, undef, 'Class is created successfully' );
b68c3910 27}
a28e50e4 28
29done_testing;