From: Gabriel Caruso Date: Sat, 3 Feb 2018 15:51:22 +0000 (-0200) Subject: Remove superfluous PHP version check in tests X-Git-Tag: php-7.3.0alpha1~479 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=9a4cc52c23bfe2c11f29b578c4d5e324e0fe9b0c;p=php Remove superfluous PHP version check in tests Also remove tests that target only old PHP versions. --- diff --git a/ext/date/tests/DateTimeZone_getLocation.phpt b/ext/date/tests/DateTimeZone_getLocation.phpt index 011f0460f3..06d22820f1 100644 --- a/ext/date/tests/DateTimeZone_getLocation.phpt +++ b/ext/date/tests/DateTimeZone_getLocation.phpt @@ -2,12 +2,6 @@ DateTimeZone::getLocation -- timezone_location_get — Returns location information for a timezone public array DateTimeZone::getLocation ( void ) ; --CREDITS-- marcosptf - - #phparty7 - @phpsp - novatec/2015 - sao paulo - br ---SKIPIF-- - --FILE-- - @phpsp - sao paulo - br --SKIPIF-- ?> --FILE-- diff --git a/ext/mysqli/tests/mysqli_class_mysqli_driver_reflection.phpt b/ext/mysqli/tests/mysqli_class_mysqli_driver_reflection.phpt index 2e6d9c2fd1..11c3492817 100644 --- a/ext/mysqli/tests/mysqli_class_mysqli_driver_reflection.phpt +++ b/ext/mysqli/tests/mysqli_class_mysqli_driver_reflection.phpt @@ -5,8 +5,6 @@ Interface of the class mysqli_driver - Reflection require_once('skipif.inc'); require_once('skipifemb.inc'); require_once('connect.inc'); -if (($tmp = substr(PHP_VERSION, 0, strpos(PHP_VERSION, '.'))) && ($tmp < 5)) - die("skip Reflection not available before PHP 5 (found PHP $tmp)"); /* Let's not deal with cross-version issues in the EXPECTF/UEXPECTF. diff --git a/ext/mysqli/tests/mysqli_class_mysqli_result_reflection.phpt b/ext/mysqli/tests/mysqli_class_mysqli_result_reflection.phpt index 89be46fb8a..75a8e8cfcb 100644 --- a/ext/mysqli/tests/mysqli_class_mysqli_result_reflection.phpt +++ b/ext/mysqli/tests/mysqli_class_mysqli_result_reflection.phpt @@ -7,9 +7,6 @@ require_once('skipifemb.inc'); require_once('skipifconnectfailure.inc'); require_once('connect.inc'); -if (($tmp = substr(PHP_VERSION, 0, strpos(PHP_VERSION, '.'))) && ($tmp < 5)) - die("skip Reflection not available before PHP 5 (found PHP $tmp)"); - /* Let's not deal with cross-version issues in the EXPECTF/UEXPECTF. Most of the things which we test are covered by mysqli_class_*_interface.phpt. diff --git a/ext/mysqli/tests/mysqli_class_mysqli_warning_reflection.phpt b/ext/mysqli/tests/mysqli_class_mysqli_warning_reflection.phpt index dc0c14e6e8..8ad12737a7 100644 --- a/ext/mysqli/tests/mysqli_class_mysqli_warning_reflection.phpt +++ b/ext/mysqli/tests/mysqli_class_mysqli_warning_reflection.phpt @@ -6,9 +6,6 @@ require_once('skipif.inc'); require_once('skipifemb.inc'); require_once('connect.inc'); -if (($tmp = substr(PHP_VERSION, 0, strpos(PHP_VERSION, '.'))) && ($tmp < 5)) - die("skip Reflection not available before PHP 5 (found PHP $tmp)"); - /* Let's not deal with cross-version issues in the EXPECTF/UEXPECTF. Most of the things which we test are covered by mysqli_class_*_interface.phpt. diff --git a/ext/phar/tests/fopen.phpt b/ext/phar/tests/fopen.phpt index 5b694d6e2d..b55bc59c84 100644 --- a/ext/phar/tests/fopen.phpt +++ b/ext/phar/tests/fopen.phpt @@ -2,7 +2,6 @@ Phar: test fopen() interception --SKIPIF-- -= 5.3 required for this test");?> --INI-- phar.require_hash=1 phar.readonly=0 @@ -40,4 +39,4 @@ include $fname; Warning: fopen() expects at least 2 parameters, 0 given in %sfopen.php on line %d hihi Warning: fopen(notfound.txt): failed to open stream: No such file or directory in phar://%sfopen.phar.php/index.php on line %d -===DONE=== \ No newline at end of file +===DONE=== diff --git a/ext/phar/tests/fopen5.2.phpt b/ext/phar/tests/fopen5.2.phpt deleted file mode 100644 index aa064f1662..0000000000 --- a/ext/phar/tests/fopen5.2.phpt +++ /dev/null @@ -1,43 +0,0 @@ ---TEST-- -Phar: test fopen() interception ---SKIPIF-- - - ---INI-- -phar.require_hash=1 -phar.readonly=0 ---FILE-- -'; -$a['dir/file1.txt'] = 'hi'; -$a['dir/file2.txt'] = 'hi2'; -$a['dir/file3.txt'] = 'hi3'; -$a->setStub(' -===DONE=== ---CLEAN-- - ---EXPECTF-- -Warning: fopen() expects at least 2 parameters, 0 given in %sfopen5.2.php on line %d -hihi -Warning: fopen(phar://%sfopen5.2.phar.php/notfound.txt): failed to open stream: phar error: "notfound.txt" is not a file in phar "%sfopen5.2.phar.php" in phar://%sfopen5.2.phar.php/index.php on line %d -===DONE=== \ No newline at end of file diff --git a/ext/phar/tests/fopen_edgecases2.phpt b/ext/phar/tests/fopen_edgecases2.phpt index 4510fbd801..4ac529a4e0 100644 --- a/ext/phar/tests/fopen_edgecases2.phpt +++ b/ext/phar/tests/fopen_edgecases2.phpt @@ -2,7 +2,6 @@ Phar: test edge cases of fopen() function interception #2 --SKIPIF-- -=')) die('skip parameter parsing changed in 6.0'); ?> --INI-- phar.readonly=0 --FILE-- diff --git a/ext/phar/tests/stat2.phpt b/ext/phar/tests/stat2.phpt deleted file mode 100644 index defda719f3..0000000000 --- a/ext/phar/tests/stat2.phpt +++ /dev/null @@ -1,61 +0,0 @@ ---TEST-- -Phar: test stat function interceptions and is_file/is_link edge cases (PHP 5.2) ---SKIPIF-- - - ---INI-- -phar.readonly=0 -phar.require_hash=0 ---FILE-- -convertToExecutable(); -unset($a); -Phar::unlinkArchive($fname2); -$b['foo/stat.php'] = ''; -$b->addEmptyDir('foo/bar/blah'); -$b->setStub(' -===DONE=== ---CLEAN-- - - ---EXPECTF-- -Warning: Wrong parameter count for is_file() in %sstat2.php on line %d - -Warning: Wrong parameter count for is_link() in %sstat2.php on line %d -bool(true) -is_link -bool(false) -bool(true) -bool(false) -bool(false) -bool(true) -string(4) "link" -string(3) "dir" -bool(true) -not found -bool(false) -dir -bool(true) -bool(false) -===DONE=== \ No newline at end of file diff --git a/ext/phar/tests/stat2_5.3.phpt b/ext/phar/tests/stat2_5.3.phpt index 6a3f2bf2c8..99f658fa78 100644 --- a/ext/phar/tests/stat2_5.3.phpt +++ b/ext/phar/tests/stat2_5.3.phpt @@ -2,7 +2,6 @@ Phar: test stat function interceptions and is_file/is_link edge cases (PHP 5.3+) --SKIPIF-- - --INI-- phar.readonly=0 phar.require_hash=0 diff --git a/ext/sockets/tests/bug46360.phpt b/ext/sockets/tests/bug46360.phpt index c725a82f9a..8c15d4c340 100644 --- a/ext/sockets/tests/bug46360.phpt +++ b/ext/sockets/tests/bug46360.phpt @@ -3,12 +3,6 @@ Bug 46360 - TCP_NODELAY constant (sock_get_option, sock_set_option) --CREDITS-- Florian Anderiasch fa@php.net ---SKIPIF-- - --FILE-- - @phpsp - sao paulo - br ---SKIPIF-- - --FILE-- - #phparty7 - @phpsp - novatec/2015 - sao paulo - br ---SKIPIF-- - --FILE-- - #phparty7 - @phpsp - novatec/2015 - sao paulo - br ---SKIPIF-- - --FILE-- - #phparty7 - @phpsp - novatec/2015 - sao paulo - br ---SKIPIF-- - --FILE-- - #phparty7 - @phpsp - novatec/2015 - sao paulo - br ---SKIPIF-- - --FILE-- - #phparty7 - @phpsp - novatec/2015 - sao paulo - br ---SKIPIF-- - --FILE-- --EXPECTF-- %s %s