1

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?

mona
  • 151
  • 2
  • 2
  • 8

1 Answers1

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