From: Karen Etheridge Date: Sat, 22 Dec 2012 01:47:34 +0000 (-0800) Subject: add test counts, obviating done_testing X-Git-Tag: v0.48~13 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=1f314cdccd9ef11cc0ecb606b5247fc0f9ee0237;p=gitmo%2FMooseX-Getopt.git add test counts, obviating done_testing --- diff --git a/t/011_process_argv.t b/t/011_process_argv.t index c070d54..2a7baf3 100644 --- a/t/011_process_argv.t +++ b/t/011_process_argv.t @@ -1,18 +1,9 @@ use strict; use warnings; -use Test::More; +use Test::More tests => 6; use Test::Fatal 0.003; - -if ( !eval { require Test::Deep } ) -{ - plan skip_all => 'Test requires Test::Deep'; - exit; -} -else -{ - plan tests => 6; -} +use Test::Requires 'Test::Deep'; { package Testing::Foo; diff --git a/t/104_override_usage.t b/t/104_override_usage.t index be68178..71ff691 100644 --- a/t/104_override_usage.t +++ b/t/104_override_usage.t @@ -1,6 +1,7 @@ use strict; use warnings; -use Test::More 0.88; + +use Test::More tests => 8; use Test::Trap; { @@ -55,5 +56,3 @@ use Test::Trap; is_deeply \@MyScript::exception, $exp; } -done_testing; - diff --git a/t/105_uc_bug_more.t b/t/105_uc_bug_more.t index 061dc97..04a8c9b 100644 --- a/t/105_uc_bug_more.t +++ b/t/105_uc_bug_more.t @@ -1,6 +1,7 @@ use strict; use warnings; -use Test::More; + +use Test::More tests => 12; use Moose (); use Moose::Meta::Class; @@ -33,5 +34,3 @@ foreach my $role (qw/ "Debug was set for argv --debug on $role"); } -done_testing; - diff --git a/t/106_no_ignore_case.t b/t/106_no_ignore_case.t index 709ec65..06955c8 100644 --- a/t/106_no_ignore_case.t +++ b/t/106_no_ignore_case.t @@ -1,6 +1,7 @@ use strict; use warnings; -use Test::More; + +use Test::More tests => 21; use Moose (); use Moose::Meta::Class; @@ -53,5 +54,3 @@ foreach my $role (qw/ } } -done_testing; - diff --git a/t/107_no_auto_help.t b/t/107_no_auto_help.t index f252780..d3eb573 100644 --- a/t/107_no_auto_help.t +++ b/t/107_no_auto_help.t @@ -7,11 +7,11 @@ # Summary: If we disable the "auto_help" option in Getopt::Long, then # getoptions() will not call into pod2usage() (causing program termination) # when --help is passed (and MooseX::ConfigFromFile is in use). + use strict; use warnings; -use Test::More; - +use Test::More tests => 1; use Test::Requires { 'MooseX::SimpleConfig' => 0.07, # skip all if not installed }; @@ -47,8 +47,6 @@ use Test::Fatal 0.003; END { ok(!$fail_on_exit, 'getoptions() lives'); - done_testing; - # cancel the non-zero exit status from _getopt_full_usage() exit 0; } diff --git a/t/107_union_bug.t b/t/107_union_bug.t index 5d03c68..270e3bf 100644 --- a/t/107_union_bug.t +++ b/t/107_union_bug.t @@ -1,7 +1,7 @@ use strict; use warnings; -use Test::More; +use Test::More tests => 5; { package example; @@ -60,5 +60,3 @@ use Test::More; is_deeply($example->results, [qw(1234 5678 9012)], 'result as expected'); } -done_testing; -