From ced5bb7d88b48dbc9b98a2d24e3ee586fe65651a Mon Sep 17 00:00:00 2001 From: Fabien Villepinte Date: Tue, 3 Sep 2019 22:54:41 +0200 Subject: Add the last missing SKIPIF --- ext/bz2/bug71263.phpt | 53 -------------------------- ext/bz2/tests/bug71263.phpt | 55 +++++++++++++++++++++++++++ ext/intl/tests/bug77895.phpt | 2 + ext/intl/tests/dateformat_bug65683_2.phpt | 2 + ext/json/tests/bug77843.phpt | 2 + ext/session/tests/bug71162.phpt | 2 + ext/session/tests/bug74892.phpt | 2 + ext/tokenizer/no_inline_html_split.phpt | 24 ------------ ext/tokenizer/tests/bad_character.phpt | 2 + ext/tokenizer/tests/bug76991.phpt | 2 + ext/tokenizer/tests/no_inline_html_split.phpt | 26 +++++++++++++ ext/tokenizer/tests/php_tag_only.phpt | 2 + ext/zlib/tests/bug71417.phpt | 2 + 13 files changed, 99 insertions(+), 77 deletions(-) delete mode 100644 ext/bz2/bug71263.phpt create mode 100644 ext/bz2/tests/bug71263.phpt delete mode 100644 ext/tokenizer/no_inline_html_split.phpt create mode 100644 ext/tokenizer/tests/no_inline_html_split.phpt diff --git a/ext/bz2/bug71263.phpt b/ext/bz2/bug71263.phpt deleted file mode 100644 index 387c06bfdb..0000000000 --- a/ext/bz2/bug71263.phpt +++ /dev/null @@ -1,53 +0,0 @@ ---TEST-- -Bug #71263: fread() does not detects decoding errors from filter bzip2.decompress ---FILE-- - php_bz2_decompress_filter() detects fatal error - // --> fread() displays empty string then garbage, no errors detected: - $compressed[strlen($compressed) - 15] = 'X'; - } else if ($case == 2) { - // Truncate the compressed data - // --> php_bz2_decompress_filter() does not detect errors, - // --> fread() displays the empty string: - $compressed = substr($compressed, 0, strlen($compressed) - 20); - } else { - // Corrupted final CRC - // --> php_bz2_decompress_filter() detects fatal error - // --> fread() displays an empty string, then the correct plain text, no error detected: - $compressed[strlen($compressed)-2] = 'X'; - } - - file_put_contents($fn, $compressed); - - $r = fopen($fn, "r"); - stream_filter_append($r, 'bzip2.decompress', STREAM_FILTER_READ); - while (!feof($r)) { - $s = fread($r, 100); - echo "read: "; var_dump($s); - } - fclose($r); - unlink($fn); -} - -test(1); -test(2); -test(3); -?> ---EXPECT-- -Compressed len = 81 -read: bool(false) -Compressed len = 81 -read: string(0) "" -Compressed len = 81 -read: bool(false) diff --git a/ext/bz2/tests/bug71263.phpt b/ext/bz2/tests/bug71263.phpt new file mode 100644 index 0000000000..d5c3ff91da --- /dev/null +++ b/ext/bz2/tests/bug71263.phpt @@ -0,0 +1,55 @@ +--TEST-- +Bug #71263: fread() does not detects decoding errors from filter bzip2.decompress +--SKIPIF-- + +--FILE-- + php_bz2_decompress_filter() detects fatal error + // --> fread() displays empty string then garbage, no errors detected: + $compressed[strlen($compressed) - 15] = 'X'; + } else if ($case == 2) { + // Truncate the compressed data + // --> php_bz2_decompress_filter() does not detect errors, + // --> fread() displays the empty string: + $compressed = substr($compressed, 0, strlen($compressed) - 20); + } else { + // Corrupted final CRC + // --> php_bz2_decompress_filter() detects fatal error + // --> fread() displays an empty string, then the correct plain text, no error detected: + $compressed[strlen($compressed)-2] = 'X'; + } + + file_put_contents($fn, $compressed); + + $r = fopen($fn, "r"); + stream_filter_append($r, 'bzip2.decompress', STREAM_FILTER_READ); + while (!feof($r)) { + $s = fread($r, 100); + echo "read: "; var_dump($s); + } + fclose($r); + unlink($fn); +} + +test(1); +test(2); +test(3); +?> +--EXPECT-- +Compressed len = 81 +read: bool(false) +Compressed len = 81 +read: string(0) "" +Compressed len = 81 +read: bool(false) diff --git a/ext/intl/tests/bug77895.phpt b/ext/intl/tests/bug77895.phpt index 18b4f778e6..17a86fd410 100644 --- a/ext/intl/tests/bug77895.phpt +++ b/ext/intl/tests/bug77895.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #77895: IntlDateFormatter::create fails in strict mode if $locale = null +--SKIPIF-- + --FILE-- --FILE-- --FILE-- --INI-- session.use_strict_mode=0 session.save_handler=files diff --git a/ext/session/tests/bug74892.phpt b/ext/session/tests/bug74892.phpt index a4c977828a..0947df7761 100644 --- a/ext/session/tests/bug74892.phpt +++ b/ext/session/tests/bug74892.phpt @@ -1,5 +1,7 @@ --TEST-- Bug #74892 Url Rewriting (trans_sid) not working on urls that start with # +--SKIPIF-- + --FILE-- ---EXPECTF-- -array(1) { - [0]=> - array(3) { - [0]=> - int(%d) - [1]=> - string(11) "Foo - int(1) - } -} diff --git a/ext/tokenizer/tests/bad_character.phpt b/ext/tokenizer/tests/bad_character.phpt index 0c6b1136a6..87f0179004 100644 --- a/ext/tokenizer/tests/bad_character.phpt +++ b/ext/tokenizer/tests/bad_character.phpt @@ -1,5 +1,7 @@ --TEST-- token_get_all() produces T_BAD_CHARACTER for unexpected characters +--SKIPIF-- + --FILE-- --FILE-- +--INI-- +short_open_tag=0 +--FILE-- + +--EXPECTF-- +array(1) { + [0]=> + array(3) { + [0]=> + int(%d) + [1]=> + string(11) "Foo + int(1) + } +} diff --git a/ext/tokenizer/tests/php_tag_only.phpt b/ext/tokenizer/tests/php_tag_only.phpt index a6df7ded4d..aec11f9e16 100644 --- a/ext/tokenizer/tests/php_tag_only.phpt +++ b/ext/tokenizer/tests/php_tag_only.phpt @@ -1,5 +1,7 @@ --TEST-- Tokenization of only the --FILE-- --FILE--