Contributions
SoapUI (Free) testrunner.bat not showing my assertions
Hi there, I am facing the following problem. I have a project, with a testsuite, 1 testcase containing 5 teststeps. 1 of the teststeps contains an assertion that will fail (I added this on purpose). When executing the testsuite in SoapUI, that step failes due to the assertion. So far so good... When running this testsuite with testrunner.bat I also get an error that that step is failing.. What I dont understand is the following message in the command window: (check the bold) SoapUI 5.5.0 TestCaseRunner Summary ----------------------------- Time Taken: 26650ms Total TestSuites: 1 Total TestCases: 1 (1 failed) Total TestSteps: 5 Total Request Assertions: 0 Total Failed Assertions: 0 Total Exported Results: 1 16:16:05,540 ERROR [SoapUITestCaseRunner] java.lang.Exception: TestCase [SmokeTest] failed without assertions 16:16:05,540 ERROR [SoapUI] An error occurred [TestCase [SmokeTest] failed without assertions ], see error log for details java.lang.Exception: TestCase [SmokeTest] failed without assertions This info seems not ok ??? Seems like the counter for the assertions is not working ??? Info that the testcase is failed without assertions seems faulty, no ?! Since it is actually failing due to the assertion...628Views0likes0CommentsRe: Groovy script get certain tag(s) from response xml
I am using windows..Dont really see the problem. If I can create a file with a string in it and this work, the same should work with the PrevalidationMin value in it. But that gives the NullPointerException. Dont really understand why the file path wouldnt work in the 2nd example...12KViews0likes2CommentsRe: Groovy script get certain tag(s) from response xml
Rupert, Thanks for your reply. However I still get an error when trying to create the file. I get a NullPointerException. When I write new File('/yourfile.csv').write("Test") the script creates a new file with the string Test in it. When I write new File('/yourfile.csv').write(PrevalidationMin) I get the NullPointerException12KViews0likes6CommentsGroovy script get certain tag(s) from response xml
Hi, I am rather new to groovy scripting and have a question. I have a xml request that gives a certain response: <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"> <SOAP-ENV:Header xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"/> <soap:Body> <ns2:MT_GetValidationRanges_response xmlns:ns2="http://www.eandis.be/CAPTATIE/MF881/SPI893"> <GetValidationRangesResponse> <EANs> <EAN> <EANNumber>541448860004900201</EANNumber> <MeteringDevices> <MeteringDevice> <Id>7100627867</Id> <SerialNumber>23598095</SerialNumber> <DeviceLabel>1</DeviceLabel> <Indexes> <Index> <RegisterIdentifier>TH</RegisterIdentifier> <RegisterSequence>1</RegisterSequence> <PrevalidationMin>6674</PrevalidationMin> <PrevalidationMax>7954</PrevalidationMax> <PrevalidationDigits>8</PrevalidationDigits> <PrevalidationDecimals>3</PrevalidationDecimals> </Index> </Indexes> </MeteringDevice> </MeteringDevices> </EAN> </EANs> </GetValidationRangesResponse> <Status> <Code>0</Code> <Description>OK</Description> </Status> </ns2:MT_GetValidationRanges_response> </soap:Body> </soap:Envelope> From this reponse I would like to get the value of <PrevalidationMin> and write this to a csv file. I already found the following code online def oGroovyUtils = new com.eviware.soapui.support.GroovyUtils( context ) def oResponseHolder = oGroovyUtils.getXmlHolder("Single GetValidationRanges" + "#Response") oResponseHolder.getNodeValue( "PrevalidationMin") But still need some code. I cant find the last part. Can someone help me please ? ThanksSolved12KViews0likes9Comments