How to access TestCase custom property in a request?
Hi,
It has been a long time since I worked with SOAPUI, but I am trying to use a custom test step property in a request, but I cannot seem to get it working :(...
In the test step custom properties, I have a property named "Username" with value "XXXXXXXXXX". The test step name is "TC57".
Then, in the request I have I want to get the value of that property in the request.
I have tried:
${#TC57#Username}
${#TestStep#Username}
but neither of those cause the "XXXXXXXXXX" to be inserted into the request.
If I try the same thing with ${#Project#Username} it works fine (it pulls in the value into the request, but I need the property to be at test step level.
What am I doing wrong?
Thanks,
Jim
....
Hi,
I found the answer. The following works:
${#Username}
The explanation is in the message from "richie" in https://community.smartbear.com/t5/SoapUI-Open-Source-Questions/SoapUi-Property-Expansion-within-the-json-of-the-request-body/m-p/217487#M32009.
This part:
"using the 'scope' thing, youre specifying the "level" at which your properties are held relative to your current focus"
Since the property is at teststep level, and I am using the property at the same level, there is no need for any level above the current level.
Jim