DEV Community

Cover image for Config XDebug for Laravel 9
Jonathan Zarate
Jonathan Zarate

Posted on

Config XDebug for Laravel 9

Hey there!

In this post, we are going to configure XDebug for test coverage in Laravel Framework v9.

First, go to xdebug wizard https://xdebug.org/wizard, copy your phpinfo() and paste into the wizard, follow the instructions.

To enable test coverage you must edit the php.ini file, then add the following line:



xdebug.mode = coverage


Enter fullscreen mode Exit fullscreen mode

Finally, execute:



php artisan test --coverage


Enter fullscreen mode Exit fullscreen mode

Enjoy it!

Top comments (0)