13 years ago
passing values from groovy script to soap request
I’m trying to figure out if there is any way I could pass a value from a groovy script to a soap request. I tried using ‘setpropertyvalue’, to pass it to a property; then do a property transfer to the SOAP request, but for some reason the properties in the test case steps don’t get updated!!
=============
// This is the ‘setpropertyvalue ‘ statement, where I may be going wrong.
def myTestCase = context.testCase
myTestCase.setPropertyValue(‘${Input numbers#num1}’, lines_first)
// ‘Input numbers’ is the name of one of my test case properties.
// ‘num1′ is one of the properties in the property list ‘Input numbers’
// lines_first – This is a value I pull from a txt file, basically it would just be a number.
=============
Any help would be greatly appreciated
=============
// This is the ‘setpropertyvalue ‘ statement, where I may be going wrong.
def myTestCase = context.testCase
myTestCase.setPropertyValue(‘${Input numbers#num1}’, lines_first)
// ‘Input numbers’ is the name of one of my test case properties.
// ‘num1′ is one of the properties in the property list ‘Input numbers’
// lines_first – This is a value I pull from a txt file, basically it would just be a number.
=============
Any help would be greatly appreciated