From: André Walker Date: Fri, 24 Jun 2011 03:53:13 +0000 (-0300) Subject: the plan is to use done_testing() X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=catagits%2FCatalyst-Runtime.git;a=commitdiff_plain;h=5e3121a809731aef928f60a3ad6b9b68fb4a8a9c the plan is to use done_testing() --- diff --git a/t/aggregate/unit_core_component.t b/t/aggregate/unit_core_component.t index 69ac6c0..f823ef3 100644 --- a/t/aggregate/unit_core_component.t +++ b/t/aggregate/unit_core_component.t @@ -1,4 +1,4 @@ -use Test::More tests => 22; +use Test::More; use strict; use warnings; @@ -91,3 +91,4 @@ is_deeply([ MyApp->comp('Foo') ], \@complist, 'Fallthrough return ok'); is_deeply($args, [qw/foo3 bar3/], 'args passed to ACCEPT_CONTEXT ok'); } +done_testing; diff --git a/t/aggregate/unit_core_component_generating.t b/t/aggregate/unit_core_component_generating.t index a518fce..79e3237 100644 --- a/t/aggregate/unit_core_component_generating.t +++ b/t/aggregate/unit_core_component_generating.t @@ -1,4 +1,4 @@ -use Test::More tests => 3; +use Test::More; use strict; use warnings; @@ -8,3 +8,5 @@ use TestApp; ok(TestApp->model('Generating'), 'knows about generating model'); ok(TestApp->model('Generated'), 'knows about the generated model'); is(TestApp->model('Generated')->foo, 'foo', 'can operate on generated model'); + +done_testing; diff --git a/t/aggregate/unit_core_component_layers.t b/t/aggregate/unit_core_component_layers.t index c15bc73..d603b0b 100644 --- a/t/aggregate/unit_core_component_layers.t +++ b/t/aggregate/unit_core_component_layers.t @@ -1,4 +1,4 @@ -use Test::More tests => 6; +use Test::More; use strict; use warnings; use lib 't/lib'; @@ -24,3 +24,4 @@ TestApp->setup; is($model_foo->model_quux_method, 'chunkybacon', 'Model method getting $self->{quux} from config'); +done_testing; diff --git a/t/aggregate/unit_core_component_loading.t b/t/aggregate/unit_core_component_loading.t index 2b3e205..65fb67a 100644 --- a/t/aggregate/unit_core_component_loading.t +++ b/t/aggregate/unit_core_component_loading.t @@ -1,8 +1,5 @@ -# 3 initial tests, and 6 per component in the loop below -# (do not forget to update the number of components in test 3 as well) -# 5 extra tests for the loading options -# One test for components in inner packages -use Test::More tests => 3 + 6 * 24 + 9 + 1; +# way too many tests to count +use Test::More; use strict; use warnings; @@ -256,3 +253,5 @@ eval "package $appclass; use Catalyst; __PACKAGE__->setup"; isa_ok($appclass->controller('Test'), 'Catalyst::Controller'); rmtree($libdir); + +done_testing; diff --git a/t/aggregate/unit_core_component_mro.t b/t/aggregate/unit_core_component_mro.t index 8e9a064..3b0fae6 100644 --- a/t/aggregate/unit_core_component_mro.t +++ b/t/aggregate/unit_core_component_mro.t @@ -1,4 +1,4 @@ -use Test::More tests => 1; +use Test::More; use strict; use warnings; @@ -27,3 +27,4 @@ my $warn = ''; like($warn, qr/after Catalyst::Component in MyApp::Component/, 'correct warning thrown'); +done_testing; diff --git a/t/aggregate/unit_core_component_setup_component.t b/t/aggregate/unit_core_component_setup_component.t index a669e90..d5a9066 100644 --- a/t/aggregate/unit_core_component_setup_component.t +++ b/t/aggregate/unit_core_component_setup_component.t @@ -1,6 +1,6 @@ use strict; use warnings; -use Test::More tests => 13; +use Test::More; use Moose::Meta::Class; my %config = ( @@ -94,3 +94,5 @@ Moose::Meta::Class->create( $regular => ( is( $message, undef, "no exception thrown" ); isa_ok( $component, $regular, "the returned value is correct" ); } + +done_testing; diff --git a/t/aggregate/unit_core_container_path_env.t b/t/aggregate/unit_core_container_path_env.t index b91d185..11e3d81 100644 --- a/t/aggregate/unit_core_container_path_env.t +++ b/t/aggregate/unit_core_container_path_env.t @@ -4,7 +4,7 @@ use warnings; use FindBin; use lib "$FindBin::Bin/../lib"; -use Test::More tests => 3; +use Test::More; $ENV{ TESTAPPCONTAINER_CONFIG } = 'test.perl'; @@ -13,3 +13,5 @@ use_ok 'Catalyst::Test', 'TestAppContainer'; ok my ( $res, $c ) = ctx_request( '/' ), 'context object'; is_deeply $c->container->resolve( service => 'config_path' ), [ qw( test.perl perl ) ], 'path is "test.perl"'; + +done_testing; diff --git a/t/aggregate/unit_core_container_suffix_env.t b/t/aggregate/unit_core_container_suffix_env.t index 589e266..2390ba6 100644 --- a/t/aggregate/unit_core_container_suffix_env.t +++ b/t/aggregate/unit_core_container_suffix_env.t @@ -4,7 +4,7 @@ use warnings; use FindBin; use lib "$FindBin::Bin/../lib"; -use Test::More tests => 3; +use Test::More; $ENV{ TESTAPPCONTAINER_CONFIG_LOCAL_SUFFIX } = 'test'; use_ok 'Catalyst::Test', 'TestAppContainer'; @@ -12,3 +12,5 @@ use_ok 'Catalyst::Test', 'TestAppContainer'; ok my ( $res, $c ) = ctx_request( '/' ), 'context object'; is $c->container->resolve( service => 'config_local_suffix' ), 'test', 'suffix is "test"'; + +done_testing;