Created
August 5, 2019 15:28
-
-
Save MrRio/267033f3b0aeaaf1b348ec25d320707c to your computer and use it in GitHub Desktop.
Speed up your phpunit code coverage output in Laravel.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Tests; | |
use Illuminate\Foundation\Testing\TestCase as BaseTestCase; | |
abstract class TestCase extends BaseTestCase | |
{ | |
use CreatesApplication; | |
protected function setUp(): void | |
{ | |
if (function_exists('xdebug_set_filter')) { | |
\xdebug_set_filter( | |
\XDEBUG_FILTER_CODE_COVERAGE, | |
\XDEBUG_PATH_WHITELIST, | |
[ | |
'./app/' | |
] | |
); | |
} | |
parent::setUp(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment