socaltester
5 years agoContributor
Clone Test Step into Multiple Test Cases Using Groovy
I have a Test Step that I need to clone into all the Test Cases I have within all the Test Suites. Would the following script work when ran against each Test Suite individually:
def slaveTestStep = testRunner.testCase.testSuite.project.getTestSuiteByName("Test Suite").getTestCaseByName("Name") testRunner.testCase.testSuite.project.getTestSuiteByName("Test Suite").get TestCaseByName("Name").cloneTestStepByName(slaveTestStep,"NewName") Tags (0) Add tags