Open
Description
Q | A |
---|---|
PHPUnit version | 11.1.3 |
PHP version | 8.2.x, 8.3.x |
Installation Method | Composer / PHAR |
Summary
- when a test (or any function called from the test) flushes or cleans the output buffer, this incorrectly changes the output making tests pass that fail with expectOutputString and/or would cause a PHP notice when the code is actually executed
- if a test ends but starts a new output buffer, no error is reported, since only the ob level is compared instead of comparing the output
- when a test (or any function called from the test) register a non-removable ob callback, this leads to complete failure/unexpected behavior
- non-removable ob callbacks cannot currently be tested
- if stopping output buffering fails, it will try again creating the same notices twice
I will provide a PR.
Activity