Forum Discussion
- RadfordSuper Contributor
The "responselist" is a GPathResult object. See:
http://docs.groovy-lang.org/latest/html/api/groovy/util/XmlSlurper.html
The following page has example on how to use the XmlSlurper:
http://groovy-lang.org/processing-xml.html
Hopefully that should get you started.
- nmraoChampion Level 2Can you post the raw response? By the way, your question is not clear. Please try to make it clear.
- tania90Occasional Contributor
- tania90Occasional ContributorAny update on this. Waiting for your reply
- tania90Occasional ContributorNot able to parse XML rest response using XmlSlurper and add elements to a list.
- nmraoChampion Level 2I see the xml response that you had attached and that is partial response. You did not mention what is exact problem. Would you please show the same?
- tania90Occasional Contributor
The problem is I am not able to extract and put rest response elements ( First-name, Surname, Title ) in a list for comparison with jdbc response.
On executing the groovy script assertion, I am being returned blank list for rest response when XmlSlurper. With XMLparser also able to extract specific elements not all the elements in the list.
Please suggest changes in my code
- tania90Occasional Contributor
Please reply guys.
- tania90Occasional Contributor
Hi
Not able to sort the jdbcobject and XMLobject list for comparison
- tania90Occasional ContributorPlease reply
Related Content
- 9 years ago
Recent Discussions
- 5 days ago