Skip to content

Commit dc4427d

Browse files
committed
Implemented request #62055 (Make run-tests.php support --CGI-- sections)
Not regarding the CGI section might even been seen as a bug, and since server-tests.php appears to broken, anway[1][2], we implement it for run-tests.php in the way as described[3] for server-tests.php, i.e. respective tests are skipped if no CGI executable is found. [1] <#222 (comment)> [2] <#1811 (comment)> [3] <https://qa.php.net/phpt_details.php#cgi_section>
1 parent 0fe6724 commit dc4427d

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

NEWS

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -119,6 +119,10 @@ PHP NEWS
119119
. Fixed unzserialize(), to disable creation of unsupported data structures
120120
through manually crafted strings. (Dmitry)
121121

122+
- Testing:
123+
. Implemented request #62055 (Make run-tests.php support --CGI-- sections).
124+
(cmb)
125+
122126
- Zlib:
123127
. Added zlib/level context option for compress.zlib wrapper. (Sara)
124128

run-tests.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1406,7 +1406,7 @@ function run_test($php, $file, $env)
14061406
$tested = trim($section_text['TEST']);
14071407

14081408
/* For GET/POST/PUT tests, check if cgi sapi is available and if it is, use it. */
1409-
if (!empty($section_text['GET']) || !empty($section_text['POST']) || !empty($section_text['GZIP_POST']) || !empty($section_text['DEFLATE_POST']) || !empty($section_text['POST_RAW']) || !empty($section_text['PUT']) || !empty($section_text['COOKIE']) || !empty($section_text['EXPECTHEADERS'])) {
1409+
if (array_key_exists('CGI', $section_text) || !empty($section_text['GET']) || !empty($section_text['POST']) || !empty($section_text['GZIP_POST']) || !empty($section_text['DEFLATE_POST']) || !empty($section_text['POST_RAW']) || !empty($section_text['PUT']) || !empty($section_text['COOKIE']) || !empty($section_text['EXPECTHEADERS'])) {
14101410
if (isset($php_cgi)) {
14111411
$old_php = $php;
14121412
$php = $php_cgi . ' -C ';

0 commit comments

Comments
 (0)