marcpa
11 years agoOccasional Contributor
Unit test failures when building from sources under jenkins
Hello,
when I build soapui from sources (a branch in my fork on github based on branch next) using jdk1.7 and maven 3 from the command line, everything builds fine and unit tests passes.
However, when I configure a jenkins job to do the same thing, I get failed tests. At first I thought it may be a problem with tests trying to access a frame buffer (jenkins is on linux and the job is running as another user than the one loggued in the GUI), but either letting anybody use the default X Display server (xhost +) or installing Xvfb plugin in jenkins did not solve the issue.
The failed tests are :
An example of stacktrace for failures:
The weird thing is that the assertion that fails appears to be inside one of the classes in the xbean-fixed-2.4.0.jar for which the source is not in smartbear's maven2 repo...
Anybody have an idea ?
Thanks in advance,
Marc Paquette
when I build soapui from sources (a branch in my fork on github based on branch next) using jdk1.7 and maven 3 from the command line, everything builds fine and unit tests passes.
However, when I configure a jenkins job to do the same thing, I get failed tests. At first I thought it may be a problem with tests trying to access a frame buffer (jenkins is on linux and the job is running as another user than the one loggued in the GUI), but either letting anybody use the default X Display server (xhost +) or installing Xvfb plugin in jenkins did not solve the issue.
The failed tests are :
shouldNotResortMockOperationsOnReload(com.eviware.soapui.impl.wsdl.WsdlProjectWithRestMockTest)
shouldSaveAndReloadRestMockServices(com.eviware.soapui.impl.wsdl.WsdlProjectWithRestMockTest)
shouldSaveAndReloadRestMockResponses(com.eviware.soapui.impl.wsdl.WsdlProjectWithRestMockTest)
projectLoadedFromInputStreamCanBeSaved(com.eviware.soapui.impl.wsdl.WsdlProjectLoadAndSaveTest)
projectLoadedFromFileCanBeSaved(com.eviware.soapui.impl.wsdl.WsdlProjectLoadAndSaveTest)
userIsPromptedForSaveLocationWhenSavingProjectLoadedFromInputStream(com.eviware.soapui.impl.wsdl.WsdlProjectLoadAndSaveTest)
createMockAsWar(com.eviware.soapui.actions.MockAsWarActionTest)
An example of stacktrace for failures:
Test set: com.eviware.soapui.impl.wsdl.WsdlProjectWithRestMockTest
-------------------------------------------------------------------------------
Tests run: 5, Failures: 3, Errors: 0, Skipped: 0, Time elapsed: 1.271 sec <<< FAILURE!
shouldNotResortMockOperationsOnReload(com.eviware.soapui.impl.wsdl.WsdlProjectWithRestMockTest) Time elapsed: 1.143 sec <<< FAILURE!
java.lang.AssertionError
at org.apache.xmlbeans.impl.values.XmlObjectBase.build_text(XmlObjectBase.java:868)
at org.apache.xmlbeans.impl.store.Xobj.ensureOccupancy(Xobj.java:1706)
at org.apache.xmlbeans.impl.store.Xobj.copyNode(Xobj.java:1109)
at org.apache.xmlbeans.impl.store.Xobj.copy_contents_from(Xobj.java:2331)
at org.apache.xmlbeans.impl.store.Xobj.copy(Xobj.java:2405)
at org.apache.xmlbeans.impl.values.XmlObjectBase._copy(XmlObjectBase.java:155)
at org.apache.xmlbeans.impl.values.XmlObjectBase._copy(XmlObjectBase.java:138)
at org.apache.xmlbeans.impl.values.XmlObjectBase.copy(XmlObjectBase.java:119)
at com.eviware.soapui.impl.wsdl.WsdlProject.saveIn(WsdlProject.java:861)
at com.eviware.soapui.impl.wsdl.WsdlProject.saveIn(WsdlProject.java:851)
at com.eviware.soapui.impl.wsdl.WsdlProjectWithRestMockTest.saveAndReloadProject(WsdlProjectWithRestMockTest.java:125)
at com.eviware.soapui.impl.wsdl.WsdlProjectWithRestMockTest.shouldNotResortMockOperationsOnReload(WsdlProjectWithRestMockTest.java:102)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:47)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:44)
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:271)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:70)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:50)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:238)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:63)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:236)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:53)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:229)
at org.junit.runners.ParentRunner.run(ParentRunner.java:309)
at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:249)
at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:142)
at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:113)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray(ReflectionUtils.java:189)
at org.apache.maven.surefire.booter.ProviderFactory$ProviderProxy.invoke(ProviderFactory.java:165)
at org.apache.maven.surefire.booter.ProviderFactory.invokeProvider(ProviderFactory.java:85)
at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:104)
at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:75)
The weird thing is that the assertion that fails appears to be inside one of the classes in the xbean-fixed-2.4.0.jar for which the source is not in smartbear's maven2 repo...
Anybody have an idea ?
Thanks in advance,
Marc Paquette