kannan
4 years agoOccasional Contributor
Calling a TestSuite from test step of another Test case
I have a requirement to call a Test suite from test step of another Testcases.
Project structure
Our Project structure is
1.TestSuite1
1.1 TestSuite1_Positive
1.2 TestSuite1_Negative
2. TestSuite2
2.1 TestSuite2_Positive.
2.2 TestSuite2_Negative
3. TestSuite3
3.1 Runner
Requirement is to run TestSuite 1 from TestSuite3 --> Runner . Is there any way to achieve this ?
Thanks in advance .
Hi kannan ,
yes, it should be easy to implement it with groovy scripts.
// groovy
def testSuiteList = ["TestSuite1", "TestSuite2", "TestSuite3"]
def ts= null
testSuiteList.each {
ts = testRunner.testCase.testSuite.project.testSuites[it]
ts.run(new com.eviware.soapui.support.types.StringToObjectMap(), false)
}
Thanks,
/Aaron