Add stringify back for action, and test
[catagits/Catalyst-Runtime.git] / t / live_engine_request_uri.t
index fe15e9d..01a19fa 100644 (file)
@@ -6,7 +6,7 @@ use warnings;
 use FindBin;
 use lib "$FindBin::Bin/lib";
 
-use Test::More tests => 54;
+use Test::More tests => 49;
 use Catalyst::Test 'TestApp';
 use Catalyst::Request;
 
@@ -62,8 +62,8 @@ SKIP:
     ok( my $response = request('http://localhost/engine/request/uri?a=1;a=2;b=3'), 'Request' );
     ok( $response->is_success, 'Response Successful 2xx' );
     ok( eval '$creq = ' . $response->content, 'Unserialize Catalyst::Request' );
-    is( $creq->{uri}->query, 'a=1;a=2;b=3', 'Query string ok' );
-    is_deeply( $creq->{parameters}, $parameters, 'Parameters ok' );
+    is( $creq->uri->query, 'a=1;a=2;b=3', 'Query string ok' );
+    is_deeply( $creq->parameters, $parameters, 'Parameters ok' );
 }
 
 # test that query params are unescaped properly
@@ -71,8 +71,8 @@ SKIP:
     ok( my $response = request('http://localhost/engine/request/uri?text=Catalyst%20Rocks'), 'Request' );
     ok( $response->is_success, 'Response Successful 2xx' );
     ok( eval '$creq = ' . $response->content, 'Unserialize Catalyst::Request' );
-    is( $creq->{uri}->query, 'text=Catalyst%20Rocks', 'Query string ok' );
-    is( $creq->{parameters}->{text}, 'Catalyst Rocks', 'Unescaped param ok' );
+    is( $creq->uri->query, 'text=Catalyst%20Rocks', 'Query string ok' );
+    is( $creq->parameters->{text}, 'Catalyst Rocks', 'Unescaped param ok' );
 }
 
 # test that uri_with adds params
@@ -120,12 +120,3 @@ SKIP:
     is( $response->header( 'X-Catalyst-warnings' ), 0, 'no warnings emitted' );
 }
 
-
-# test that query params are unescaped properly with '+'
-{
-    ok( my $response = request('http://localhost/engine/request/uri?text=C%2B%2B+lang'), 'Request' );
-    ok( $response->is_success, 'Response Successful 2xx' );
-    ok( eval '$creq = ' . $response->content, 'Unserialize Catalyst::Request' );
-    is( $creq->{uri}->query, 'text=C%2B%2B+lang', 'Query string ok' );
-    is( $creq->{parameters}->{text}, 'C++ lang', 'Unescaped param has pluses in it' );
-}