[Catalyst-commits] r8276 - Catalyst-Runtime/5.70/trunk/t

rafl at dev.catalyst.perl.org rafl at dev.catalyst.perl.org
Sun Aug 24 20:32:21 BST 2008


Author: rafl
Date: 2008-08-24 20:32:21 +0100 (Sun, 24 Aug 2008)
New Revision: 8276

Modified:
   Catalyst-Runtime/5.70/trunk/t/live_component_controller_action_chained.t
Log:
Test :Chained('../../action').

Modified: Catalyst-Runtime/5.70/trunk/t/live_component_controller_action_chained.t
===================================================================
--- Catalyst-Runtime/5.70/trunk/t/live_component_controller_action_chained.t	2008-08-24 19:32:14 UTC (rev 8275)
+++ Catalyst-Runtime/5.70/trunk/t/live_component_controller_action_chained.t	2008-08-24 19:32:21 UTC (rev 8276)
@@ -10,7 +10,7 @@
 
 BEGIN { $iters = $ENV{CAT_BENCH_ITERS} || 1; }
 
-use Test::More tests => 138*$iters;
+use Test::More tests => 141*$iters;
 use Catalyst::Test 'TestApp';
 
 if ( $ENV{CAT_BENCHMARK} ) {
@@ -548,6 +548,27 @@
     }
 
     #
+    #   Test if ../ works to go up more than one level
+    #
+    {
+        local $TODO = 'to be coded';
+        my @expected = qw[
+            TestApp::Controller::Action::Chained->begin
+            TestApp::Controller::Action::Chained->one
+            TestApp::Controller::Action::Chained::ParentChain::Relative->chained_rel_two
+            TestApp::Controller::Action::Chained->end
+        ];
+
+        my $expected = join( ", ", @expected );
+
+        ok( my $response = request('http://localhost/chained/one/1/chained_rel_two/42/23'),
+            "../ works to go up more than one level" );
+        is( $response->header('X-Catalyst-Executed'),
+            $expected, 'Executed actions' );
+        is( $response->content, '1; 42, 23', 'Content OK' );
+    }
+
+    #
     #   Test if :ChainedParent is working
     #
     {




More information about the Catalyst-commits mailing list