Forum Discussion

Rookie's avatar
Rookie
Occasional Contributor
8 years ago
Solved

Would like to run another TestCase using Groovy

Hi,   I'm totally new to this.  I am trying to Execute another TestCase using Groovy.  For some reason this code is not working for me.  I am using ReadyAPI 1.6.0:   //get test case from other ...
  • Radford's avatar
    8 years ago

    What error are you getting? This is the code that I use to call another test case from within the same test suite:

     

    import com.eviware.soapui.support.types.StringToObjectMap
    
    def testCase = testRunner.getTestCase().getTestSuite().getTestCaseByName('Test Case Name')
    testCase.setPropertyValue('Proprety Name', 'Property Value')
    testCase.run(new StringToObjectMap(), false)

     

    This looks very close to your code...