[英]Global property is not getting added when saving it from groovy script using “launch test runner”
com.eviware.soapui.model.propertyexpansion.PropertyExpansionUtils.globalProperties.setPropertyValue('userID', 'ID from response')
有人對此有想法嗎?
預先感謝您的回答。
這是可以設置全局屬性值的常規腳本。
Groovy腳本
def newValue = 'testsetvalue'
//set the value to global property called PROPERTY_NAME
com.eviware.soapui.SoapUI.globalProperties.setPropertyValue('PROPERTY_NAME', newValue)
// get the property value which was set above.
def getNewValue = com.eviware.soapui.SoapUI.globalProperties.getPropertyValue('PROPERTY_NAME')
//assert it
assert getNewValue == newValue
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.