Uploaded image for project: 'XWiki Platform'
  1. XWiki Platform
  2. XWIKI-21144

ExtensionManagerScriptServiceTest is failing when built with Java 17

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Major
    • 15.10-rc-1
    • 15.5
    • Extension
    • None
    • Java 17
    • Unknown
    • N/A
    • N/A

    Description

      [ERROR] Errors: 
      [ERROR]   ExtensionManagerScriptServiceTest.testInstallOnNamespace:152->install:114 » NullPointer Cannot invoke "org.slf4j.Marker.contains(org.slf4j.Marker)" because "marker" is null
      [ERROR]   ExtensionManagerScriptServiceTest.testInstallOnNamespaceWithoutProgrammingRigths »  Unexpected exception, expected<org.xwiki.extension.InstallException> but was<java.lang.NullPointerException>
      [ERROR]   ExtensionManagerScriptServiceTest.testInstallOnRoot:146->install:114 » NullPointer Cannot invoke "org.slf4j.Marker.contains(org.slf4j.Marker)" because "marker" is null
      [ERROR]   ExtensionManagerScriptServiceTest.testInstallOnRootWithoutProgrammingRigths »  Unexpected exception, expected<org.xwiki.extension.InstallException> but was<java.lang.NullPointerException>
      [ERROR]   ExtensionManagerScriptServiceTest.testOverwriteAllowedNamespaces:173 » NullPointer Cannot invoke "org.slf4j.Marker.contains(org.slf4j.Marker)" because "marker" is null
      [ERROR]   ExtensionManagerScriptServiceTest.testUninstallFromRoot:208->uninstall:131 » NullPointer Cannot invoke "org.slf4j.Marker.contains(org.slf4j.Marker)" because "marker" is null
      [ERROR]   ExtensionManagerScriptServiceTest.testUninstallOnNamespace:214->uninstall:131 » NullPointer Cannot invoke "org.slf4j.Marker.contains(org.slf4j.Marker)" because "marker" is null
      [ERROR]   ExtensionManagerScriptServiceTest.testUninstallOnNamespaceWithoutProgrammingRigths »  Unexpected exception, expected<org.xwiki.extension.UninstallException> but was<java.lang.NullPointerException>
      [ERROR]   ExtensionManagerScriptServiceTest.testUninstallOnRootWithoutProgrammingRigths »  Unexpected exception, expected<org.xwiki.extension.UninstallException> but was<java.lang.NullPointerException>
      [INFO] 
      [ERROR] Tests run: 15, Failures: 0, Errors: 9, Skipped: 0
      
      [ERROR] org.xwiki.extension.script.ExtensionManagerScriptServiceTest.testUninstallOnRootWithoutProgrammingRigths -- Time elapsed: 0.131 s <<< ERROR!
      java.lang.Exception: Unexpected exception, expected<org.xwiki.extension.UninstallException> but was<java.lang.NullPointerException>
              at org.junit.internal.runners.statements.ExpectException.evaluate(ExpectException.java:30)
              at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26)
              at org.xwiki.extension.test.MockitoRepositoryUtilsRule$1.evaluate(MockitoRepositoryUtilsRule.java:61)
              at com.xpn.xwiki.test.MockitoOldcoreRule$1.evaluate(MockitoOldcoreRule.java:76)
              at org.xwiki.test.mockito.MockitoComponentManagerRule$1.evaluate(MockitoComponentManagerRule.java:44)
              at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
              at org.junit.runners.BlockJUnit4ClassRunner$1.evaluate(BlockJUnit4ClassRunner.java:100)
              at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:366)
              at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:103)
              at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:63)
              at org.junit.runners.ParentRunner$4.run(ParentRunner.java:331)
              at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:79)
              at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:329)
              at org.junit.runners.ParentRunner.access$100(ParentRunner.java:66)
              at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:293)
              at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
              at org.junit.runners.ParentRunner.run(ParentRunner.java:413)
              at org.junit.runner.JUnitCore.run(JUnitCore.java:137)
              at org.junit.runner.JUnitCore.run(JUnitCore.java:115)
              at org.junit.vintage.engine.execution.RunnerExecutor.execute(RunnerExecutor.java:42)
              at org.junit.vintage.engine.VintageTestEngine.executeAllChildren(VintageTestEngine.java:80)
              at org.junit.vintage.engine.VintageTestEngine.execute(VintageTestEngine.java:72)
              at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:147)
              at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:127)
              at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:90)
              at org.junit.platform.launcher.core.EngineExecutionOrchestrator.lambda$execute$0(EngineExecutionOrchestrator.java:55)
              at org.junit.platform.launcher.core.EngineExecutionOrchestrator.withInterceptedStreams(EngineExecutionOrchestrator.java:102)
              at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:54)
              at org.junit.platform.launcher.core.DefaultLauncher.execute(DefaultLauncher.java:114)
              at org.junit.platform.launcher.core.DefaultLauncher.execute(DefaultLauncher.java:86)
              at org.junit.platform.launcher.core.DefaultLauncherSession$DelegatingLauncher.execute(DefaultLauncherSession.java:86)
              at org.apache.maven.surefire.junitplatform.LazyLauncher.execute(LazyLauncher.java:56)
              at org.apache.maven.surefire.junitplatform.JUnitPlatformProvider.execute(JUnitPlatformProvider.java:184)
              at org.apache.maven.surefire.junitplatform.JUnitPlatformProvider.invokeAllTests(JUnitPlatformProvider.java:148)
              at org.apache.maven.surefire.junitplatform.JUnitPlatformProvider.invoke(JUnitPlatformProvider.java:122)
              at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:385)
              at org.apache.maven.surefire.booter.ForkedBooter.execute(ForkedBooter.java:162)
              at org.apache.maven.surefire.booter.ForkedBooter.run(ForkedBooter.java:507)
              at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:495)
      Caused by: java.lang.NullPointerException: Cannot invoke "org.slf4j.Marker.contains(org.slf4j.Marker)" because "marker" is null
              at org.xwiki.logging.marker.AbstractContainerMarker.contains(AbstractContainerMarker.java:157)
              at org.xwiki.logging.LogUtils.newLogEvent(LogUtils.java:76)
              at org.xwiki.logging.LogUtils.newLogEvent(LogUtils.java:57)
              at org.xwiki.logging.LogQueue.addLogEvent(LogQueue.java:120)
              at org.xwiki.logging.LogQueue.addLogEvent(LogQueue.java:93)
              at org.xwiki.logging.LogQueue.info(LogQueue.java:482)
              at org.xwiki.logging.event.LogEvent.log(LogEvent.java:156)
              at org.xwiki.logging.event.LogEvent.log(LogEvent.java:142)
              at org.xwiki.logging.internal.tail.AbstractLoggerTail.log(AbstractLoggerTail.java:40)
              at org.xwiki.job.AbstractJobStatus.getLog(AbstractJobStatus.java:526)
              at org.xwiki.extension.script.ExtensionManagerScriptServiceTest.uninstall(ExtensionManagerScriptServiceTest.java:131)
              at org.xwiki.extension.script.ExtensionManagerScriptServiceTest.testUninstallOnRootWithoutProgrammingRigths(ExtensionManagerScriptServiceTest.java:223)
              at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
              at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
              at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
              at java.base/java.lang.reflect.Method.invoke(Method.java:568)
              at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:59)
              at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
              at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:56)
              at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
              at org.junit.internal.runners.statements.ExpectException.evaluate(ExpectException.java:19)
              ... 38 more
      

      Attachments

        Issue Links

          Activity

            People

              vmassol Vincent Massol
              vmassol Vincent Massol
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: