Answer the question
In order to leave comments, you need to log in
How to exclude directories by regular expression from code coverage in phpunit?
Good afternoon,
Tell me how to set up phpunit.xml to exclude some directories from Code coverage by regular expression.
The folders to be excluded are at different levels, so hardcoding the paths is not an option.
I do this, but they still get into the report
<phpunit ...>
....
<filter>
<whitelist>
<directory>./../src/</directory>
<exclude>
<directory>./../src/*NeedToExclude/*</directory>
</exclude>
</whitelist>
</filter>
....
<phpunit>
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question