I'm currently trying to generate a report for my test suite in SoapUI.
My old working code was a line this, in the testSuite teardown script :
def testc = project.testSuites['TestSuite'].testCases['TestCase'].testSteps['xxxxx']
But it had to be duplicated for each new test step.
The code that I'm trying to use is this one :
for (service in project.testSuites) {
for (testCase in service.testCases) {
for (testStep in testCase.testSteps) {
someFile.withWriterAppend{out ->out.println testStep.toString()}
}
}
}
Wich is giving me this error :
groovy?lang.MissingPropertyException: No such property: testCases for class: javaUtil.hashMap$Node
Since I'm using the same path to access every test step, I was surprised to not be able to do it with an iteration.