r44095 - in /trunk/libcatalyst-perl: ./ debian/ inc/Module/Install/ lib/ lib/Catalyst/ lib/Catalyst/Engine/ t/ t/aggregate/ t/author/ t/lib/

eloy at users.alioth.debian.org eloy at users.alioth.debian.org
Mon Sep 14 15:21:15 UTC 2009


Author: eloy
Date: Mon Sep 14 15:21:09 2009
New Revision: 44095

URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=44095
Log:
new upstream version

Added:
    trunk/libcatalyst-perl/inc/Module/Install/AuthorTests.pm
      - copied unchanged from r44094, branches/upstream/libcatalyst-perl/current/inc/Module/Install/AuthorTests.pm
    trunk/libcatalyst-perl/t/author/
      - copied from r44094, branches/upstream/libcatalyst-perl/current/t/author/
    trunk/libcatalyst-perl/t/unit_controller_actions.t
      - copied unchanged from r44094, branches/upstream/libcatalyst-perl/current/t/unit_controller_actions.t
Removed:
    trunk/libcatalyst-perl/t/cdi_backcompat_plugin_accessor_override.t
    trunk/libcatalyst-perl/t/optional_http-server.t
Modified:
    trunk/libcatalyst-perl/Changes
    trunk/libcatalyst-perl/MANIFEST
    trunk/libcatalyst-perl/META.yml
    trunk/libcatalyst-perl/Makefile.PL
    trunk/libcatalyst-perl/TODO
    trunk/libcatalyst-perl/debian/changelog
    trunk/libcatalyst-perl/lib/Catalyst.pm
    trunk/libcatalyst-perl/lib/Catalyst/ClassData.pm
    trunk/libcatalyst-perl/lib/Catalyst/Component.pm
    trunk/libcatalyst-perl/lib/Catalyst/Controller.pm
    trunk/libcatalyst-perl/lib/Catalyst/Dispatcher.pm
    trunk/libcatalyst-perl/lib/Catalyst/Engine.pm
    trunk/libcatalyst-perl/lib/Catalyst/Engine/CGI.pm
    trunk/libcatalyst-perl/lib/Catalyst/Request.pm
    trunk/libcatalyst-perl/lib/Catalyst/Runtime.pm
    trunk/libcatalyst-perl/t/aggregate/live_component_controller_action_index_or_default.t
    trunk/libcatalyst-perl/t/aggregate/live_component_controller_action_path_matchsingle.t
    trunk/libcatalyst-perl/t/aggregate/live_component_controller_action_regexp.t
    trunk/libcatalyst-perl/t/aggregate/live_component_view_single.t
    trunk/libcatalyst-perl/t/aggregate/live_engine_request_escaped_path.t
    trunk/libcatalyst-perl/t/aggregate/live_engine_request_remote_user.t
    trunk/libcatalyst-perl/t/deprecated.t
    trunk/libcatalyst-perl/t/lib/TestApp.pm
    trunk/libcatalyst-perl/t/optional_http-server-restart.t
    trunk/libcatalyst-perl/t/unit_core_classdata.t
    trunk/libcatalyst-perl/t/unit_core_component_loading.t
    trunk/libcatalyst-perl/t/unit_core_plugin.t
    trunk/libcatalyst-perl/t/unit_core_setup_stats.t

Modified: trunk/libcatalyst-perl/Changes
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/Changes?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/Changes (original)
+++ trunk/libcatalyst-perl/Changes Mon Sep 14 15:21:09 2009
@@ -1,4 +1,25 @@
 # This file documents the revision history for Perl extension Catalyst.
+#
+5.80012 2009-09-09 19:09:09
+
+  Bug fixes:
+     - Fix t/optional_http-server.t test.
+     - Fix t/optional_http-server-restart.t test.
+     - Fix duplicate components being loaded at setup time, each component is
+       now loaded at most once + tests.
+     - Fix backward compatibility - hash key configured actions are stored in
+       is returned to 'actions'.
+     - Fix get_action_methods returning duplicate methods when a method is both
+       decorated with method attributes and set as an action in config.
+
+  Refactoring / cleanups:
+     - Reduce minimum supported perl version from 5.8.6 to 5.8.4 as there are
+       many people still running/testing this version with no known issues.
+
+  Tests:
+     - Make the optional_http_server.t test an author only test which must be
+       run by authors to stop it being broken again.
+     - Fix recursion warnings in the test suites.
 
 5.80011 2009-08-23 13:48:15
 
@@ -48,9 +69,7 @@
          new Catalyst::Restarter in a recent Catalyst::Devel instead.
        - New unit test for Catalyst::Action 'unit_core_action.t'
        - Bump minimum supported perl version from 5.8.1 to 5.8.6 as there are
-         known issues with 5.8.3, and nobody is prepared to fix / support perl
-         older than 5.8.6 any more. Patches to regain compatibility to older
-         perls would be welcome.
+         known issues with 5.8.3.
        - Debug output uses dynamic column sizing to create more readable output
          when using a larger $ENV{COLUMNS} setting. (groditi)
 

Modified: trunk/libcatalyst-perl/MANIFEST
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/MANIFEST?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/MANIFEST (original)
+++ trunk/libcatalyst-perl/MANIFEST Mon Sep 14 15:21:09 2009
@@ -2,6 +2,7 @@
 inc/Module/AutoInstall.pm
 inc/Module/Install.pm
 inc/Module/Install/AuthorRequires.pm
+inc/Module/Install/AuthorTests.pm
 inc/Module/Install/AutoInstall.pm
 inc/Module/Install/Base.pm
 inc/Module/Install/Can.pm
@@ -114,11 +115,11 @@
 t/aggregate/unit_core_component_layers.t
 t/aggregate/unit_core_uri_for_action.t
 t/aggregate/unit_core_uri_for_multibytechar.t
+t/author/optional_http-server.t
 t/c3_appclass_bug.t
 t/c3_mro.t
 t/caf_backcompat.t
 t/catalyst_130pix.gif
-t/cdi_backcompat_plugin_accessor_override.t
 t/conf/extra.conf.in
 t/custom_exception_class_simple.t
 t/custom_live_component_controller_action_auto_doublebug.t
@@ -266,7 +267,6 @@
 t/optional_apache-fastcgi-non-root.pl
 t/optional_apache-fastcgi.pl
 t/optional_http-server-restart.t
-t/optional_http-server.t
 t/optional_lighttpd-fastcgi-non-root.t
 t/optional_lighttpd-fastcgi.t
 t/optional_memleak.t
@@ -276,6 +276,7 @@
 t/plugin_new_method_backcompat.t
 t/something/Makefile.PL
 t/something/script/foo/bar/for_dist
+t/unit_controller_actions.t
 t/unit_controller_config.t
 t/unit_controller_namespace.t
 t/unit_core_action.t

Modified: trunk/libcatalyst-perl/META.yml
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/META.yml?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/META.yml (original)
+++ trunk/libcatalyst-perl/META.yml Mon Sep 14 15:21:09 2009
@@ -54,11 +54,11 @@
   URI: 1.35
   namespace::autoclean: 0
   namespace::clean: 0
-  perl: 5.8.6
+  perl: 5.8.4
 resources:
   IRC: irc://irc.perl.org/#catalyst
   MailingList: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
   homepage: http://dev.catalyst.perl.org/
   license: http://dev.perl.org/licenses/
   repository: http://dev.catalyst.perl.org/repos/Catalyst/Catalyst-Runtime/
-version: 5.80011
+version: 5.80012

Modified: trunk/libcatalyst-perl/Makefile.PL
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/Makefile.PL?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/Makefile.PL (original)
+++ trunk/libcatalyst-perl/Makefile.PL Mon Sep 14 15:21:09 2009
@@ -5,9 +5,10 @@
     if ($Module::Install::AUTHOR) {
         require Module::Install::AuthorRequires;
         require Module::Install::CheckConflicts;
+        require Module::Install::AuthorTests;
     }
 }
-perl_version '5.008006';
+perl_version '5.008004';
 
 name 'Catalyst-Runtime';
 all_from 'lib/Catalyst/Runtime.pm';
@@ -61,6 +62,7 @@
         map  { glob } qw[t/*.t t/aggregate/*.t];
 }
 
+author_tests 't/author';
 author_requires(map {; $_ => 0 } qw(
   Test::NoTabs
   Test::Pod

Modified: trunk/libcatalyst-perl/TODO
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/TODO?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/TODO (original)
+++ trunk/libcatalyst-perl/TODO Mon Sep 14 15:21:09 2009
@@ -14,7 +14,7 @@
 # Compatibility warnings to add:
 
   - $self->config should warn as config should only ever be called as a
-    class method.
+    class method (TESTS).
 
 # Proposed functionality / feature additions:
 
@@ -40,7 +40,7 @@
 ## App / ctx split:
 
   NOTE - these are notes that t0m thought up after doing back compat for
-         _component_class, may be inaccurate, wrong or missing things
+         catalyst_component_class, may be inaccurate, wrong or missing things
          bug mst (at least) to correct before trying more than the first 2
          steps. Please knock yourself out on the first two however :)
 
@@ -60,4 +60,3 @@
   - Profit! (Things like changing the complete app config per vhost, i.e.
     writing a config loader / app class role which dispatches per vhost to
     differently configured apps is piss easy)
-

Modified: trunk/libcatalyst-perl/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/debian/changelog?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/debian/changelog (original)
+++ trunk/libcatalyst-perl/debian/changelog Mon Sep 14 15:21:09 2009
@@ -1,3 +1,9 @@
+libcatalyst-perl (5.80012-1) UNRELEASED; urgency=low
+
+  * New upstream release
+
+ -- Krzysztof Krzyżaniak (eloy) <eloy at debian.org>  Mon, 14 Sep 2009 17:19:44 +0200
+
 libcatalyst-perl (5.80011-1) unstable; urgency=low
 
   [ Jonathan Yu ]

Modified: trunk/libcatalyst-perl/lib/Catalyst.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/lib/Catalyst.pm?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/lib/Catalyst.pm (original)
+++ trunk/libcatalyst-perl/lib/Catalyst.pm Mon Sep 14 15:21:09 2009
@@ -32,7 +32,7 @@
 use utf8;
 use Carp qw/croak carp shortmess/;
 
-BEGIN { require 5.008001; }
+BEGIN { require 5.008004; }
 
 has stack => (is => 'ro', default => sub { [] });
 has stash => (is => 'rw', default => sub { {} });
@@ -79,7 +79,7 @@
 
 # Remember to update this in Catalyst::Runtime as well!
 
-our $VERSION = '5.80011';
+our $VERSION = '5.80012';
 
 {
     my $dev_version = $VERSION =~ /_\d{2}$/;
@@ -646,7 +646,7 @@
 
 sub model {
     my ( $c, $name, @args ) = @_;
-
+    my $appclass = ref($c) || $c;
     if( $name ) {
         my @result = $c->_comp_search_prefixes( $name, qw/Model M/ );
         return map { $c->_filter_component( $_, @args ) } @result if ref $name;
@@ -659,8 +659,8 @@
         return $c->model( $c->stash->{current_model} )
           if $c->stash->{current_model};
     }
-    return $c->model( $c->config->{default_model} )
-      if $c->config->{default_model};
+    return $c->model( $appclass->config->{default_model} )
+      if $appclass->config->{default_model};
 
     my( $comp, $rest ) = $c->_comp_search_prefixes( undef, qw/Model M/);
 
@@ -700,6 +700,7 @@
 sub view {
     my ( $c, $name, @args ) = @_;
 
+    my $appclass = ref($c) || $c;
     if( $name ) {
         my @result = $c->_comp_search_prefixes( $name, qw/View V/ );
         return map { $c->_filter_component( $_, @args ) } @result if ref $name;
@@ -712,8 +713,8 @@
         return $c->view( $c->stash->{current_view} )
           if $c->stash->{current_view};
     }
-    return $c->view( $c->config->{default_view} )
-      if $c->config->{default_view};
+    return $c->view( $appclass->config->{default_view} )
+      if $appclass->config->{default_view};
 
     my( $comp, $rest ) = $c->_comp_search_prefixes( undef, qw/View V/);
 
@@ -1566,9 +1567,9 @@
 
 sub _stats_start_execute {
     my ( $c, $code ) = @_;
-
+    my $appclass = ref($c) || $c;
     return if ( ( $code->name =~ /^_.*/ )
-        && ( !$c->config->{show_internal_actions} ) );
+        && ( !$appclass->config->{show_internal_actions} ) );
 
     my $action_name = $code->reverse();
     $c->counter->{$action_name}++;
@@ -1882,7 +1883,7 @@
         $c->prepare_read;
 
         # Parse the body unless the user wants it on-demand
-        unless ( $c->config->{parse_on_demand} ) {
+        unless ( ref($c)->config->{parse_on_demand} ) {
             $c->prepare_body;
         }
     }
@@ -2153,6 +2154,7 @@
 
     my @comps = sort { length $a <=> length $b }
                 $class->locate_components($config);
+    my %comps = map { $_ => 1 } @comps;
 
     my $deprecatedcatalyst_component_names = grep { /::[CMV]::/ } @comps;
     $class->log->warn(qq{Your application is using the deprecated ::[MVC]:: type naming scheme.\n}.
@@ -2175,6 +2177,7 @@
     for my $component (@comps) {
         $class->components->{ $component } = $class->setup_component($component);
         for my $component ($class->expand_component_module( $component, $config )) {
+            next if $comps{$component};
             $class->_controller_init_base_classes($component); # Also cover inner packages
             $class->components->{ $component } = $class->setup_component($component);
         }
@@ -2221,7 +2224,7 @@
 
 sub expand_component_module {
     my ($class, $module) = @_;
-    Devel::InnerPackage::list_packages( $module );
+    return Devel::InnerPackage::list_packages( $module );
 }
 
 =head2 $c->setup_component
@@ -2757,7 +2760,7 @@
 
 Andrew Bramble
 
-Andrew Ford
+Andrew Ford E<lt>A.Ford at ford-mason.co.ukE<gt>
 
 Andrew Ruthven
 
@@ -2773,6 +2776,14 @@
 
 chicks: Christopher Hicks
 
+Chisel Wright C<pause at herlpacker.co.uk>
+
+Danijel Milicevic C<me at danijel.de>
+
+David Kamholz E<lt>dkamholz at cpan.orgE<gt>
+
+David Naughton, C<naughton at umn.edu>
+
 David E. Wheeler
 
 dkubb: Dan Kubb <dan.kubb-cpan at onautopilot.com>
@@ -2785,10 +2796,14 @@
 
 fireartist: Carl Franks <cfranks at cpan.org>
 
+frew: Arthur Axel "fREW" Schmidt <frioux at gmail.com>
+
 gabb: Danijel Milicevic
 
 Gary Ashton Jones
 
+Gavin Henry C<ghenry at perl.me.uk>
+
 Geoff Richards
 
 hobbs: Andrew Rodland <andrew at cleverdomain.org>
@@ -2797,7 +2812,7 @@
 
 jcamacho: Juan Camacho
 
-jester: Jesse Sheidlower
+jester: Jesse Sheidlower C<jester at panix.com>
 
 jhannah: Jay Hannah <jay at jays.net>
 
@@ -2807,6 +2822,10 @@
 
 jon: Jon Schutz <jjschutz at cpan.org>
 
+Jonathan Rockway C<< <jrockway at cpan.org> >>
+
+Kieren Diment C<kd at totaldatasolution.com>
+
 konobi: Scott McWhirter <konobi at cpan.org>
 
 marcus: Marcus Ramberg <mramberg at cpan.org>
@@ -2837,13 +2856,21 @@
 
 random: Roland Lammel <lammel at cpan.org>
 
+Robert Sedlacek C<< <rs at 474.at> >>
+
 sky: Arthur Bergman
 
 t0m: Tomas Doran <bobtfish at bobtfish.net>
 
 Ulf Edvinsson
 
+Viljo Marrandi C<vilts at yahoo.com>
+
+Will Hawes C<info at whawes.co.uk>
+
 willert: Sebastian Willert <willert at cpan.org>
+
+Yuval Kogman, C<nothingmuch at woobling.org>
 
 =head1 LICENSE
 

Modified: trunk/libcatalyst-perl/lib/Catalyst/ClassData.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/lib/Catalyst/ClassData.pm?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/lib/Catalyst/ClassData.pm (original)
+++ trunk/libcatalyst-perl/lib/Catalyst/ClassData.pm Mon Sep 14 15:21:09 2009
@@ -6,7 +6,7 @@
 use Moose::Util ();
 
 sub mk_classdata {
-  my ($class, $attribute) = @_;
+  my ($class, $attribute, $warn_on_instance) = @_;
   confess("mk_classdata() is a class method, not an object method")
     if blessed $class;
 

Modified: trunk/libcatalyst-perl/lib/Catalyst/Component.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/lib/Catalyst/Component.pm?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/lib/Catalyst/Component.pm (original)
+++ trunk/libcatalyst-perl/lib/Catalyst/Component.pm Mon Sep 14 15:21:09 2009
@@ -113,6 +113,8 @@
 
 sub config {
     my $self = shift;
+    # Uncomment once sane to do so
+    #Carp::cluck("config method called on instance") if ref $self;
     my $config = $self->_config || {};
     if (@_) {
         my $newconfig = { %{@_ > 1 ? {@_} : $_[0]} };

Modified: trunk/libcatalyst-perl/lib/Catalyst/Controller.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/lib/Catalyst/Controller.pm?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/lib/Catalyst/Controller.pm (original)
+++ trunk/libcatalyst-perl/lib/Catalyst/Controller.pm Mon Sep 14 15:21:09 2009
@@ -2,7 +2,7 @@
 
 use Moose;
 use Moose::Util qw/find_meta/;
-
+use List::MoreUtils qw/uniq/;
 use namespace::clean -except => 'meta';
 
 BEGIN { extends qw/Catalyst::Component MooseX::MethodAttributes::Inheritable/; }
@@ -29,9 +29,9 @@
      predicate => 'has_action_namespace',
     );
 
-has _controller_actions =>
+has actions =>
     (
-     is => 'rw',
+     accessor => '_controller_actions',
      isa => 'HashRef',
      init_arg => undef,
     );
@@ -137,21 +137,23 @@
     my $orig = shift;
     my ( $self, $c ) = @_;
 
+    my $class = ref($self) || $self;
+    my $appclass = ref($c) || $c;
     if( ref($self) ){
         return $self->$orig if $self->has_action_namespace;
     } else {
-        return $self->config->{namespace} if exists $self->config->{namespace};
+        return $class->config->{namespace} if exists $class->config->{namespace};
     }
 
     my $case_s;
     if( $c ){
-        $case_s = $c->config->{case_sensitive};
+        $case_s = $appclass->config->{case_sensitive};
     } else {
         if ($self->isa('Catalyst')) {
-            $case_s = $self->config->{case_sensitive};
+            $case_s = $class->config->{case_sensitive};
         } else {
             if (ref $self) {
-                $case_s = $self->_application->config->{case_sensitive};
+                $case_s = ref($self->_application)->config->{case_sensitive};
             } else {
                 confess("Can't figure out case_sensitive setting");
             }
@@ -198,7 +200,7 @@
                   . ( ref $self ) )
           } keys %{ $self->_controller_actions }
     ) if ( ref $self );
-    return @methods;
+    return uniq @methods;
 }
 
 

Modified: trunk/libcatalyst-perl/lib/Catalyst/Dispatcher.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/lib/Catalyst/Dispatcher.pm?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/lib/Catalyst/Dispatcher.pm (original)
+++ trunk/libcatalyst-perl/lib/Catalyst/Dispatcher.pm Mon Sep 14 15:21:09 2009
@@ -335,7 +335,7 @@
                 reverse   => "$component_class->$method",
                 class     => $component_class,
                 namespace => Catalyst::Utils::class2prefix(
-                    $component_class, $c->config->{case_sensitive}
+                    $component_class, ref($c)->config->{case_sensitive}
                 ),
             }
         );

Modified: trunk/libcatalyst-perl/lib/Catalyst/Engine.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/lib/Catalyst/Engine.pm?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/lib/Catalyst/Engine.pm (original)
+++ trunk/libcatalyst-perl/lib/Catalyst/Engine.pm Mon Sep 14 15:21:09 2009
@@ -112,7 +112,7 @@
     my ( $self, $c ) = @_;
 
     $c->res->content_type('text/html; charset=utf-8');
-    my $name = $c->config->{name} || join(' ', split('::', ref $c));
+    my $name = ref($c)->config->{name} || join(' ', split('::', ref $c));
 
     my ( $title, $error, $infos );
     if ( $c->debug ) {
@@ -317,13 +317,14 @@
 sub prepare_body {
     my ( $self, $c ) = @_;
 
+    my $appclass = ref($c) || $c;
     if ( my $length = $self->read_length ) {
         my $request = $c->request;
         unless ( $request->_body ) {
             my $type = $request->header('Content-Type');
             $request->_body(HTTP::Body->new( $type, $length ));
-            $request->_body->tmpdir( $c->config->{uploadtmp} )
-              if exists $c->config->{uploadtmp};
+            $request->_body->tmpdir( $appclass->config->{uploadtmp} )
+              if exists $appclass->config->{uploadtmp};
         }
 
         while ( my $buffer = $self->read($c) ) {

Modified: trunk/libcatalyst-perl/lib/Catalyst/Engine/CGI.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/lib/Catalyst/Engine/CGI.pm?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/lib/Catalyst/Engine/CGI.pm (original)
+++ trunk/libcatalyst-perl/lib/Catalyst/Engine/CGI.pm Mon Sep 14 15:21:09 2009
@@ -57,9 +57,9 @@
 
   PROXY_CHECK:
     {
-        unless ( $c->config->{using_frontend_proxy} ) {
+        unless ( ref($c)->config->{using_frontend_proxy} ) {
             last PROXY_CHECK if $ENV{REMOTE_ADDR} ne '127.0.0.1';
-            last PROXY_CHECK if $c->config->{ignore_frontend_proxy};
+            last PROXY_CHECK if ref($c)->config->{ignore_frontend_proxy};
         }
         last PROXY_CHECK unless $ENV{HTTP_X_FORWARDED_FOR};
 
@@ -126,9 +126,9 @@
     # If we are running as a backend proxy, get the true hostname
   PROXY_CHECK:
     {
-        unless ( $c->config->{using_frontend_proxy} ) {
+        unless ( ref($c)->config->{using_frontend_proxy} ) {
             last PROXY_CHECK if $host !~ /localhost|127.0.0.1/;
-            last PROXY_CHECK if $c->config->{ignore_frontend_proxy};
+            last PROXY_CHECK if ref($c)->config->{ignore_frontend_proxy};
         }
         last PROXY_CHECK unless $ENV{HTTP_X_FORWARDED_HOST};
 

Modified: trunk/libcatalyst-perl/lib/Catalyst/Request.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/lib/Catalyst/Request.pm?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/lib/Catalyst/Request.pm (original)
+++ trunk/libcatalyst-perl/lib/Catalyst/Request.pm Mon Sep 14 15:21:09 2009
@@ -237,8 +237,9 @@
 
 =head2 $req->body
 
-Returns the message body of the request, unless Content-Type is
-C<application/x-www-form-urlencoded> or C<multipart/form-data>.
+Returns the message body of the request, as returned by L<HTTP::Body>: a string,
+unless Content-Type is C<application/x-www-form-urlencoded>, C<text/xml>, or
+C<multipart/form-data>, in which case a L<File::Temp> object is returned.
 
 =head2 $req->body_parameters
 

Modified: trunk/libcatalyst-perl/lib/Catalyst/Runtime.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/lib/Catalyst/Runtime.pm?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/lib/Catalyst/Runtime.pm (original)
+++ trunk/libcatalyst-perl/lib/Catalyst/Runtime.pm Mon Sep 14 15:21:09 2009
@@ -3,11 +3,11 @@
 use strict;
 use warnings;
 
-BEGIN { require 5.008006; }
+BEGIN { require 5.008004; }
 
 # Remember to update this in Catalyst as well!
 
-our $VERSION='5.80011';
+our $VERSION='5.80012';
 
 $VERSION = eval $VERSION;
 

Modified: trunk/libcatalyst-perl/t/aggregate/live_component_controller_action_index_or_default.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/t/aggregate/live_component_controller_action_index_or_default.t?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/t/aggregate/live_component_controller_action_index_or_default.t (original)
+++ trunk/libcatalyst-perl/t/aggregate/live_component_controller_action_index_or_default.t Mon Sep 14 15:21:09 2009
@@ -10,9 +10,12 @@
 
 BEGIN { $iters = $ENV{CAT_BENCH_ITERS} || 1; }
 
-use Test::More tests => 6*$iters;
+use Test::More;
+use Catalyst::Test 'TestAppIndexDefault';
 
-use Catalyst::Test 'TestAppIndexDefault';
+plan 'skip_all' if ( $ENV{CATALYST_SERVER} );
+
+plan tests => 6*$iters;
 
 if ( $ENV{CAT_BENCHMARK} ) {
     require Benchmark;

Modified: trunk/libcatalyst-perl/t/aggregate/live_component_controller_action_path_matchsingle.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/t/aggregate/live_component_controller_action_path_matchsingle.t?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/t/aggregate/live_component_controller_action_path_matchsingle.t (original)
+++ trunk/libcatalyst-perl/t/aggregate/live_component_controller_action_path_matchsingle.t Mon Sep 14 15:21:09 2009
@@ -10,8 +10,12 @@
 
 BEGIN { $iters = $ENV{CAT_BENCH_ITERS} || 1; }
 
-use Test::More tests => 3*$iters;
+use Test::More;
 use Catalyst::Test 'TestAppMatchSingleArg';
+
+plan 'skip_all' if ( $ENV{CATALYST_SERVER} );
+
+plan tests => 3*$iters;
 
 if ( $ENV{CAT_BENCHMARK} ) {
     require Benchmark;

Modified: trunk/libcatalyst-perl/t/aggregate/live_component_controller_action_regexp.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/t/aggregate/live_component_controller_action_regexp.t?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/t/aggregate/live_component_controller_action_regexp.t (original)
+++ trunk/libcatalyst-perl/t/aggregate/live_component_controller_action_regexp.t Mon Sep 14 15:21:09 2009
@@ -131,8 +131,10 @@
             'TestApp::Controller::Action::Regexp',
             'Test Class'
         );
+        my $location = $response->header('location');
+        $location =~ s/localhost(:\d+)?/localhost/;
         is(
-            $response->header('location'),
+            $location,
             $url,
             'Redirect URI is the same as the request URI'
         );

Modified: trunk/libcatalyst-perl/t/aggregate/live_component_view_single.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/t/aggregate/live_component_view_single.t?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/t/aggregate/live_component_view_single.t (original)
+++ trunk/libcatalyst-perl/t/aggregate/live_component_view_single.t Mon Sep 14 15:21:09 2009
@@ -10,8 +10,12 @@
 
 BEGIN { $iters = $ENV{CAT_BENCH_ITERS} || 1; }
 
-use Test::More tests => 3*$iters;
+use Test::More;
 use Catalyst::Test 'TestAppOneView';
+
+plan 'skip_all' if ( $ENV{CATALYST_SERVER} );
+
+plan tests => 3*$iters;
 
 if ( $ENV{CAT_BENCHMARK} ) {
     require Benchmark;

Modified: trunk/libcatalyst-perl/t/aggregate/live_engine_request_escaped_path.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/t/aggregate/live_engine_request_escaped_path.t?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/t/aggregate/live_engine_request_escaped_path.t (original)
+++ trunk/libcatalyst-perl/t/aggregate/live_engine_request_escaped_path.t Mon Sep 14 15:21:09 2009
@@ -54,8 +54,6 @@
 }
 
 # test that request with URL-escaped code works.
-TODO: {
-    local $TODO = 'Actions should match when path parts are url encoded';
     my $request = Catalyst::Utils::request( 'http://localhost/args/param%73/one/two' );
     my $cgi     = HTTP::Request::AsCGI->new( $request, %ENV )->setup;
 
@@ -67,6 +65,8 @@
     TestApp->handle_request( env => \%ENV );
 
     ok( my $response = $cgi->restore->response );
+TODO: {
+    local $TODO = 'Actions should match when path parts are url encoded';
     ok( $response->is_success, 'Response Successful 2xx' );
     is( $response->content, 'onetwo' );
 }

Modified: trunk/libcatalyst-perl/t/aggregate/live_engine_request_remote_user.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/t/aggregate/live_engine_request_remote_user.t?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/t/aggregate/live_engine_request_remote_user.t (original)
+++ trunk/libcatalyst-perl/t/aggregate/live_engine_request_remote_user.t Mon Sep 14 15:21:09 2009
@@ -37,6 +37,11 @@
     }
 
     isa_ok( $creq, 'Catalyst::Request' );
-    
-    is( $creq->remote_user, 'dwc', '$c->req->remote_user ok' );
+    SKIP:
+    {
+        if ( $ENV{CATALYST_SERVER} ) {
+            skip 'Using remote server', 1;
+        }
+        is( $creq->remote_user, 'dwc', '$c->req->remote_user ok' );
+    }
 }

Modified: trunk/libcatalyst-perl/t/deprecated.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/t/deprecated.t?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/t/deprecated.t (original)
+++ trunk/libcatalyst-perl/t/deprecated.t Mon Sep 14 15:21:09 2009
@@ -16,6 +16,8 @@
 BEGIN {
     my $logger = Class::MOP::Class->create_anon_class(
     methods => {
+        debug => sub {0},
+        info  => sub {0},
         warn => sub {
             if ($_[1] =~ /switch your class names/) {
                $mvc_warnings++;

Modified: trunk/libcatalyst-perl/t/lib/TestApp.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/t/lib/TestApp.pm?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/t/lib/TestApp.pm (original)
+++ trunk/libcatalyst-perl/t/lib/TestApp.pm Mon Sep 14 15:21:09 2009
@@ -77,7 +77,7 @@
             @executed
         );
     }
-
+    no warnings 'recursion';
     return $c->SUPER::execute(@_);
 }
 
@@ -107,6 +107,7 @@
 
 sub recursion_test : Local {
     my ( $self, $c ) = @_;
+    no warnings 'recursion';
     $c->forward( 'recursion_test' );
 }
 

Modified: trunk/libcatalyst-perl/t/optional_http-server-restart.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/t/optional_http-server-restart.t?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/t/optional_http-server-restart.t (original)
+++ trunk/libcatalyst-perl/t/optional_http-server-restart.t Mon Sep 14 15:21:09 2009
@@ -45,10 +45,11 @@
 my $port = 30000 + int rand( 1 + 10000 );
 
 my( $server, $pid );
-$pid = open3( undef, $server, undef,
-  $^X, "-I$FindBin::Bin/../lib",
+my @cmd = ($^X, "-I$FindBin::Bin/../lib", "-I$FindBin::Bin/lib",
   "$FindBin::Bin/../t/tmp/TestApp/script/testapp_server.pl", '-port',
-  $port, '-restart' )
+  $port, '-restart');
+
+$pid = open3( undef, $server, undef, @cmd )
     or die "Unable to spawn standalone HTTP server: $!";
 
 # switch to non-blocking reads so we can fail
@@ -67,10 +68,8 @@
     "$FindBin::Bin/../t/tmp/TestApp/lib/TestApp.pm",
     "$FindBin::Bin/../t/tmp/TestApp/lib/TestApp/Controller/Action/Begin.pm",
     "$FindBin::Bin/../t/tmp/TestApp/lib/TestApp/Controller/Immutable.pm",
+    "$FindBin::Bin/../t/tmp/TestApp/lib/TestApp/Controller/Immutable/HardToReload.pm",
 );
-
-push(@files, "$FindBin::Bin/../t/tmp/TestApp/lib/TestApp/Controller/Immutable/HardToReload.pm")
-    if Catalyst::Engine::HTTP::Restarter::Watcher::DETECT_PACKAGE_COMPILATION();
 
 # change some files and make sure the server restarts itself
 NON_ERROR_RESTART:
@@ -84,7 +83,6 @@
     # give the server time to notice the change and restart
     my $count = 0;
     my $line;
-
     while ( ( $line || '' ) !~ /can connect/ ) {
         # wait for restart message
         $line = $server->getline;

Modified: trunk/libcatalyst-perl/t/unit_core_classdata.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/t/unit_core_classdata.t?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/t/unit_core_classdata.t (original)
+++ trunk/libcatalyst-perl/t/unit_core_classdata.t Mon Sep 14 15:21:09 2009
@@ -100,3 +100,7 @@
 is(refaddr(ClassDataTest->_scalarref), refaddr($scalarref3));
 is(refaddr(ClassDataTest->_coderef), refaddr($coderef3));
 is(ClassDataTest->_scalar, $scalar3);
+
+my $i = bless {}, 'ClassDataTest';
+$i->_scalar('foo');
+

Modified: trunk/libcatalyst-perl/t/unit_core_component_loading.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/t/unit_core_component_loading.t?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/t/unit_core_component_loading.t (original)
+++ trunk/libcatalyst-perl/t/unit_core_component_loading.t Mon Sep 14 15:21:09 2009
@@ -2,7 +2,7 @@
 # (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 => 2 + 6 * 24 + 7 + 1;
+use Test::More tests => 2 + 6 * 24 + 8 + 1;
 
 use strict;
 use warnings;
@@ -193,8 +193,10 @@
 package ${appclass}::Model::TopLevel::Nested;
 use base 'Catalyst::Model';
 
+my \$called=0;
 no warnings 'redefine';
-sub COMPONENT { return shift->next::method(\@_); }
+sub COMPONENT { \$called++;return shift->next::method(\@_); }
+sub called { return \$called };
 1;
 
 EOF
@@ -202,6 +204,7 @@
 eval "package $appclass; use Catalyst; __PACKAGE__->setup";
 
 is($@, '', "Didn't load component twice");
+is($appclass->model('TopLevel::Nested')->called,1, 'COMPONENT called once');
 
 ok($appclass->model('TopLevel::Generated'), 'Have generated model');
 is(ref($appclass->model('TopLevel::Generated')), 'FooBarBazQuux',

Modified: trunk/libcatalyst-perl/t/unit_core_plugin.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/t/unit_core_plugin.t?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/t/unit_core_plugin.t (original)
+++ trunk/libcatalyst-perl/t/unit_core_plugin.t Mon Sep 14 15:21:09 2009
@@ -21,6 +21,9 @@
 use PluginTestApp;
 my $logger = Class::MOP::Class->create_anon_class(
     methods => {
+        error => sub {0},
+        debug => sub {0},
+        info => sub {0},
         warn => sub {
             if ($_[1] =~ /plugin method is deprecated/) {
                $warnings++;
@@ -40,6 +43,8 @@
 #         for Catalyst 5.9
 ok( get("/run_time_plugins"),     "get ok" );
 
+local $ENV{CATALYST_DEBUG} = 0;
+
 is( $warnings, 1, '1 warning' );
 
 use_ok 'TestApp';
@@ -56,3 +61,4 @@
 # Faux::Plugin is no longer reported
 is_deeply [ TestApp->registered_plugins ], \@expected,
   'registered_plugins() should only report the plugins for the current class';
+

Modified: trunk/libcatalyst-perl/t/unit_core_setup_stats.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcatalyst-perl/t/unit_core_setup_stats.t?rev=44095&op=diff
==============================================================================
--- trunk/libcatalyst-perl/t/unit_core_setup_stats.t (original)
+++ trunk/libcatalyst-perl/t/unit_core_setup_stats.t Mon Sep 14 15:21:09 2009
@@ -22,7 +22,6 @@
 sub mock_app {
     my $name = shift;
     %log_messages = (); # Flatten log messages.
-    diag "Setting up mock application: $name";
     my $meta = Moose->init_meta( for_class => $name );
     $meta->superclasses('Catalyst');
     $meta->add_method('log', sub { $mock_log }); 




More information about the Pkg-perl-cvs-commits mailing list