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
When running Junit tests of the entire project (mvn test), the logging within all test classes works as expected. Eclipse uses the systemPropertyVariables defined in the Surefire plugin.
However, when executing only one test case (e.g. a method annotated with @Test) and right-clicking on a test file ("Run as->Junit Test"), the logging doesn't work and I get this error the console:
ERROR:
The LogManager accessed before the "java.util.logging.manager" system property was set to "org.jboss.logmanager.LogManager".
Results may be unexpected.
To solve this issue, I need to
Right click on unit test file -> Run As -> Run Configuration -> JUnit -> Tab "Arguments"
With this workaround, logging for this file works. However, it is cumbersome to add this line to every Junit test class.
Would be nice if m2e took systemPropertyVariables into account when executing test files from the IDE (e.g. when right-clicking on a test file ("Run as->Junit Test")).
The text was updated successfully, but these errors were encountered:
I have this in my pom.xml:
When running Junit tests of the entire project (
mvn test
), the logging within all test classes works as expected. Eclipse uses thesystemPropertyVariables
defined in the Surefire plugin.However, when executing only one test case (e.g. a method annotated with
@Test
) and right-clicking on a test file ("Run as->Junit Test"), the logging doesn't work and I get this error the console:To solve this issue, I need to
Right click on unit test file -> Run As -> Run Configuration -> JUnit -> Tab "Arguments"
and add the below line in "VM arguments"-section:
-Djava.util.logging.manager=org.jboss.logmanager.LogManager
With this workaround, logging for this file works. However, it is cumbersome to add this line to every Junit test class.
Would be nice if m2e took
systemPropertyVariables
into account when executing test files from the IDE (e.g. when right-clicking on a test file ("Run as->Junit Test")).The text was updated successfully, but these errors were encountered: