reworked test

This commit is contained in:
Florian Engelhardt 2017-09-14 12:41:02 +02:00
parent 5e55ce30df
commit 8158a95b53
4 changed files with 26 additions and 18 deletions

View File

@ -6,11 +6,13 @@ PHP TestFest 2017 - Bergfreunde, Florian Engelhardt <florian.engelhardt@bergfreu
<?php if (!extension_loaded("zlib")) print "skip"; ?>
--FILE--
<?php
ini_set('zlib.output_compression', 'On');
$enc = zlib_get_coding_type();
ini_set('zlib.output_compression', 'Off');
var_dump($enc);
var_dump(zlib_get_coding_type());
$encOff = zlib_get_coding_type();
ini_set('zlib.output_compression', 'On');
$encOn = zlib_get_coding_type();
ini_set('zlib.output_compression', 'Off');
var_dump($encOff);
var_dump($encOn);
?>
--EXPECT--
bool(false)

View File

@ -8,11 +8,13 @@ PHP TestFest 2017 - Bergfreunde, Florian Engelhardt <florian.engelhardt@bergfreu
HTTP_ACCEPT_ENCODING=br
--FILE--
<?php
ini_set('zlib.output_compression', 'On');
$enc = zlib_get_coding_type();
ini_set('zlib.output_compression', 'Off');
var_dump($enc);
var_dump(zlib_get_coding_type());
$encOff = zlib_get_coding_type();
ini_set('zlib.output_compression', 'On');
$encOn = zlib_get_coding_type();
ini_set('zlib.output_compression', 'Off');
var_dump($encOff);
var_dump($encOn);
?>
--EXPECT--
bool(false)

View File

@ -8,12 +8,14 @@ PHP TestFest 2017 - Bergfreunde, Florian Engelhardt <florian.engelhardt@bergfreu
HTTP_ACCEPT_ENCODING=deflate
--FILE--
<?php
ini_set('zlib.output_compression', 'On');
$enc = zlib_get_coding_type();
ini_set('zlib.output_compression', 'Off');
var_dump($enc);
var_dump(zlib_get_coding_type());
$encOff = zlib_get_coding_type();
ini_set('zlib.output_compression', 'On');
$encOn = zlib_get_coding_type();
ini_set('zlib.output_compression', 'Off');
var_dump($encOff);
var_dump($encOn);
?>
--EXPECT--
string(7) "deflate"
bool(false)
string(7) "deflate"

View File

@ -8,12 +8,14 @@ PHP TestFest 2017 - Bergfreunde, Florian Engelhardt <florian.engelhardt@bergfreu
HTTP_ACCEPT_ENCODING=gzip
--FILE--
<?php
ini_set('zlib.output_compression', 'On');
$enc = zlib_get_coding_type();
ini_set('zlib.output_compression', 'Off');
var_dump($enc);
var_dump(zlib_get_coding_type());
$encOff = zlib_get_coding_type();
ini_set('zlib.output_compression', 'On');
$encOn = zlib_get_coding_type();
ini_set('zlib.output_compression', 'Off');
var_dump($encOff);
var_dump($encOn);
?>
--EXPECT--
string(4) "gzip"
bool(false)
string(4) "gzip"