-
-
Notifications
You must be signed in to change notification settings - Fork 495
[framework-bundle] Disable the logger in test env #248
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
Conversation
dunglas
commented
Nov 10, 2017
Q | A |
---|---|
License | MIT |
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.
Pull request passes validation.
@@ -2,3 +2,7 @@ framework: | |||
test: ~ | |||
#session: | |||
# storage_id: session.storage.mock_file | |||
|
|||
services: | |||
# Disable logs |
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.
As soon as Monolog is used with a proper stream handler for instance, registering this null logger probably isn't a good idea.
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.
Why? It will speed up the builds, even with Monolog (no IO).
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.
Logs can be useful to understand why a test fail. I'm not sure about this as is in the recipe.
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.
Anyway monolog has no specific config for tests right now.
It's just a recipe, for specific needs, debugging etc, the user can (should?) modify this file.
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.
the question then is whether this logger is winning over monolog or no. This should be checked
The goal is to have it winning over the default logger added in FrameworkBundle when no logger is defined
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.
or maybe we should make it possible to disable the default logger via config
closing in favor of #281 |