SoapUI Groovy Script DataSource
Hello,
I'm trying to make a groovy script for a data source that will iterate through an array of codes of size x and store them in the results.
This is the code I have so far
__________________________________________________________________
List codeList = testRunner.testCase.getPropertyValue("rightCode").split(/ /)
def size = codeList.size()
for (i = 0; i< size; i++)
{
result["rightCode"] = codeList.get(i)
}
___________________________________________________________________
The problem with this is whenever the results displays it will display for example if the original array was size 10, it will store 10 of the last element in that array instead of all of the elements.
I think the problem might be that I have I do not know what code to use to get to the next row so it doesnt keep writing over row 1?