From: Tokuhiro Matsuno Date: Wed, 3 Dec 2008 06:13:51 +0000 (+0000) Subject: oops... i forgot s/Moose/Mouse/ orz X-Git-Tag: 0.19~136^2~59 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=b0000b3d2779a5829883471f95f4a8548b486c82;p=gitmo%2FMouse.git oops... i forgot s/Moose/Mouse/ orz --- diff --git a/t/300_immutable/007_immutable_trigger_from_constructor.t b/t/300_immutable/007_immutable_trigger_from_constructor.t index cab557f..e8382f0 100644 --- a/t/300_immutable/007_immutable_trigger_from_constructor.t +++ b/t/300_immutable/007_immutable_trigger_from_constructor.t @@ -3,15 +3,16 @@ use strict; use warnings; -use Test::More tests => 3; +use Test::More; use Test::Exception; - +plan skip_all => "mouse doesn't support Maybe[] yet"; +plan tests => 3; { package AClass; - use Moose; + use Mouse; has 'foo' => (is => 'rw', isa => 'Maybe[Str]', trigger => sub { die "Pulling the Foo trigger\n" @@ -25,7 +26,7 @@ use Test::Exception; __PACKAGE__->meta->make_immutable; #(debug => 1); - no Moose; + no Mouse; } eval { AClass->new(foo => 'bar') }; diff --git a/t/300_immutable/008_immutable_constructor_error.t b/t/300_immutable/008_immutable_constructor_error.t index 62d6d3c..d4af493 100644 --- a/t/300_immutable/008_immutable_constructor_error.t +++ b/t/300_immutable/008_immutable_constructor_error.t @@ -18,7 +18,7 @@ constructor. { package Foo; - use Moose; + use Mouse; has 'foo' => (is => 'rw', isa => 'Int'); diff --git a/t/300_immutable/009_buildargs.t b/t/300_immutable/009_buildargs.t index 6c1ca33..c7c700c 100644 --- a/t/300_immutable/009_buildargs.t +++ b/t/300_immutable/009_buildargs.t @@ -7,7 +7,7 @@ use Test::More tests => 14; { package Foo; - use Moose; + use Mouse; has bar => ( is => "rw" ); has baz => ( is => "rw" ); @@ -21,7 +21,7 @@ use Test::More tests => 14; __PACKAGE__->meta->make_immutable; package Bar; - use Moose; + use Mouse; extends qw(Foo); @@ -31,17 +31,23 @@ use Test::More tests => 14; foreach my $class qw(Foo Bar) { is( $class->new->bar, undef, "no args" ); is( $class->new( bar => 42 )->bar, 42, "normal args" ); - is( $class->new( 37 )->bar, 37, "single arg" ); + SKIP: { + skip "this feature doesn't supported by Mouse", 1; + is( $class->new( 37 )->bar, 37, "single arg" ); + }; { my $o = $class->new(bar => 42, baz => 47); is($o->bar, 42, '... got the right bar'); is($o->baz, 47, '... got the right bar'); } - { - my $o = $class->new(42, baz => 47); - is($o->bar, 42, '... got the right bar'); - is($o->baz, 47, '... got the right bar'); - } + SKIP: { + skip "this feature doesn't supported by Mouse", 2; + { + my $o = $class->new(42, baz => 47); + is($o->bar, 42, '... got the right bar'); + is($o->baz, 47, '... got the right bar'); + } + }; }