Skip to content

Conversation

@ogeidix
Copy link

@ogeidix ogeidix commented Dec 4, 2018

Without the slf4j-simple dependency, log-statements during tests
are ignored and the following warning is printed instead:

SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
SLF4J: Defaulting to no-operation (NOP) logger implementation
SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.

The error is documented here too:
https://www.slf4j.org/codes.html#StaticLoggerBinder

--- Currently:

$ mvn verify

T E S T S

Running com.google.firebase.iid.FirebaseInstanceIdIT
SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
SLF4J: Defaulting to no-operation (NOP) logger implementation
SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.
Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 3.494 sec - in com.google.firebase.iid.FirebaseInstanceIdIT

Results :

Tests run: 1, Failures: 0, Errors: 0, Skipped: 0

--- With the dependency:

$ mvn verify

T E S T S

Running com.google.firebase.iid.FirebaseInstanceIdIT
Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 3.536 sec - in com.google.firebase.iid.FirebaseInstanceIdIT

Results :

Tests run: 1, Failures: 0, Errors: 0, Skipped: 0

Without the `slf4j-simple` dependency, log-statements during tests are ignored and the following warning is printed instead: > SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder". > SLF4J: Defaulting to no-operation (NOP) logger implementation > SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details. The error is documented here too: https://www.slf4j.org/codes.html#StaticLoggerBinder --- Currently: $ mvn verify ------------------------------------------------------- T E S T S ------------------------------------------------------- Running com.google.firebase.iid.FirebaseInstanceIdIT SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder". SLF4J: Defaulting to no-operation (NOP) logger implementation SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details. Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 3.494 sec - in com.google.firebase.iid.FirebaseInstanceIdIT Results : Tests run: 1, Failures: 0, Errors: 0, Skipped: 0 --- With the dependency: $ mvn verify ------------------------------------------------------- T E S T S ------------------------------------------------------- Running com.google.firebase.iid.FirebaseInstanceIdIT Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 3.536 sec - in com.google.firebase.iid.FirebaseInstanceIdIT Results : Tests run: 1, Failures: 0, Errors: 0, Skipped: 0
@ogeidix
Copy link
Author

ogeidix commented Jan 10, 2019

friendly ping

@hiranya911
Copy link
Contributor

I think the existing behavior is acceptable. We certainly don't want to permanently enable logs for tests. If we must turn off the warning, then we should add slf4j-nop to the test classpath.

@hiranya911 hiranya911 closed this Jun 25, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants