summaryrefslogtreecommitdiff
path: root/ext/zlib/tests
diff options
context:
space:
mode:
authorStanislav Malyshev <stas@php.net>2012-01-01 23:51:21 (GMT)
committerStanislav Malyshev <stas@php.net>2012-01-01 23:51:21 (GMT)
commit0fdbefa4302bb69e0d9524a17de92c407635bd7e (patch)
treee3acfb70b6b2d4384eee25e6ba6d8d3d09a59f12 /ext/zlib/tests
parent3a06ca721c10d72e7df44eeee0912fcb29ed8f08 (diff)
downloadphp-0fdbefa4302bb69e0d9524a17de92c407635bd7e.tar.gz
add test for ob_gzhandler
Diffstat (limited to 'ext/zlib/tests')
-rw-r--r--ext/zlib/tests/ob_gzhandler_legacy_002.phpt24
1 files changed, 24 insertions, 0 deletions
diff --git a/ext/zlib/tests/ob_gzhandler_legacy_002.phpt b/ext/zlib/tests/ob_gzhandler_legacy_002.phpt
new file mode 100644
index 0000000..dad2821
--- /dev/null
+++ b/ext/zlib/tests/ob_gzhandler_legacy_002.phpt
@@ -0,0 +1,24 @@
+--TEST--
+ob_gzhandler legacy
+--SKIPIF--
+<?php
+if (!extension_loaded("zlib")) die("skip need ext/zlib");
+if (false === stristr(PHP_SAPI, "cgi")) die("skip need sapi/cgi");
+?>
+--INI--
+zlib.output_compression=0
+--ENV--
+HTTP_ACCEPT_ENCODING=
+--POST--
+dummy=42
+--FILE--
+<?php
+if (false !== ob_gzhandler("", PHP_OUTPUT_HANDLER_START)) {
+ ini_set("zlib.output_compression", 0);
+ ob_start("ob_gzhandler");
+}
+echo "hi\n";
+?>
+--EXPECTF--
+hi
+--EXPECTHEADERS--