[Tests] EZP-32103: Adjusted Behat config to behave more like prod #621
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
JIRA: https://issues.ibexa.co/browse/EZP-32103
Contains #623 and temp changes, needs rebase before merging.Things done:
We're using the default values for the kernel class and path. The env and debug value is taken from the loaded bootstrap file, which loads environmental variables - there's no change in behaviour if APP_ENV=behat, APP_DEBUG=1 is specified (which we do in all our builds) and it's not harcoded there in case someone wants to change it.
behat
env configuration to be more prod-like: right now it contains all the files fromprod
env, reasoning: our tests should be running in a similar env as the production one (but with Debug enabled, so that errors are not silenced). I've also enabled strict_requirements for routing: https://symfony.com/doc/current/reference/configuration/framework.html#strict-requirements to make sure we're not silencing any errors. I had to do it because HTTP cache behaves in a weird way whenframework.test
setting is enabled - IMHO it's a good opportunity to decide how thebehat
env should behave.