Contributions
- 1.7KViews0likes0Comments
missing package org.apache.xmlbeans when running a Test Case from java
I am trying to start to run a TestCase from java more or less like this try { WsdlProject project = new WsdlProject(testxml); TestSuite testSuite = project.getTestSuiteByName(suitename); TestCase testCase = testSuite.getTestCaseByName(testcase); // create empty properties and run synchronously TestRunner runner = testCase.run(new PropertiesMap(), false); Assert.assertEquals(Status.FINISHED, runner.getStatus()); } catch (XmlException e) { Assert.fail("Could not start soapui"); } catch (IOException e) { Assert.fail("Could not start soapui"); } catch (SoapUIException e) { Assert.fail("Could not start soapui"); } But I keep getting the following Exception: package org.apache.xmlbeans does not exist [javac] import org.apache.xmlbeans.XmlException; what am I missing in my class path?3.5KViews0likes1CommentRe: Run test Case fron another project
project = testRunner.getTestCase().getTestSuite().getProject().getWorkspace().getProjectByName(project_name) testSuite = project.getTestSuiteByName(suite_name); testCase = testSuite.getTestCaseByName(testcase_name); // run test case runner = testCase.run(new com.eviware.soapui.support.types.StringToObjectMap(), false) // objectMap, async5.1KViews0likes0CommentsCommandLine Tool - is there a way to accessing other projects ?
I have a workspace with several projects. When I receive a certain request in a MockService from project A, I run a test case from Project B, by the following groovy script. project =context.getMockRunner().getMockService().getProject().getWorkspace().getProjectByName(project_name) testSuite = project.getTestSuiteByName(suite_name); testCase = testSuite.getTestCaseByName(testcase_name); runner = testCase.run(new com.eviware.soapui.support.types.StringToObjectMap(), false) This works perfectly fine within the soapUI GUI. But when I start the MockService of A via command line it is not able to access project B since the workspace is null. Is there another way to get access to project B or is the only solution to pack everything into one big project? Thanks a lot for your help --rah1.1KViews0likes1CommentRe: sql UPDATE statement in Groovy -> soapUI 3.0 crashes
I found the error. I was working on a record that did not fulfill all unique constraints. Now everything works perfectly fine, with result = sql.executeUpdate(myquery) and also with the driver in my preferred location (not in bin/ext). Thanks a lot for your support and sorry for the inconveniences!2.5KViews0likes0CommentsRe: sql UPDATE statement in Groovy -> soapUI 3.0 crashes
Thanks for your fast reply. I purposely did not move the driver jar to bin/ext and with the ClasspathHacker.addURL statement and only SELECTs this has worked fine. I have copied the driver now to bin/ext as you have suggested but it does not make any difference at all. I am working with the open version of soapUI on Linux2.5KViews0likes0CommentsRe: sql UPDATE statement in Groovy -> soapUI 3.0 crashes
Hi Dragica, Thanks a lot for your help and please apologies for my impreciseness. I tried "sql.executeUpdate(query)" but it causes the same effects as before. On the db nothing gets updated, the soapUI 3.0 GUI freezes and the only output I get in the log is [exec] 2009-07-23 10:24:54,295 INFO [viware.soapui.SoapUI:57 ] [AWT-EventQueue-0] Added [file:/share/java/jpository/oracle/product/10.2.0.4.0/jdbc/lib/ojdbc14.jar] to classpath2.5KViews0likes0Comments