From: Justin Hunter Date: Fri, 29 May 2009 00:42:33 +0000 (+0000) Subject: why have two loops X-Git-Tag: 5.80005~16 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=catagits%2FCatalyst-Runtime.git;a=commitdiff_plain;h=2938f7a0daa2ed737ca5cf64a4c60bab1581dda5 why have two loops add Catalyst::Plugin::MangleDollarUnderScore to plugin tests --- diff --git a/lib/Catalyst.pm b/lib/Catalyst.pm index 137e618..b32c09c 100644 --- a/lib/Catalyst.pm +++ b/lib/Catalyst.pm @@ -2505,11 +2505,8 @@ the plugin name does not begin with C. my @plugins = map { s/\A\+// ? $_ : "Catalyst::Plugin::$_" } @$plugins; - for my $plugin (@plugins) { - Class::MOP::load_class($plugin); - } - for my $plugin ( reverse @plugins ) { + Class::MOP::load_class($plugin); my $meta = find_meta($plugin); next if $meta && $meta->isa('Moose::Meta::Role'); diff --git a/t/aggregate/live_plugin_loaded.t b/t/aggregate/live_plugin_loaded.t index 835f85c..d5fc317 100644 --- a/t/aggregate/live_plugin_loaded.t +++ b/t/aggregate/live_plugin_loaded.t @@ -10,6 +10,7 @@ use Test::More tests => 5; use Catalyst::Test 'TestApp'; my @expected = qw[ + Catalyst::Plugin::MangleDollarUnderScore Catalyst::Plugin::Test::Errors Catalyst::Plugin::Test::Headers Catalyst::Plugin::Test::Inline diff --git a/t/unit_core_plugin.t b/t/unit_core_plugin.t index cfa3370..09bcfa1 100644 --- a/t/unit_core_plugin.t +++ b/t/unit_core_plugin.t @@ -42,6 +42,7 @@ is( $warnings, 1, '1 warning' ); use_ok 'TestApp'; my @expected = qw( + Catalyst::Plugin::MangleDollarUnderScore Catalyst::Plugin::Test::Errors Catalyst::Plugin::Test::Headers Catalyst::Plugin::Test::Inline