3 Environment & Database
File .env
Case A — config in the root config/ directory
config/ directory###> sylius/test-application ###
SYLIUS_TEST_APP_CONFIGS_TO_IMPORT="@YourPlugin/tests/TestApplication/config/config.yaml"
SYLIUS_TEST_APP_ROUTES_TO_IMPORT="@YourPlugin/tests/TestApplication/config/routes.yaml"
SYLIUS_TEST_APP_BUNDLES_PATH="tests/TestApplication/config/bundles.php"
###< sylius/test-application ###
###> doctrine/doctrine-bundle ###
DATABASE_URL=mysql://root:[email protected]:3306/your_plugin_dev?serverVersion=8.0
###< doctrine/doctrine-bundle ###Case B — config in src/Resources/config/
src/Resources/config/###> sylius/test-application ###
SYLIUS_TEST_APP_CONFIGS_TO_IMPORT="../../../../tests/TestApplication/config/config.yaml"
SYLIUS_TEST_APP_ROUTES_TO_IMPORT="../../../../tests/TestApplication/config/routes.yaml"
SYLIUS_TEST_APP_BUNDLES_PATH="tests/TestApplication/config/bundles.php"
###< sylius/test-application ###
###> doctrine/doctrine-bundle ###
DATABASE_URL=mysql://root:[email protected]:3306/your_plugin_%kernel.environment%?serverVersion=8.0
###< doctrine/doctrine-bundle ###File .env.test
Quick verification
Last updated
Was this helpful?
