Groovy script to create Test cases with test steps
I am trying to create 50 Test cases. I need to change only few parameters in each test step. I am requiring to create a groovy script which creates Test Cases. Is there any link which I can refer to?
I need to create 50 test cases like the test case in the image, with change in values with Properties test step. If I have a groovy to do this, without manually creating each test case with change in properties file.
I am looking something more like this
This is very basic, if I am copy a test case, then edit using groovy script, will make my life easier.
It was mentioned in earlier comment that there is values changes for different test cases, so need to copy 50 cases.
I still believe that the data driven is best for this need and have all the test case specific values in the data source (excel ?) a row for a test case and loop it thru the rows. That way, you can even scale it for 100's of tests.
Data driven is the answer for this, however, Soapui can not support the Html results in this apporach.
We tried this apporach to avoid duplication of code, but due to the problem (it does not write Html results as step-wise, rather test case-wise) with Soapui, we gave it up.
Created each step as a test case, now we are able to get the results in .HTML format. The tool should be modified to meet the requirements.
I was away, and I was not able to respond earlier.
with one testcase created manually in the testsuite, I took the testcase.xml and modified, created copies. This works for me. I can do semi automatic now, which is ok for me.