I am doing Data driven testing for JSON request using Soap UI free version. I have done the parameterization using Excel as Datasource. Now I want to validate the response for each input value. Can anyone help me on how can I proceed with this?
Asked
Active
Viewed 132 times
1 Answers
1
You have to use Groovy Scripiting for that..
for example
Request="""{
"qoteRef": "H0005T",
"lineusiness": "4",
"scief": "A02",
"pode": "CH7ND",
"do": "1977-06-12",
"soeOfB": "hello"
}"""
Below code can read one element of json and then you can validate it
def json= new JsonSlurper().parseText(Request)
def quoteRef=json.qoteRef
using JsonSlurper inside Groovy Script you can proceed with validations

Gaurav Khurana
- 3,423
- 2
- 29
- 38
-
mona could you upvote and accept it as answer. If it helped you – Gaurav Khurana Oct 26 '18 at 10:44