Forum Discussion
SmartBear_Suppo
16 years agoSmartBear Alumni (Retired)
Hello,
The easiest way to manage your endpoint via a Groovy script is probably by creating a TestCase Test Property for it and using a Property Expansion. For example, create a new Test Property in the TestCase named "endpoint" and set the actual endpoint of the request to ${#TestCase#endpoint} (if you will be using the same endpoint for other testcases you may wish to make it a property on TestSuite level or even Project level instead). To change this property in a Groovy TestStep use:
Regards,
Dain
eviware.com
The easiest way to manage your endpoint via a Groovy script is probably by creating a TestCase Test Property for it and using a Property Expansion. For example, create a new Test Property in the TestCase named "endpoint" and set the actual endpoint of the request to ${#TestCase#endpoint} (if you will be using the same endpoint for other testcases you may wish to make it a property on TestSuite level or even Project level instead). To change this property in a Groovy TestStep use:
testRunner.testCase.properties['endpoint'].setValue('new endpoint')
Regards,
Dain
eviware.com
Related Content
- 5 years ago
- 4 years ago
Recent Discussions
- 5 days ago
- 9 days ago
xml to soap
Solved9 days ago