-
Notifications
You must be signed in to change notification settings - Fork 18
Description
As discussed in PHP-CS-Fixer#7187 it looks like ParaUnit does not handle how PHPUnit displays output for diff-based assertions.
In short: this is out of the scope of this repo. On our side we only assert that 2 strings are equal. This leads to
PHPUnit\Framework\ExpectationFailedExceptionwhich containsSebastianBergmann\Comparator\ComparisonFailurewhich hasgetDiff()and prints the diff between actual and expected code.
As a result, failures displayed in the ParaUnit's output miss important context.
It would be great if ParaUnit could catch whole PHPUnit's output and print it. Currently test output in PHP CS Fixer has this little flaw that you can't see what's the actual difference, you only see "Failed asserting that two strings are identical.", which requires running these tests locally and verifying what's the problem. This is not a big deal if there's the same failure for all PHP versions, but if it's only for specific version, it requires additional steps from developer (e.g. running through Docker). It would be just easier if there was diff in the CI output 🙂.