mirror of
https://github.com/symfony/recipes.git
synced 2026-09-12 07:36:30 +03:00
Allow to override .env files per env
This commit is contained in:
@@ -0,0 +1,4 @@
|
||||
# define your env variables for the test env here
|
||||
KERNEL_CLASS=App\\Kernel
|
||||
APP_SECRET='s$cretf0rt3st'
|
||||
SHELL_VERBOSITY=-1
|
||||
@@ -1,5 +1,6 @@
|
||||
{
|
||||
"copy-from-recipe": {
|
||||
".env.test": ".env.test",
|
||||
"phpunit.xml.dist": "phpunit.xml.dist",
|
||||
"tests/": "tests/"
|
||||
},
|
||||
|
||||
@@ -2,19 +2,13 @@
|
||||
|
||||
<!-- https://phpunit.de/manual/current/en/appendixes.configuration.html -->
|
||||
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:noNamespaceSchemaLocation="http://schema.phpunit.de/6.1/phpunit.xsd"
|
||||
xsi:noNamespaceSchemaLocation="http://schema.phpunit.de/4.7/phpunit.xsd"
|
||||
backupGlobals="false"
|
||||
colors="true"
|
||||
bootstrap="vendor/autoload.php"
|
||||
bootstrap="tests/bootstrap.php"
|
||||
>
|
||||
<php>
|
||||
<ini name="error_reporting" value="-1" />
|
||||
<env name="KERNEL_CLASS" value="App\Kernel" />
|
||||
<env name="APP_ENV" value="test" />
|
||||
<env name="APP_DEBUG" value="1" />
|
||||
<env name="APP_SECRET" value="s$cretf0rt3st" />
|
||||
<env name="SHELL_VERBOSITY" value="-1" />
|
||||
<!-- define your env variables for the test env here -->
|
||||
</php>
|
||||
|
||||
<testsuites>
|
||||
|
||||
@@ -0,0 +1,5 @@
|
||||
<?php
|
||||
|
||||
require dirname(__DIR__).'/vendor/autoload.php';
|
||||
|
||||
App\Kernel::bootstrapEnv('test');
|
||||
Reference in New Issue
Block a user