I\'ve got a bit of a weird issue at the moment.
I\'m currently building a Laravel package which is on Github at https://github.com/matthewbdaly/laravel-error-snapsho
As it turned out, the answer was fairly straightforward. I just needed to exclude the routes file from the test coverage generation:
The filter section from file phpunit.xml
:
<filter>
<whitelist processUncoveredFilesFromWhitelist="true">
<directory suffix=".php">./src</directory>
<exclude>
<directory suffix=".php">./src/database</directory>
<file>./src/routes.php</file>
</exclude>
</whitelist>
</filter>