Forum Discussion
nmrao
Champion Level 3
Can you please show the screen shot of your assertion? Could not image what kind of assertion being used.
meital
9 years agoNew Contributor
attached
- PaulMS9 years agoSuper Contributor
Try clicking the select from current button, this shows <VALUE2/> as the expected result so you could copy that into the test case property.
- wujianyy9 years agoContributor
you can select "Script Assertion" to verify some json elements at same time. xml is same. please try research it. This solutions is more flexible.
import groovy.json.JsonSlurper
def responseMessage = messageExchange.response.responseContent
def jsonSlurper = new JsonSlurper().parseText(responseMessage)//verify the Json object isn't empty
assert !(jsonSlurper.isEmpty())
log.info jsonSlurper
Related Content
Recent Discussions
- 15 years ago