From: gfx Date: Sun, 1 Nov 2009 06:06:19 +0000 (+0900) Subject: Delete a duplicated test file and add a new test file for Mouse::PurePerl X-Git-Tag: 0.40_05~5 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=gitmo%2FMouse.git;a=commitdiff_plain;h=5644cfbb90812c441c4c41266c526a38bea0e19a Delete a duplicated test file and add a new test file for Mouse::PurePerl --- diff --git a/t/001_mouse/603-mouse-pureperl.t b/t/001_mouse/603-mouse-pureperl.t new file mode 100644 index 0000000..8877042 --- /dev/null +++ b/t/001_mouse/603-mouse-pureperl.t @@ -0,0 +1,11 @@ +#!perl -w + +use strict; + +use Test::More tests => 1; + +use Mouse::PurePerl; +use Mouse; + +ok !Mouse::Util::_MOUSE_XS, 'load Mouse::PurePerl'; + diff --git a/t/001_mouse/603-octal-defaults.t b/t/001_mouse/603-octal-defaults.t deleted file mode 100644 index 8e41449..0000000 --- a/t/001_mouse/603-octal-defaults.t +++ /dev/null @@ -1,119 +0,0 @@ -#!/usr/bin/env perl -use Test::More qw(no_plan); - -# copied straight out of Moose t/100/019 - -{ - my $package = qq{ -package Test::Mouse::Go::Boom; -use Mouse; -use lib qw(lib); - -has id => ( - isa => 'Str', - is => 'ro', - default => '019600', # this caused the original failure -); - -no Mouse; - -__PACKAGE__->meta->make_immutable; -}; - - eval $package; - $@ ? ::fail($@) : ::pass('quoted 019600 default works'); - my $obj = Test::Mouse::Go::Boom->new; - ::is( $obj->id, '019600', 'value is still the same' ); -} - -{ - my $package = qq{ -package Test::Mouse::Go::Boom2; -use Mouse; -use lib qw(lib); - -has id => ( - isa => 'Str', - is => 'ro', - default => 017600, -); - -no Mouse; - -__PACKAGE__->meta->make_immutable; -}; - - eval $package; - $@ ? ::fail($@) : ::pass('017600 octal default works'); - my $obj = Test::Mouse::Go::Boom2->new; - ::is( $obj->id, 8064, 'value is still the same' ); -} - -{ - my $package = qq{ -package Test::Mouse::Go::Boom3; -use Mouse; -use lib qw(lib); - -has id => ( - isa => 'Str', - is => 'ro', - default => 0xFF, -); - -no Mouse; - -__PACKAGE__->meta->make_immutable; -}; - - eval $package; - $@ ? ::fail($@) : ::pass('017600 octal default works'); - my $obj = Test::Mouse::Go::Boom3->new; - ::is( $obj->id, 255, 'value is still the same' ); -} - -{ - my $package = qq{ -package Test::Mouse::Go::Boom4; -use Mouse; -use lib qw(lib); - -has id => ( - isa => 'Str', - is => 'ro', - default => '0xFF', -); - -no Mouse; - -__PACKAGE__->meta->make_immutable; -}; - - eval $package; - $@ ? ::fail($@) : ::pass('017600 octal default works'); - my $obj = Test::Mouse::Go::Boom4->new; - ::is( $obj->id, '0xFF', 'value is still the same' ); -} - -{ - my $package = qq{ -package Test::Mouse::Go::Boom5; -use Mouse; -use lib qw(lib); - -has id => ( - isa => 'Str', - is => 'ro', - default => '0 but true', -); - -no Mouse; - -__PACKAGE__->meta->make_immutable; -}; - - eval $package; - $@ ? ::fail($@) : ::pass('017600 octal default works'); - my $obj = Test::Mouse::Go::Boom5->new; - ::is( $obj->id, '0 but true', 'value is still the same' ); -}