Convert unhandled PHPT exceptions to skipped test result #3529
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.
Fixes #3011 which is very much like #3490
Verification
You can see the exception handling at work when you manually run the new end-to-end test:
Changes
PhptTestCase
unit tests--SECTION--
Note
The improved exception handling is designed to prevent PHPUnit from crashing out during a run, which works in both the 7.x and 8.x major versions. Version 8 additionally has the improved Testdox and error output which provides much more detailed code locations.