You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
These modules test LogLevelMap in different combinations of backend and context.
A particular pair of backend and context implementations is a test subject here. But we can't specify them with code. They are part of Gradle module configuration. We add the corresponding implementations to runtimClasspath and make the assumption that the logging Platform would load exactly them. And I believe it is so in most cases.
Though, recently in #50 it was found that if two following conditions are met:
Backend implementation fails to expose its BackendFactory as a Java service. It may be due to incorrect service declaration in META-INF file. Or maybe the annotation preprocessor didn't start (if @AutoValue annotation was used).
Some transitive dependency puts another BackendFactory on the classpath.
Then our test may accidentally pass where it should have failed.
I've added such assertions in the following tests:
jvm-our-backend-our-context.
jvm-log4j-backend-our-context.
Please take a look and propagate such assertions to other modules in tests directory. It is sort of double check, but it may be useful due to complexity of Gradle configurations and runtime.
Maybe some abstract base can be created for such assertions.
The text was updated successfully, but these errors were encountered:
These modules test
LogLevelMap
in different combinations of backend and context.A particular pair of backend and context implementations is a test subject here. But we can't specify them with code. They are part of Gradle module configuration. We add the corresponding implementations to
runtimClasspath
and make the assumption that the loggingPlatform
would load exactly them. And I believe it is so in most cases.Though, recently in #50 it was found that if two following conditions are met:
BackendFactory
as a Java service. It may be due to incorrect service declaration in META-INF file. Or maybe the annotation preprocessor didn't start (if@AutoValue
annotation was used).BackendFactory
on the classpath.Then our test may accidentally pass where it should have failed.
I've added such assertions in the following tests:
jvm-our-backend-our-context
.jvm-log4j-backend-our-context
.Please take a look and propagate such assertions to other modules in
tests
directory. It is sort of double check, but it may be useful due to complexity of Gradle configurations and runtime.Maybe some abstract base can be created for such assertions.
The text was updated successfully, but these errors were encountered: