Reintroduce proc_open_multiplex.phpt #17192
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The main intent of the test was to show the changed behavior on Windows; previously,
stream_select()
would return immediately there, reporting all pipes as ready; now, it only returns if at least one pipe is actually ready.The original test case was overspecified; of course, we cannot assume that the pipes are ready one after the other; depending on the concrete
select(2)
implementation and the system scheduler, minor differences are to be expected.Thus we relax the test expectations, and now require that not all pipes are reported ready after a single
stream_select()
call, and that the output contains all strings. We also ensure thatstream_select()
doesn't fail (for whatever reason). And in case of the test expectations not being met, we also output some diagnostics (most notably the output that has already been read).