Laravel 6 includes some additional configuration in phpunit.xml:
<server name="APP_CONFIG_CACHE" value="bootstrap/cache/config.phpunit.php"/>
<server name="APP_SERVICES_CACHE" value="bootstrap/cache/services.phpunit.php"/>
<server name="APP_PACKAGES_CACHE" value="bootstrap/cache/packages.phpunit.php"/>
<server name="APP_ROUTES_CACHE" value="bootstrap/cache/routes.phpunit.php"/>
<server name="APP_EVENTS_CACHE" value="bootstrap/cache/events.phpunit.php"/>
If I run the tests in PHPStorm, I get the following error:
In PackageManifest.php line 168:
The bootstrap/cache directory must be present and writable.
But the bootstrap/cache directory is indeed present and writable. However, if I comment out those new configs in phpunit.xml, my tests run without any errors. How do I fix this?
I also ran php artisan cache:clear
. No luck.