2 use Test::More qw(no_plan);
4 # copied straight out of Moose t/100/019
8 package Test::Mouse::Go::Boom;
15 default => '019600', # this caused the original failure
20 __PACKAGE__->meta->make_immutable;
24 $@ ? ::fail($@) : ::pass('quoted 019600 default works');
25 my $obj = Test::Mouse::Go::Boom->new;
26 ::is( $obj->id, '019600', 'value is still the same' );
31 package Test::Mouse::Go::Boom2;
43 __PACKAGE__->meta->make_immutable;
47 $@ ? ::fail($@) : ::pass('017600 octal default works');
48 my $obj = Test::Mouse::Go::Boom2->new;
49 ::is( $obj->id, 8064, 'value is still the same' );
54 package Test::Mouse::Go::Boom3;
66 __PACKAGE__->meta->make_immutable;
70 $@ ? ::fail($@) : ::pass('017600 octal default works');
71 my $obj = Test::Mouse::Go::Boom3->new;
72 ::is( $obj->id, 255, 'value is still the same' );
77 package Test::Mouse::Go::Boom4;
89 __PACKAGE__->meta->make_immutable;
93 $@ ? ::fail($@) : ::pass('017600 octal default works');
94 my $obj = Test::Mouse::Go::Boom4->new;
95 ::is( $obj->id, '0xFF', 'value is still the same' );
100 package Test::Mouse::Go::Boom5;
107 default => '0 but true',
112 __PACKAGE__->meta->make_immutable;
116 $@ ? ::fail($@) : ::pass('017600 octal default works');
117 my $obj = Test::Mouse::Go::Boom5->new;
118 ::is( $obj->id, '0 but true', 'value is still the same' );