branch off v1 as R_1_7
[m6w6/ext-http] / tests / etag_mode_034.phpt
index b8bb04d9f068d7df17106af9e24d315bbc697c67..f97bda931c6221dd1697afc347ce6da9c4f3a40c 100644 (file)
@@ -1,25 +1,24 @@
 --TEST--
-mhash etag
+ext/hash etag
 --SKIPIF--
 <?php
 include 'skip.inc';
 checkcgi();
-checkmax(5.0);
-skipif(!http_support(HTTP_SUPPORT_MHASHETAGS), 'need mhash support');
-skipif(!defined('HTTP_ETAG_MHASH_WHIRLPOOL'), 'need whirlpool mhash support');
+checkmin("5.2.5");
+skipif(!extension_loaded('hash'), 'need ext/hash support');
 ?>
 --FILE--
 <?php
-ini_set('http.etag_mode', HTTP_ETAG_MHASH_WHIRLPOOL);
+ini_set('http.etag.mode', 'sha256');
 http_cache_etag();
 http_send_data("abc\n");
 ?>
 --EXPECTF--
-Content-type: %s
-X-Powered-By: PHP/%s
+X-Powered-By: PHP/%a
 Cache-Control: private, must-revalidate, max-age=0
 Accept-Ranges: bytes
-ETag: "53efa9e423f86dabd449b3e23dd0350def661b9e7055b23ceb2230c8b61bc0766514957ea9d349a88ef794715a1a17a409b549edfd6f43d696e63407fff3541c"
+ETag: "edeaaff3f1774ad2888673770c6d64097e391bc362d7d6fb34982ddf0efd18cb"
 Content-Length: 4
+Content-type: %a
 
 abc