From: Dave Rolsky Date: Mon, 29 Nov 2010 22:29:28 +0000 (-0600) Subject: Use done_testing (require Test::More 0.88) X-Git-Tag: v0.15~10 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=d7a80104bb058373d3685627779a8bd1fd893824;p=gitmo%2FMooseX-Params-Validate.git Use done_testing (require Test::More 0.88) --- diff --git a/Makefile.PL b/Makefile.PL index e2efe9d..43e4fa0 100644 --- a/Makefile.PL +++ b/Makefile.PL @@ -13,7 +13,7 @@ requires 'Params::Validate' => '0.88'; requires 'Scalar::Util' => '0'; requires 'Sub::Exporter' => '0'; -build_requires 'Test::More' => '0.62'; +build_requires 'Test::More' => '0.88'; build_requires 'Test::Exception' => '0.21'; license 'Perl'; diff --git a/t/000_load.t b/t/000_load.t index 830b4bc..5b5bd74 100644 --- a/t/000_load.t +++ b/t/000_load.t @@ -3,10 +3,12 @@ use strict; use warnings; -use Test::More tests => 1; +use Test::More; BEGIN { # this module doesn't export to main package Testing; ::use_ok('MooseX::Params::Validate'); } + +done_testing(); diff --git a/t/001_basic.t b/t/001_basic.t index 4bede46..2b5a53d 100644 --- a/t/001_basic.t +++ b/t/001_basic.t @@ -3,7 +3,7 @@ use strict; use warnings; -use Test::More tests => 35; +use Test::More; use Test::Exception; { @@ -178,3 +178,5 @@ qr/\QThe 'foo' parameter\E.+\Qchecking type constraint/, throws_ok { $foo->quux( foo => [ 1, 2, 3, 4 ] ) } qr/\QThe 'foo' parameter\E.+\Qsome random callback/, '... foo parameter additional callback requires that arrayref be 0-2 elements'; + +done_testing(); diff --git a/t/002_basic_list.t b/t/002_basic_list.t index b248919..6759847 100644 --- a/t/002_basic_list.t +++ b/t/002_basic_list.t @@ -3,7 +3,7 @@ use strict; use warnings; -use Test::More tests => 27; +use Test::More; use Test::Exception; { @@ -132,3 +132,5 @@ qr/\QThe 'baz' parameter ("Foo")/, throws_ok { $foo->bar( foo => $foo, baz => \( my $var ) ) } qr/\QThe 'baz' parameter/, '... baz requires a ArrayRef | HashRef'; + +done_testing(); diff --git a/t/003_nocache_flag.t b/t/003_nocache_flag.t index a81b19a..a1ae689 100644 --- a/t/003_nocache_flag.t +++ b/t/003_nocache_flag.t @@ -3,7 +3,7 @@ use strict; use warnings; -use Test::More tests => 4; +use Test::More; use Test::Exception; { @@ -36,3 +36,4 @@ lives_ok { } '... successfully applied the parameter validation (look mah no cache) (just checkin)'; +done_testing(); diff --git a/t/004_custom_cache_key.t b/t/004_custom_cache_key.t index 5bceb0c..a4c3110 100644 --- a/t/004_custom_cache_key.t +++ b/t/004_custom_cache_key.t @@ -3,7 +3,7 @@ use strict; use warnings; -use Test::More tests => 7; +use Test::More; use Test::Exception; use Scalar::Util; @@ -51,3 +51,4 @@ lives_ok { } '... successfully applied the parameter validation (just checking)'; +done_testing(); diff --git a/t/005_coercion.t b/t/005_coercion.t index 967fdcd..4e36c05 100644 --- a/t/005_coercion.t +++ b/t/005_coercion.t @@ -3,7 +3,7 @@ use strict; use warnings; -use Test::More tests => 15; +use Test::More; use Test::Exception; # Note that setting coerce => 1 for the Num type tests that we don't try to do @@ -154,3 +154,5 @@ is_deeply( [ undef, undef, undef ], 'did not try to coerce non-existent parameters' ); + +done_testing(); diff --git a/t/006_not_moose.t b/t/006_not_moose.t index 46f64d9..f48b685 100644 --- a/t/006_not_moose.t +++ b/t/006_not_moose.t @@ -3,7 +3,7 @@ use strict; use warnings; -use Test::More tests => 2; +use Test::More; use Test::Exception; eval <<'EOF'; @@ -18,3 +18,5 @@ is( 'loading MX::Params::Validate in a non-Moose class does not blow up' ); ok( Foo->can('validated_hash'), 'validated_hash() sub was added to Foo package' ); + +done_testing(); diff --git a/t/007_deprecated.t b/t/007_deprecated.t index fb79933..b079957 100644 --- a/t/007_deprecated.t +++ b/t/007_deprecated.t @@ -1,7 +1,7 @@ use strict; use warnings; -use Test::More tests => 2; +use Test::More; use Test::Exception; { @@ -14,3 +14,5 @@ use Test::Exception; ok( Foo->can('validate'), ':deprecated tag exports validate' ); ok( Foo->can('validatep'), ':deprecated tag exports validatep' ); + +done_testing(); diff --git a/t/008_positional.t b/t/008_positional.t index ac7fe5a..6c05da0 100644 --- a/t/008_positional.t +++ b/t/008_positional.t @@ -3,7 +3,7 @@ use strict; use warnings; -use Test::More tests => 31; +use Test::More; use Test::Exception; { @@ -147,3 +147,4 @@ throws_ok { $foo->bar( $foo, {}, \( my $var ) ) } qr/\QParameter #3/, throws_ok { $foo->bar( $foo, {}, [qw/one two three/] ) } qr/\QParameter #3/, '... third param a ArrayRef[Int]'; +done_testing(); diff --git a/t/009_wrapped.t b/t/009_wrapped.t index 6547942..40d875c 100644 --- a/t/009_wrapped.t +++ b/t/009_wrapped.t @@ -3,7 +3,7 @@ use strict; use warnings; -use Test::More tests => 2; +use Test::More; use Test::Exception; { @@ -63,3 +63,4 @@ use Test::Exception; 'multiple around wrappers can safely be cached (2nd time)' ); } +done_testing(); diff --git a/t/010_overloaded.t b/t/010_overloaded.t index 6c861de..b939243 100644 --- a/t/010_overloaded.t +++ b/t/010_overloaded.t @@ -1,4 +1,4 @@ -use Test::More tests => 4; +use Test::More; use strict; use warnings; @@ -49,3 +49,4 @@ is( 'to_string( padded => 1 )' ); +done_testing();