Closed titantwentyone closed 11 months ago
This is specific to traits, because for the past few versions Xdebug has been outputting branch/path data for traits under a key that doesn't allow us easily to map it back to where it came from.
That's now fixed (https://bugs.xdebug.org/view.php?id=2027), so I think all we have to do here is strip off the extra annotation
When testing the methods of a trait, the code coverage stats for branches and paths are labelled as
n/a
when looking at the summary however the code summary below is correctly highlighted showing the code that cover the paths and branches.Example repo at https://github.com/titantwentyone/code-coverage-for-traits whch includes the code below:
If useful,
phpunit.xml
is defined as:And for completeness, the command I am running is:
What I am seeing: For both branches and paths: