例如,在app-profile-saml-jee-jsp快速啓動上運行時,出現以下錯誤。許多Keycloak快速啓動在測試階段失敗
試圖在app-profile-jee-vanilla
上運行相同的快速啓動也會在測試中失敗。
任何想法如何解決這個問題?謝謝。
錯誤:
---------------------------------------- ---------------測試 --------------------------------- ----------------------正在運行org.keycloak.quickstart.ArquillianProfileSamlJeeJspTest測試運行:1,失敗:0,錯誤:1,跳過:0,經過的時間: 0.491秒< < <失敗! - in org.keycloak.quickstart.ArquillianProfileSamlJeeJspTest org.keycloak.quickstart.ArquillianProfileSamlJeeJspTest已用時間: 0.49秒< < <錯誤! java.lang.RuntimeException:無法在org處創建org.jboss.arquillian.test.impl.EventTestRunnerAdaptor的新實例,位於org.jboss.arquillian.test.spi.SecurityActions.newInstance(SecurityActions.java:166)。 jboss.arquillian.test.spi.SecurityActions.newInstance(SecurityActions.java:103)在org.jboss.arquillian.test.spi.TestRunnerAdaptorBuilder.build(TestRunnerAdaptorBuilder.java:52)at org.jboss.arquillian.junit.Arquillian。運行(Arquillian.java:114)在org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:264)at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:153) org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:124)at org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:200)at org.apache.maven.surefire .booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:153)at org.apache.maven.surefi re.booter.ForkedBooter.main(ForkedBooter.java:103)由於:java.lang.reflect.InvocationTargetException:null at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl .java:62)at org.jboss.arquillian.test.spi.SecurityActions上的java.lang.reflect.Constructor.newInstance(Constructor.java:423)處的sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)。 newInstance(SecurityActions.java:162)在org.jboss.arquillian.test.spi.SecurityActions.newInstance(SecurityActions.java:103)at org.jboss.arquillian.test.spi.TestRunnerAdaptorBuilder.build(TestRunnerAdaptorBuilder.java:52)在org.apache.maven.surefire.junit4的org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:264)處的org.jboss.arquillian.junit.Arquillian.run(Arquillian.java:114) .JUnit4Provider.executeTestS (org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:124)at org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:200) org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:153)at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:103)引起:org.jboss。 arquillian.container.impl.ContainerCreationException:無法在org.jboss.arquillian.container.impl.client.container的org.jboss.arquillian.container.impl.LocalContainerRegistry.create(LocalContainerRegistry.java:85)上創建容器jboss。在sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces)上的sun.reflect.NativeMethodAccessorImpl.invoke0(本地方法)中的ContainerRegistryCreator.createRegistry(ContainerRegistryCreator.java:78)在org.jboss.arquillian上的org.jboss.arquillian.core.impl.ObserverImpl.invoke(ObserverImpl.java:96)處的java.lang.reflect.Method.invoke(Method.java:498)處的sorImpl.java:43) .core.impl.EventContextImpl.invokeObservers(EventContextImpl.java:99)at org.jboss.arquillian.core.impl.EventContextImpl.proceed(EventContextImpl.java:81)at org.jboss.arquillian.core.impl.ManagerImpl.fire (ManagerImpl.java:145)at org.jboss.arquillian.core.impl.ManagerImpl.fire(ManagerImpl.java:116)。jboss.arquillian.core.impl.ManagerImpl.bindAndFire(ManagerImpl.java:265)位於org.jboss.arquillian.core.impl.InstanceImpl.set(InstanceImpl.java:74),位於org.jboss.arquillian.config.impl。在sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl。)上的sun.reflect.NativeMethodAccessorImpl.invoke0(本地方法)擴展.ConfigurationRegistrar.loadConfiguration(ConfigurationRegistrar.java:73) java:43)at org.jboss.arquillian.core.impl.ObserverImpl.invoke(ObserverImpl.java:96)at org.jboss.arquillian.core java.lang.reflect.Method.invoke(Method.java:498) .impl.EventContextImpl.invokeObservers(EventContextImpl.java:99)at org.jboss.arquillian.core.impl.EventContextImpl.proceed(EventContextImpl.java:81)at org.jboss.arquillian.core.impl.ManagerImpl.fire(ManagerImpl .java:145)在org.jboss.arquillian.core.impl.ManagerImpl.s(ManagerImpl.java:116) tart(ManagerImpl.java:290)at org.jboss.arquillian.test.impl.EventTestRunnerAdaptor。(EventTestRunnerAdaptor.java:63)at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl的.java:62)在sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)在java.lang.reflect.Constructor.newInstance(Constructor.java:423)在org.jboss.arquillian.test.spi.SecurityActions。的newInstance(SecurityActions.java:162)在org.jboss.arquillian.test.spi.SecurityActions.newInstance(SecurityActions.java:103)在org.jboss.arquillian.test.spi.TestRunnerAdaptorBuilder.build(TestRunnerAdaptorBuilder.java:52)在org.apache.maven.surefire.junit4的org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:264)處的org.jboss.arquillian.junit.Arquillian.run(Arquillian.java:114) .JUnit4Provider.executeTestSet(JUnit4Provider.java:153)at org.apache.maven.surefi re.junit4.JUnit4Provider.invoke(JUnit4Provider.java:124)在org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:200)在org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess( ForkedBooter.java:153)at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:103)引起:java.lang.IllegalArgumentException:必須指定DeployableContainer at org.jboss.arquillian.core .spi.Validate.notNull(Validate.java:44)at org.jboss.arquillian.container.impl.ContainerImpl。(ContainerImpl.java:71)at org.jboss.arquillian.container.impl.LocalContainerRegistry.create(LocalContainerRegistry。的java:80)在org.jboss.arquillian.container.impl.client.container.ContainerRegistryCreator.createRegistry(ContainerRegistryCreator.java:78)在sun.reflect.NativeMethodAccessorImpl.invoke0(本機方法)在sun.reflect.NativeMethodAccessorImpl.invoke( NativeMethodAccessorImpl.java:62) un.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)在java.lang.reflect.Method.invoke(Method.java:498)在org.jboss.arquillian.core.impl.ObserverImpl.invoke(ObserverImpl.java: 96)org.jboss.arquillian.core.impl.EventContextImpl.invokeObservers(EventContextImpl.java:99)at org.jboss.arquillian.core.impl.EventContextImpl.proceed(EventContextImpl.java:81)at org.jboss.arquillian .core.impl.ManagerImpl.fire(ManagerImpl.java:145)at org.jboss.arquillian.core.impl.ManagerImpl.fire(ManagerImpl.java:116)at org.jboss.arquillian.core.impl.ManagerImpl.bindAndFire (ManagerImpl.java:265)at org.jboss.arquillian.core.impl.InstanceImpl.set(InstanceImpl.java:74)at org.jboss.arquillian.config.impl.extension.ConfigurationRegistrar.loadConfiguration(ConfigurationRegistrar.java:73 )at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)at sun.reflect.DelegatingMethodAccessorImpl。在org.jboss的org.jboss.arquillian.core.impl.ObserverImpl.invoke(ObserverImpl.java:96)處的java.lang.reflect.Method.invoke(Method.java:498)處調用(DelegatingMethodAccessorImpl.java:43) .rquillian.core.impl.EventContextImpl.invokeObservers(EventContextImpl.java:99)at org.jboss.arquillian.core.impl.EventContextImpl.proceed(EventContextImpl.java:81)at org.jboss.arquillian.core.impl.ManagerImpl .fire(ManagerImpl.java:145)at org.jboss.arquillian.core.impl.ManagerImpl.fire(ManagerImpl.java:116)at org.jboss.arquillian.core.impl.ManagerImpl.start(ManagerImpl.java:290 )在org.jboss.arquillian.test.impl.EventTestRunnerAdaptor。(EventTestRunnerAdaptor.java:63)在sun.reflect.NativeConstructorAccessorImpl.newInstance0(本機方法)在sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)在陽光下.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)at java.lang.reflect.Constructor.newInstance(Constructor。的java:423)在org.jboss.arquillian.test.spi.SecurityActions.newInstance(SecurityActions.java:162)在org.jboss.arquillian.test.spi.SecurityActions.newInstance(SecurityActions.java:103)在org.jboss .arquillian.test.spi.TestRunnerAdaptorBuilder.build(TestRunnerAdaptorBuilder.java:52)在org.jboss.arquillian.junit.Arquillian.run(Arquillian.java:114)在org.apache.maven.surefire.junit4.JUnit4Provider.execute (JUnit4Provider.java:264)在org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:153)在org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:124)在org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:200)在org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:153)在org.apache.maven.surefire。 booter.ForkedBooter.main(ForkedBooter.java:103)
爲什麼測試失敗? –
因爲必須使用'wildfly-managed'配置文件才能運行測試。 –
跳過測試足以使其工作 - '-DskipTests'。 –