-
Notifications
You must be signed in to change notification settings - Fork 155
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove rest dependencies #173
Changes from 1 commit
6a359ff
d4b20a8
09fc0fa
3dfe0c3
24fe9f2
c197044
69f3596
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
This file was deleted.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,10 @@ | ||
imports: | ||
- { resource: config_dev.yml } | ||
fos_rest: | ||
view: | ||
formats: | ||
json: true | ||
empty_content: 204 | ||
format_listener: | ||
rules: | ||
- { path: '^/', priorities: ['json'], fallback_format: json, prefer_extension: true } | ||
exception: | ||
enabled: false |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -19,7 +19,7 @@ use Symfony\Bundle\FrameworkBundle\Console\Application; | |
use Symfony\Component\Console\Input\ArgvInput; | ||
|
||
$input = new ArgvInput(); | ||
$env = $input->getParameterOption(array('--env', '-e'), getenv('SYMFONY_ENV') ?: 'test'); | ||
$env = $input->getParameterOption(['--env', '-e'], getenv('APP_ENV') ?? 'test'); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Replaced |
||
|
||
$application = new Application(new AppKernel($env, true)); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. What's the idea behind that? Do we really need it? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The idea is to test prod requirements (without optional rest bundles). There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @pamil Maybe you have a better idea to test without optional bundles... |
||
$application->run($input); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Makes the environment config file optional, it's the same behaviour as in Symfony 4+ apps.