mirror of
https://github.com/php/php-src.git
synced 2024-11-23 18:04:36 +08:00
Remove unnecessary CLI checks in tests
This commit is contained in:
parent
cc60e8b000
commit
4e0dd6b0ed
@ -2,7 +2,6 @@
|
||||
Bug #40236 (php -a function allocation eats memory)
|
||||
--SKIPIF--
|
||||
<?php
|
||||
if (php_sapi_name() != "cli") die("skip CLI only");
|
||||
if (extension_loaded("readline")) die("skip Test doesn't support readline");
|
||||
?>
|
||||
--FILE--
|
||||
|
@ -1,11 +1,5 @@
|
||||
--TEST--
|
||||
Bug #60978 (exit code incorrect)
|
||||
--SKIPIF--
|
||||
<?php
|
||||
if ("cli" != php_sapi_name()) {
|
||||
echo "skip CLI only";
|
||||
}
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
$php = getenv('TEST_PHP_EXECUTABLE');
|
||||
|
@ -2,7 +2,6 @@
|
||||
Bug #66218 zend_register_functions breaks reflection
|
||||
--SKIPIF--
|
||||
<?php
|
||||
if (PHP_SAPI != "cli") die("skip CLI only test");
|
||||
if (!function_exists("dl")) die("skip need dl");
|
||||
?>
|
||||
--FILE--
|
||||
|
@ -4,8 +4,6 @@ Constant scalar expressions with autoloading and classes
|
||||
opcache.enable=1
|
||||
opcache.enable_cli=1
|
||||
opcache.optimization_level=-1
|
||||
--SKIPIF--
|
||||
<?php if (php_sapi_name() != "cli") die("skip CLI only"); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
|
@ -5,7 +5,7 @@ opcache.enable=1
|
||||
opcache.enable_cli=1
|
||||
opcache.optimization_level=-1
|
||||
--SKIPIF--
|
||||
<?php if (!extension_loaded('Zend OPcache') || php_sapi_name() != "cli") die("skip CLI only"); ?>
|
||||
<?php if (!extension_loaded('Zend OPcache')) die("skip Zend OPcache extension not loaded"); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
printf ("A=%s\n", getA());
|
||||
|
@ -3,7 +3,7 @@ Bug #66338 (Optimization binding of class constants is not safely opcacheable)
|
||||
--INI--
|
||||
opcache.enable=0
|
||||
--SKIPIF--
|
||||
<?php if (!extension_loaded('Zend OPcache') || php_sapi_name() != "cli") die("skip CLI only"); ?>
|
||||
<?php if (!extension_loaded('Zend OPcache')) die("skip Zend OPcache extension not loaded"); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
$root = str_replace('.php', "", __FILE__);
|
||||
|
@ -7,7 +7,6 @@ phar.readonly=0
|
||||
--SKIPIF--
|
||||
<?php require_once('skipif.inc'); ?>
|
||||
<?php if (!extension_loaded("phar")) die("skip"); ?>
|
||||
<?php if (php_sapi_name() != "cli") die("skip CLI only"); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
$stub = '<?php
|
||||
|
@ -7,7 +7,6 @@ opcache.revalidate_freq=0
|
||||
opcache.file_update_protection=0
|
||||
--SKIPIF--
|
||||
<?php require_once('skipif.inc'); ?>
|
||||
<?php if (php_sapi_name() != "cli") die("skip CLI only"); ?>
|
||||
<?php if (getenv("SKIP_SLOW_TESTS")) die("skip slow tests excluded by request") ?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
@ -7,7 +7,6 @@ phar.readonly=0
|
||||
--SKIPIF--
|
||||
<?php require_once('skipif.inc'); ?>
|
||||
<?php if (!extension_loaded("phar")) die("skip"); ?>
|
||||
<?php if (php_sapi_name() != "cli") die("skip CLI only"); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
$stub = "<?php header('Content-Type: text/plain;');
|
||||
|
@ -6,7 +6,6 @@ opcache.enable_cli=1
|
||||
opcache.revalidate_path=1
|
||||
--SKIPIF--
|
||||
<?php require_once('skipif.inc'); ?>
|
||||
<?php if (php_sapi_name() != "cli") die("skip CLI only"); ?>
|
||||
--FILE--
|
||||
<?php
|
||||
$dir = dirname(__FILE__);
|
||||
|
@ -2,7 +2,6 @@
|
||||
ReflectionExtension::getFunctions() ##6218 zend_register_functions breaks reflection
|
||||
--SKIPIF--
|
||||
<?php
|
||||
if (PHP_SAPI != "cli") die("skip CLI only test");
|
||||
if (!function_exists("dl")) die("skip need dl");
|
||||
?>
|
||||
--FILE--
|
||||
|
@ -3,7 +3,6 @@ Bug #72035 php-cgi.exe fails to run scripts relative to drive root
|
||||
--SKIPIF--
|
||||
<?php
|
||||
if(substr(PHP_OS, 0, 3) != 'WIN' ) die('skip windows only test');
|
||||
if(php_sapi_name() != "cli") die('skip CLI only test');
|
||||
|
||||
$cgi = realpath(dirname(PHP_BINARY)) . DIRECTORY_SEPARATOR . "php-cgi.exe";
|
||||
if (!file_exists($cgi)) die('skip CGI binary not found');
|
||||
|
@ -1,11 +1,5 @@
|
||||
--TEST--
|
||||
Bug #70018 (exec does not strip all whitespace)
|
||||
--SKIPIF--
|
||||
<?php
|
||||
if ("cli" != php_sapi_name()) {
|
||||
die("skip.. CLI only test");
|
||||
}
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
$output = array();
|
||||
|
@ -1,11 +1,5 @@
|
||||
--TEST--
|
||||
header() and friends
|
||||
--SKIPIF--
|
||||
<?php
|
||||
if (php_sapi_name() != "cli") {
|
||||
die("skip this test is for CLI");
|
||||
}
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
|
@ -8,10 +8,6 @@ if (!defined('PHP_WINDOWS_VERSION_MAJOR')) {
|
||||
die('skip: Only for Windows');
|
||||
}
|
||||
|
||||
if (PHP_SAPI != 'cli') {
|
||||
die('skip: Only for CLI');
|
||||
}
|
||||
|
||||
if (getenv('SKIP_SLOW_TESTS')) {
|
||||
doe('skip: Slow test');
|
||||
}
|
||||
|
@ -2,7 +2,6 @@
|
||||
proc_open with bypass_shell subprocess parameter passing
|
||||
--SKIPIF--
|
||||
<?php # vim:syn=php
|
||||
if (php_sapi_name() != "cli") die('skip CLI only test');
|
||||
if (!function_exists("proc_open")) echo "skip proc_open() is not available";
|
||||
?>
|
||||
--FILE--
|
||||
|
@ -2,7 +2,6 @@
|
||||
proc_open without bypass_shell subprocess parameter passing
|
||||
--SKIPIF--
|
||||
<?php # vim:syn=php
|
||||
if (php_sapi_name() != "cli") die('skip CLI only test');
|
||||
if (!function_exists("proc_open")) echo "skip proc_open() is not available";
|
||||
?>
|
||||
--FILE--
|
||||
|
@ -3,11 +3,6 @@ cli_get_process_title() function : basic functionality
|
||||
--CREDITS--
|
||||
Patrick Allaert patrickallaert@php.net
|
||||
@nephp #nephp17
|
||||
--SKIPIF--
|
||||
<?php
|
||||
if (PHP_SAPI !== "cli")
|
||||
die("skip");
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
if (cli_set_process_title("title") && cli_get_process_title() === "title")
|
||||
|
@ -3,11 +3,6 @@ cli_get_process_title() function : error conditions
|
||||
--CREDITS--
|
||||
Patrick Allaert patrickallaert@php.net
|
||||
@nephp #nephp17
|
||||
--SKIPIF--
|
||||
<?php
|
||||
if (PHP_SAPI !== "cli")
|
||||
die("skip");
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
cli_get_process_title("foo");
|
||||
|
@ -3,11 +3,6 @@ cli_set_process_title() function : basic functionality
|
||||
--CREDITS--
|
||||
Patrick Allaert patrickallaert@php.net
|
||||
@nephp #nephp17
|
||||
--SKIPIF--
|
||||
<?php
|
||||
if (PHP_SAPI !== "cli")
|
||||
die("skip");
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
if (cli_set_process_title("title") === true &&
|
||||
|
@ -3,11 +3,6 @@ cli_set_process_title() function : error conditions
|
||||
--CREDITS--
|
||||
Patrick Allaert patrickallaert@php.net
|
||||
@nephp #nephp17
|
||||
--SKIPIF--
|
||||
<?php
|
||||
if (PHP_SAPI !== "cli")
|
||||
die("skip");
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
cli_set_process_title();
|
||||
|
@ -1,7 +1,5 @@
|
||||
--TEST--
|
||||
Testing $argc and $argv handling (cli)
|
||||
--SKIPIF--
|
||||
<?php if(php_sapi_name()!='cli') echo 'skip'; ?>
|
||||
--INI--
|
||||
register_argc_argv=1
|
||||
variables_order=GPS
|
||||
|
@ -1,11 +1,5 @@
|
||||
--TEST--
|
||||
Bug #71273 A wrong ext directory setup in php.ini leads to crash
|
||||
--SKIPIF--
|
||||
<?php
|
||||
if ("cli" != php_sapi_name()) {
|
||||
die("skip CLI only");
|
||||
}
|
||||
?>
|
||||
--FILE--
|
||||
<?php
|
||||
/* NOTE this file is required to be encoded in iso-8859-1 */
|
||||
|
Loading…
Reference in New Issue
Block a user