-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Closed
Description
That's by design. For compatibility with existing tools the legacy XML format outputs the legacy reporting name.
Please give the new Open Test Reporting XML format a try to get support for display names, report entries, hierarchical test structures, etc.
I added
--config=junit.platform.reporting.open.xml.enabled=true, but seems like it doesn't workWARNING: TestExecutionListener [org.junit.platform.reporting.open.xml.OpenTestReportGeneratingListener] threw exception for method: executionFinished(TestIdentifier [uniqueId = [engine:junit-jupiter], parentId = null, displayName = 'JUnit Jupiter', legacyReportingName = 'JUnit Jupiter', source = null, tags = [], type = CONTAINER], TestExecutionResult [status = SUCCESSFUL, throwable = null]) java.lang.RuntimeException: Failed to write event: Element{domElement=[e:finished: null]} at org.junit.platform.reporting.shadow.org.opentest4j.reporting.events.api.DefaultDocumentWriter.append(DefaultDocumentWriter.java:118) at org.junit.platform.reporting.shadow.org.opentest4j.reporting.events.api.DefaultDocumentWriter.append(DefaultDocumentWriter.java:42) at org.junit.platform.reporting.open.xml.OpenTestReportGeneratingListener.executionFinished(OpenTestReportGeneratingListener.java:247) at org.junit.platform.launcher.core.CompositeTestExecutionListener.lambda$executionFinished$10(CompositeTestExecutionListener.java:73) at org.junit.platform.launcher.core.CompositeTestExecutionListener.lambda$notifyEach$19(CompositeTestExecutionListener.java:102) at org.junit.platform.commons.util.CollectionUtils.forEachInReverseOrder(CollectionUtils.java:244) at org.junit.platform.launcher.core.IterationOrder$2.forEach(IterationOrder.java:30) at org.junit.platform.launcher.core.CompositeTestExecutionListener.notifyEach(CompositeTestExecutionListener.java:100) at org.junit.platform.launcher.core.CompositeTestExecutionListener.executionFinished(CompositeTestExecutionListener.java:72) at org.junit.platform.launcher.core.ExecutionListenerAdapter.executionFinished(ExecutionListenerAdapter.java:56) at org.junit.platform.launcher.core.CompositeEngineExecutionListener.lambda$executionFinished$6(CompositeEngineExecutionListener.java:59) at org.junit.platform.launcher.core.CompositeEngineExecutionListener.lambda$notifyEach$11(CompositeEngineExecutionListener.java:74) at org.junit.platform.commons.util.CollectionUtils.forEachInReverseOrder(CollectionUtils.java:244) at org.junit.platform.launcher.core.IterationOrder$2.forEach(IterationOrder.java:30) at org.junit.platform.launcher.core.CompositeEngineExecutionListener.notifyEach(CompositeEngineExecutionListener.java:72) at org.junit.platform.launcher.core.CompositeEngineExecutionListener.executionFinished(CompositeEngineExecutionListener.java:58) at org.junit.platform.launcher.core.DelegatingEngineExecutionListener.executionFinished(DelegatingEngineExecutionListener.java:46) at org.junit.platform.launcher.core.StackTracePruningEngineExecutionListener.executionFinished(StackTracePruningEngineExecutionListener.java:46) at org.junit.platform.launcher.core.DelegatingEngineExecutionListener.executionFinished(DelegatingEngineExecutionListener.java:46) at org.junit.platform.launcher.core.OutcomeDelayingEngineExecutionListener.reportEngineOutcome(OutcomeDelayingEngineExecutionListener.java:69) at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:199) at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:169) at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:93) at org.junit.platform.launcher.core.EngineExecutionOrchestrator.lambda$execute$0(EngineExecutionOrchestrator.java:58) at org.junit.platform.launcher.core.EngineExecutionOrchestrator.withInterceptedStreams(EngineExecutionOrchestrator.java:141) at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:57) at org.junit.platform.launcher.core.DefaultLauncher.execute(DefaultLauncher.java:103) at org.junit.platform.launcher.core.DefaultLauncher.execute(DefaultLauncher.java:85) at org.junit.platform.launcher.core.DelegatingLauncher.execute(DelegatingLauncher.java:47) at org.junit.platform.launcher.core.SessionPerRequestLauncher.execute(SessionPerRequestLauncher.java:63) at org.junit.platform.console.tasks.ConsoleTestExecutor.executeTests(ConsoleTestExecutor.java:102) at org.junit.platform.console.tasks.ConsoleTestExecutor.lambda$execute$1(ConsoleTestExecutor.java:71) at org.junit.platform.console.tasks.CustomContextClassLoaderExecutor.replaceThreadContextClassLoaderAndInvoke(CustomContextClassLoaderExecutor.java:42) at org.junit.platform.console.tasks.CustomContextClassLoaderExecutor.invoke(CustomContextClassLoaderExecutor.java:33) at org.junit.platform.console.tasks.ConsoleTestExecutor.execute(ConsoleTestExecutor.java:71) at org.junit.platform.console.options.ExecuteTestsCommand.execute(ExecuteTestsCommand.java:61) at org.junit.platform.console.options.ExecuteTestsCommand.execute(ExecuteTestsCommand.java:27) at org.junit.platform.console.options.BaseCommand.call(BaseCommand.java:81) at org.junit.platform.console.shadow.picocli.CommandLine.executeUserObject(CommandLine.java:2045) at org.junit.platform.console.shadow.picocli.CommandLine.access$1500(CommandLine.java:148) at org.junit.platform.console.shadow.picocli.CommandLine$RunLast.executeUserObjectOfLastSubcommandWithSameParent(CommandLine.java:2465) at org.junit.platform.console.shadow.picocli.CommandLine$RunLast.handle(CommandLine.java:2457) at org.junit.platform.console.shadow.picocli.CommandLine$RunLast.handle(CommandLine.java:2419) at org.junit.platform.console.shadow.picocli.CommandLine$AbstractParseResultHandler.execute(CommandLine.java:2277) at org.junit.platform.console.shadow.picocli.CommandLine$RunLast.execute(CommandLine.java:2421) at org.junit.platform.console.shadow.picocli.CommandLine.execute(CommandLine.java:2174) at org.junit.platform.console.options.MainCommand.runCommand(MainCommand.java:146) at org.junit.platform.console.options.MainCommand.run(MainCommand.java:139) at org.junit.platform.console.options.CommandFacade.run(CommandFacade.java:54) at org.junit.platform.console.options.CommandFacade.run(CommandFacade.java:37) at org.junit.platform.console.ConsoleLauncher.main(ConsoleLauncher.java:33) Caused by: java.lang.NullPointerException: Cannot invoke "java.io.Writer.flush()" because "this.fWriter" is null at java.xml/com.sun.xml.internal.stream.writers.XMLStreamWriterImpl.flush(XMLStreamWriterImpl.java:397) at org.junit.platform.reporting.shadow.org.opentest4j.reporting.events.api.DefaultDocumentWriter.writeNewLine(DefaultDocumentWriter.java:139) at org.junit.platform.reporting.shadow.org.opentest4j.reporting.events.api.DefaultDocumentWriter.append(DefaultDocumentWriter.java:112) ... 50 more
junit-platform-console-standalone-1.11.4.jar