Fix all the tests after merge
Tomas Doran [Thu, 9 Sep 2010 23:10:15 +0000 (23:10 +0000)]
lib/Catalyst/Authentication/User.pm
lib/Catalyst/Plugin/Authentication.pm
t/author/pod_coverage.t

index eeff10e..a97d3d3 100644 (file)
@@ -72,6 +72,8 @@ sub AUTOLOAD {
     my $self = shift;
     (my $method) = (our $AUTOLOAD =~ /([^:]+)$/);
     return if $method eq "DESTROY";
+    $self->get_object->$method(@_);
+}
 
 __PACKAGE__->meta->make_immutable;
 __PACKAGE__;
index d78a63b..98f170f 100644 (file)
@@ -1,5 +1,5 @@
 package Catalyst::Plugin::Authentication;
-use Moose::Role;
+use Moose;
 use MRO::Compat;
 use Tie::RefHash;
 use Class::Inspector;
@@ -192,12 +192,13 @@ sub auth_restore_user {
 
 # We can't actually do our setup in setup because the model has not yet been loaded.  
 # So we have to trigger before 'setup_finalize'.
-before 'setup_finalize' => sub {
+sub setup {
     my $app = shift;
 
     $app->mk_classdata('_auth_initialized');
     $app->_authentication_initialize();
-};
+    $app->next::method(@_);
+}
 
 ## the actual initialization routine. whee.
 sub _authentication_initialize {
index d91be5e..a36aa99 100644 (file)
@@ -4,4 +4,4 @@ eval "use Test::Pod::Coverage 1.04";
 plan skip_all => 'Test::Pod::Coverage 1.04 required' if $@;
 plan skip_all => 'set TEST_POD to enable this test' unless $ENV{TEST_POD};
 
-all_pod_coverage_ok();
+all_pod_coverage_ok( { also_private => [ qr/^BUILD(ARGS)?$/ ] } );