Uploaded image for project: 'WildFly Core'
  1. WildFly Core
  2. WFCORE-5023

A few tests don't work using IBM JDK because of mock-server 5.9.0

XMLWordPrintable

      After JIRA WFCORE-4850 the mock-server 5.9.0 does not work with IBM JDK which makes a few tests fail with the following error:

      cd ./testsuite/standalone/
      export JAVA_HOME=/home/rmartinc/apps/ibm-java-x86_64-80/
      mvn clean test -Dtest=org.jboss.as.test.integration.management.cli.SecurityCommandsTestCase
      ...
      [INFO] -------------------------------------------------------
      [INFO]  T E S T S
      [INFO] -------------------------------------------------------
      [INFO] Running org.jboss.as.test.integration.management.cli.SecurityCommandsTestCase
      [ERROR] Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.005 s <<< FAILURE! - in org.jboss.as.test.integration.management.cli.SecurityCommandsTestCase
      [ERROR] org.jboss.as.test.integration.management.cli.SecurityCommandsTestCase  Time elapsed: 0.003 s  <<< ERROR!
      java.lang.NoClassDefFoundError: sun.security.x509.GeneralNameInterface
      	at org.mockserver.socket.tls.jdk.JDKKeyAndCertificateFactory.<init>(JDKKeyAndCertificateFactory.java:36)
      	at org.mockserver.socket.tls.NettySslContextFactory.<init>(NettySslContextFactory.java:37)
      	at org.mockserver.client.MockServerClient.<init>(MockServerClient.java:57)
      	at org.mockserver.integration.ClientAndServer.<init>(ClientAndServer.java:19)
      	at org.jboss.as.test.integration.management.cli.SecurityCommandsTestCase.setup(SecurityCommandsTestCase.java:358)
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:90)
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:55)
      	at java.lang.reflect.Method.invoke(Method.java:508)
      	at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
      	at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
      	at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
      	at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:24)
      	at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27)
      	at org.junit.rules.ExternalResource$1.evaluate(ExternalResource.java:48)
      	at org.junit.rules.RunRules.evaluate(RunRules.java:20)
      	at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
      	at org.wildfly.core.testrunner.WildflyTestRunner.run(WildflyTestRunner.java:157)
      	at org.junit.runners.Suite.runChild(Suite.java:128)
      	at org.junit.runners.Suite.runChild(Suite.java:27)
      	at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
      	at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
      	at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
      	at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
      	at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
      	at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
      	at org.apache.maven.surefire.junitcore.JUnitCore.run(JUnitCore.java:55)
      	at org.apache.maven.surefire.junitcore.JUnitCoreWrapper.createRequestAndRun(JUnitCoreWrapper.java:137)
      	at org.apache.maven.surefire.junitcore.JUnitCoreWrapper.executeEager(JUnitCoreWrapper.java:107)
      	at org.apache.maven.surefire.junitcore.JUnitCoreWrapper.execute(JUnitCoreWrapper.java:83)
      	at org.apache.maven.surefire.junitcore.JUnitCoreWrapper.execute(JUnitCoreWrapper.java:75)
      	at org.apache.maven.surefire.junitcore.JUnitCoreProvider.invoke(JUnitCoreProvider.java:158)
      	at org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:383)
      	at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:344)
      	at org.apache.maven.surefire.booter.ForkedBooter.execute(ForkedBooter.java:125)
      	at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:417)
      Caused by: java.lang.ClassNotFoundException: sun.security.x509.GeneralNameInterface
      	at java.net.URLClassLoader.findClass(URLClassLoader.java:610)
      	at java.lang.ClassLoader.loadClassHelper(ClassLoader.java:944)
      	at java.lang.ClassLoader.loadClass(ClassLoader.java:889)
      	at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349)
      	at java.lang.ClassLoader.loadClass(ClassLoader.java:872)
      	... 36 more
      

      The tests that don't work are the following three classes:

      • CertificateAuthoritiesTestCase.java (elytron)
      • KeyStoresTestCase.java (elytron)
      • SecurityCommandsTestCase.java (testsuite/standalone)

      This is explained in the mock-server issue 750. For the moment the only solution is doing a downgrade to 5.8.1. Although it is expected to be fixed soon in the mock-server (maybe in the next version 5.10.1 or 5.11.0).

            rhn-support-rmartinc Ricardo Martin Camarero
            rhn-support-rmartinc Ricardo Martin Camarero
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: