When running test with Symfony Kernel, it creates /cache and /logs directory.
At the moment I load own bootstrap.php file with phpunit.xml:
<?php
require_once __DIR__.'/../vendor/autoload.php';
// clear cache
register_shutdown_function(function () {
Nette\Utils\FileSystem::delete(__DIR__.'/cache');
Nette\Utils\FileSystem::delete(__DIR__.'/logs');
});
- I wonder, is there better way to do that?
- The best without this extra
bootstrap.phpfile?
Note: I don't want to keep /cache and /logs directory there by adding them to .gitignore.
Used resources with no help:
Aucun commentaire:
Enregistrer un commentaire