Forum Discussion
bennythedroid
Occasional Contributor
First off, thank you.
I was able to transfer and id from the POST Header to a GET in the test case. The only remaining problem is that it inserts the id into the GET with [] around it. So when I try to actually run the GET, it fails because its looking for [idvalue] instead of just "idvalue".
I was able to transfer and id from the POST Header to a GET in the test case. The only remaining problem is that it inserts the id into the GET with [] around it. So when I try to actually run the GET, it fails because its looking for [idvalue] instead of just "idvalue".
bhajanmehta
8 years agoVisitor
bennythedroid : As you are getting value with square bracket [], it means that it is a array of string, can you please have a try with using index, like:
def groovyUtils = new com.eviware.soapui.support.GroovyUtils(context)
groovyUtils.setPropertyValue("Request2", "LTPA", cookie_vals.[0])
- nadamat6 years agoNew Contributor
bhajanmehta
I'm also facing a similar issue.
def value = testRunner.testCase.testSteps["GetToken"].testRequest.response.responseHeaders["Authorization"]
def tc = testRunner.testCase.testSuite.getTestCaseByName("JTY")
tc.setPropertyValue("_csrf", "$value")I'm able to get the value to the required property but in [ ].
Can someone please help me in how to get rid of those square brackets from value.
Related Content
- 5 years ago
- 2 years ago
- 9 years ago
Recent Discussions
- 4 days ago
- 8 days ago
xml to soap
Solved8 days ago