mirror of
https://github.com/symfony/recipes.git
synced 2026-09-18 10:36:43 +03:00
Allow to override .env files per env
This commit is contained in:
@@ -5,16 +5,14 @@ if (!file_exists(dirname(__DIR__).'/vendor/symfony/phpunit-bridge/bin/simple-php
|
||||
echo "Unable to find the `simple-phpunit` script in `vendor/symfony/phpunit-bridge/bin/`.\n";
|
||||
exit(1);
|
||||
}
|
||||
if (false === getenv('SYMFONY_DEPRECATIONS_HELPER')) {
|
||||
// see https://symfony.com/doc/current/components/phpunit_bridge.html#making-tests-fail
|
||||
putenv('SYMFONY_DEPRECATIONS_HELPER=999999');
|
||||
}
|
||||
|
||||
$classLoader = require dirname(__DIR__).'/vendor/autoload.php';
|
||||
App\Kernel::bootstrapEnv('test');
|
||||
$classLoader->unregister();
|
||||
|
||||
if (false === getenv('SYMFONY_PHPUNIT_REMOVE')) {
|
||||
putenv('SYMFONY_PHPUNIT_REMOVE=symfony/yaml');
|
||||
}
|
||||
if (false === getenv('SYMFONY_PHPUNIT_VERSION')) {
|
||||
putenv('SYMFONY_PHPUNIT_VERSION=6.5');
|
||||
}
|
||||
if (false === getenv('SYMFONY_PHPUNIT_DIR')) {
|
||||
putenv('SYMFONY_PHPUNIT_DIR='.__DIR__.'/.phpunit');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user