release 1.7.5
[m6w6/ext-http] / tests / request_gzip.phpt
index 7a9f027..3c5ae6f 100644 (file)
@@ -4,17 +4,18 @@ GZIP request
 <?php
 include 'skip.inc';
 checkurl('dev.iworks.at');
+skipif(!http_support(HTTP_SUPPORT_REQUESTS), 'need curl support');
 ?>
 --FILE--
 <?php
 echo "-TEST\n";
 
-var_dump(http_parse_message(http_get('http://dev.iworks.at/.print_request.php?gzip=1', array('compress' => true))));
+var_dump(http_parse_message(http_get('http://dev.iworks.at/ext-http/.print_request.php?gzip=1', array('compress' => true))));
 
 echo "Done\n";
 --EXPECTF--
-%sTEST
-object(stdClass)#%d (%d) {
+%aTEST
+object(stdClass)%a {
   ["type"]=>
   int(2)
   ["httpVersion"]=>
@@ -24,22 +25,29 @@ object(stdClass)#%d (%d) {
   ["responseStatus"]=>
   string(2) "OK"
   ["headers"]=>
-  array(6) {
-    %s
+  array(%d) {
+    %a
     ["Vary"]=>
     string(15) "Accept-Encoding"
     ["Content-Type"]=>
     string(9) "text/html"
+    ["X-Original-Transfer-Encoding"]=>
+    string(7) "chunked"
     ["Content-Length"]=>
-    string(2) "27"
+    string(2) "26"
+    ["X-Original-Content-Encoding"]=>
+    string(4) "gzip"
+    ["X-Original-Content-Length"]=>
+    string(2) "51"
   }
   ["body"]=>
-  string(27) "Array
+  string(26) "Array
 (
     [gzip] => 1
 )
-
 "
   ["parentMessage"]=>
   NULL
-}Done
+}
+Done
+