include our own leak checking code rather than using CatalystX::LeakCheck
[catagits/Catalyst-Runtime.git] / t / query_keywords_and_parameters.t
index ba8938b..6801cf0 100644 (file)
@@ -25,11 +25,10 @@ use Catalyst::Test 'MyApp';
 
 # These tests assume that the decoding that occurs for the query string follows
 # the payload decoding algorithm described here:
-# https://www.w3.org/TR/html5/forms.html#url-encoded-form-data 
+# https://www.w3.org/TR/html5/forms.html#url-encoded-form-data
 
 {
-  ok my $req = GET 'root/bar',
-    'Content-Type' => 'application/x-www-form-urlencoded';
+  ok my $req = GET 'root/bar';
 
   my ($res, $c) = ctx_request($req);
 
@@ -39,19 +38,17 @@ use Catalyst::Test 'MyApp';
 
 
 {
-  ok my $req = GET 'root/bar?',
-    'Content-Type' => 'application/x-www-form-urlencoded';
+  ok my $req = GET 'root/bar?';
 
   my ($res, $c) = ctx_request($req);
 
-  is $c->req->query_keywords, '', 'query_keywords is not defined with empty query string';
+  ok !defined $c->req->query_keywords, 'query_keywords is not defined when ? with empty query string';
   is_deeply $c->req->query_parameters, {}, 'query_parameters defined, but empty with empty query string';
 }
 
 
 {
-  ok my $req = GET 'root/bar?a=b',
-    'Content-Type' => 'application/x-www-form-urlencoded';
+  ok my $req = GET 'root/bar?a=b';
 
   my ($res, $c) = ctx_request($req);
 
@@ -61,8 +58,7 @@ use Catalyst::Test 'MyApp';
 
 
 {
-  ok my $req = GET 'root/bar?x',
-    'Content-Type' => 'application/x-www-form-urlencoded';
+  ok my $req = GET 'root/bar?x';
 
   my ($res, $c) = ctx_request($req);
 
@@ -75,8 +71,7 @@ use Catalyst::Test 'MyApp';
 
 
 {
-  ok my $req = GET 'root/bar?x&a=b',
-    'Content-Type' => 'application/x-www-form-urlencoded';
+  ok my $req = GET 'root/bar?x&a=b';
 
   my ($res, $c) = ctx_request($req);