Forum Discussion
nmrao
10 years agoChampion Level 3
Another way to set it a property, so that you would be able to access it from the rest of the steps is:
Have a groovy script with the following line
In the test request step where you required the property use as below
In order to use above variable in another groovy step of the same test case is:
Have a groovy script with the following line
testRunner.testCase.setPropertyValue('GENERATED_ID', UUID.randomUUID().toString())
In the test request step where you required the property use as below
<some_request_element>${#TestCase#GENERATED_ID}</some_request_element>
In order to use above variable in another groovy step of the same test case is:
testRuner.testCase.getProperty('GENERATRED_ID')
//OR
context.expand('${#TestCase#GENERATED_ID}')
Related Content
Recent Discussions
- 3 days agoKLWallace