Disable Xdebug for PHPUnit

If you do not need Xdebug when running tests with PHPUnit, then you can disable it and run your tests much faster. However, it’s not easy for me to remember to disable Xdebug, so in my TestCase class I’ve overridden ´setUpBeforeClass´ and ´tearDownAfterClass´ like this:

{[ .xdebug | 1.hilite(=php=) ]}

That only toggles the backtrace, so the speed gain is less impressive, but for me is an acceptable trade-off.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.