Forum Discussion

Santhy's avatar
Santhy
New Contributor
2 years ago

testRunner report does not give test case status of the called SoapUI project

I have two SoapUI projects in the same location(sample1-soapui-project.xml and sample2-soapui-project.xml) with few test suites in both projects. And I am calling sample2-soapui-project.xml from sample1-soapui-project.xml using groovy script. While running the first project using testRunner my second project gets executed successfully , but the test runner reports contains only the details of sample1-soapui-Project.xml project. How to get the test case status from the 2nd project in the testRunner report

 

testRunner command is : testrunner.bat -r -A -j -J -M -I -f"D:\SoapUI Test Results" D:\SoapProject_Latest\sample1-soapui-project.xml

 

Here is the code snippet that call the sample2-soapui-Project.xml from sample1-soapui-Project.xml

 

import com.eviware.soapui.model.project.ProjectFactoryRegistry
import com.eviware.soapui.impl.wsdl.WsdlProjectFactory

def workspace = testRunner.testCase.testSuite.project.workspace
def projectPath = new com.eviware.soapui.support.GroovyUtils(context).projectPath
def testProject = (workspace==null) ? 
  ProjectFactoryRegistry.getProjectFactory(WsdlProjectFactory.WSDL_TYPE).createNew(projectPath+"\\sample2-soapui-project.xml") :
  workspace.getProjectByName("Sample2")p
if(!testProject.open && workspace!=null) workspace.openProject(testProject)
def runStatus = testProject.run(null,true)
No RepliesBe the first to reply