|
89 | 89 |
|
90 | 90 | error_reporting(E_ALL);
|
91 | 91 |
|
92 |
| -$environment = isset($_ENV) ? $_ENV : array(); |
| 92 | +$environment = $_ENV ?? array(); |
93 | 93 | // Note: php.ini-development sets variables_order="GPCS" not "EGPCS", in which case $_ENV is NOT populated.
|
94 | 94 | // detect and handle this case, or die or warn
|
95 | 95 | if (empty($environment)) {
|
@@ -1028,7 +1028,7 @@ function mail_qa_team($data, $status = false)
|
1028 | 1028 | {
|
1029 | 1029 | $url_bits = parse_url(QA_SUBMISSION_PAGE);
|
1030 | 1030 |
|
1031 |
| - if (($proxy = getenv('http_proxy'))) { |
| 1031 | + if ($proxy = getenv('http_proxy')) { |
1032 | 1032 | $proxy = parse_url($proxy);
|
1033 | 1033 | $path = $url_bits['host'].$url_bits['path'];
|
1034 | 1034 | $host = $proxy['host'];
|
@@ -1148,7 +1148,7 @@ function system_with_timeout($commandline, $env = null, $stdin = null, $captureS
|
1148 | 1148 | unset($pipes[0]);
|
1149 | 1149 | }
|
1150 | 1150 |
|
1151 |
| - $timeout = $valgrind ? 300 : (isset($env['TEST_TIMEOUT']) ? $env['TEST_TIMEOUT'] : 60); |
| 1151 | + $timeout = $valgrind ? 300 : ($env['TEST_TIMEOUT'] ?? 60); |
1152 | 1152 |
|
1153 | 1153 | while (true) {
|
1154 | 1154 | /* hide errors from interrupted syscalls */
|
@@ -1934,7 +1934,7 @@ function run_test($php, $file, $env)
|
1934 | 1934 | $hrtime = hrtime();
|
1935 | 1935 | $startTime = $hrtime[0]*1000000000 + $hrtime[1];
|
1936 | 1936 |
|
1937 |
| - $out = system_with_timeout($cmd, $env, isset($section_text['STDIN']) ? $section_text['STDIN'] : null, $captureStdIn, $captureStdOut, $captureStdErr); |
| 1937 | + $out = system_with_timeout($cmd, $env, $section_text['STDIN'] ?? null, $captureStdIn, $captureStdOut, $captureStdErr); |
1938 | 1938 |
|
1939 | 1939 | junit_finish_timer($shortname);
|
1940 | 1940 | $hrtime = hrtime();
|
@@ -2215,7 +2215,7 @@ function run_test($php, $file, $env)
|
2215 | 2215 | error_report($file, $log_filename, $tested);
|
2216 | 2216 | }
|
2217 | 2217 | }
|
2218 |
| - |
| 2218 | + |
2219 | 2219 | if ($valgrind && $leaked && $cfg["show"]["mem"]) {
|
2220 | 2220 | show_file_block('mem', file_get_contents($memcheck_filename));
|
2221 | 2221 | }
|
@@ -2823,7 +2823,7 @@ function junit_mark_test_as($type, $file_name, $test_name, $time = null, $messag
|
2823 | 2823 |
|
2824 | 2824 | junit_suite_record($suite, 'test_total');
|
2825 | 2825 |
|
2826 |
| - $time = null !== $time ? $time : junit_get_timer($file_name); |
| 2826 | + $time = $time ?? junit_get_timer($file_name); |
2827 | 2827 | junit_suite_record($suite, 'execution_time', $time);
|
2828 | 2828 |
|
2829 | 2829 | $escaped_details = htmlspecialchars($details, ENT_QUOTES, 'UTF-8');
|
|
0 commit comments