Forum Discussion
mcbootus
15 years agoContributor
Dear Henrik,
Thank you for your assistance.
Yes they are groovy lists created like this:
a = testRunner.testCase.testSteps["PropertiesXML"].getPropertyValue("block number")
b = testRunner.testCase.testSteps["PropertiesXML"].getPropertyValue("code")
c = testRunner.testCase.testSteps["PropertiesXML"].getPropertyValue("eventDateTime")
d = testRunner.testCase.testSteps["PropertiesXML"].getPropertyValue("comment")
e = testRunner.testCase.testSteps["PropertiesXML"].getPropertyValue("transmissionStatus")
f = testRunner.testCase.testSteps["PropertiesXML"].getPropertyValue("transmissionVersion")
myList = [a,b,c,d,e,f]
I believe the date is a string just grabbed via XPath from the XML output - I may need to parse the date (or convert it to a date datatype) to compare it with the Database value properly - but for now its a string.
Maybe it is easier to drop the list coding entirely and to create and array where each pass of the loop stores the 6 values into a row of the array, and then to rearrange the rows that way?
Thanks again,
Armen
Thank you for your assistance.
Yes they are groovy lists created like this:
a = testRunner.testCase.testSteps["PropertiesXML"].getPropertyValue("block number")
b = testRunner.testCase.testSteps["PropertiesXML"].getPropertyValue("code")
c = testRunner.testCase.testSteps["PropertiesXML"].getPropertyValue("eventDateTime")
d = testRunner.testCase.testSteps["PropertiesXML"].getPropertyValue("comment")
e = testRunner.testCase.testSteps["PropertiesXML"].getPropertyValue("transmissionStatus")
f = testRunner.testCase.testSteps["PropertiesXML"].getPropertyValue("transmissionVersion")
myList = [a,b,c,d,e,f]
I believe the date is a string just grabbed via XPath from the XML output - I may need to parse the date (or convert it to a date datatype) to compare it with the Database value properly - but for now its a string.
Maybe it is easier to drop the list coding entirely and to create and array where each pass of the loop stores the 6 values into a row of the array, and then to rearrange the rows that way?
Thanks again,
Armen