Skip to content

Commit

Permalink
Make parallel run-tests compatible with IO capture tests
Browse files Browse the repository at this point in the history
Inherit the main stdin/stdout/stderr streams into the worker processes.
We don't talk to workers via these pipes, so there shouldn't be a
problem doing this.
  • Loading branch information
nikic committed Feb 19, 2019
1 parent 5cde3af commit fa91561
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions run-tests.php
Expand Up @@ -391,7 +391,6 @@ function main()
error("'$workers' is not a valid number of workers, try e.g. -j16 for 16 workers");
}
$workers = intval($workers, 10);
$environment['SKIP_IO_CAPTURE_TESTS'] = 1;
break;
case 'r':
case 'l':
Expand Down Expand Up @@ -1434,11 +1433,7 @@ function run_all_tests_parallel($test_files, $env, $redir_tested) {
for ($i = 1; $i <= $workers; $i++) {
$proc = proc_open(
$thisPHP . ' ' . escapeshellarg($thisScript),
[
0 => ['pipe', 'r'],
1 => ['pipe', 'w'],
2 => ['pipe', 'w']
],
[], // Inherit our stdin, stdout and stderr
$pipes,
NULL,
$_ENV + [
Expand Down

0 comments on commit fa91561

Please sign in to comment.