Forum Discussion
Hi ,
I should be able to extract any value. For now you can look into href element under collection.
Thanks
Have you looked into the sample provided
- piyu_sarda10 years agoOccasional Contributor
Hi Rao,
Sorry I could not reply earlier.I have looked at your answer and i tried it using groovy but it still says invalid JSON. I was completely lost after and tried various permutations.
After banging my head for a good number of hours, finally I came to know the root cause of this silly issue. The response JSON contains a empty line at the top which SOAP UI is not able to process. Although the JSON view of Response in the Test Step shows a valid JSON but when performing a property transfer, it looks like it is picking up from raw response which has an empty line at the top. My dev team is not going to definitely fix this in a shorter term as the our APIs are used by other applications and no one complained about it.
Is there a way in SOAP UI to get around it?
Thanks,
Piyu
- nmrao10 years agoChampion Level 3
I would suggest you to discuss with your development team to findout why the response is invalid as soapUI can't do much to the invalid response sent by your application.
- piyu_sarda10 years agoOccasional Contributor
Hi Rao,
Its not an invalid response. SOAP UI is able to process the response. Since it is able to parse and show the response in JSON view, it proves that response is valid. Its throwing an error only when trying to do a property transfer directly or via a groovy code.
I have attached a simple json file which you can call from a sample project and try to extract a value using property transfer. It will show the JSON response in the view but property transfer will fail. So this definitely looks like a bug which needs to be fixed. If it was a problem with the response, then SOAP UI should not have picked up JSON in first place and display in JSON tab of response.
Could you please check again?
Regards,
Piyu
Related Content
- 10 months ago
- 5 years ago
- 6 years ago
- 2 years ago
Recent Discussions
- 15 years ago