Hello,
I have a requirement where after a query to an API it returns a list of JSON objects. I wish to run various checks over each of these objects. I am having trouble, traversing over a list and applying these checks.
This is what I have so far.
`
val v3Scenario = scenario(generateNewScenario)
.exec(
http(getSimulation)
.get(getUrl)
.check(jsonPath("$.result[*]").ofType[String].findAll.saveAs(“resultList”))
).foreach("${resultList}", “result”) {
exec(
check(result.jsonPath($.status).is(live))
.check(???) //etc.
)
}
`
And of course it doesn’t compile, but I wonder if there is something similar I can do get what I want
any help is appreciated.
thanks
Swapnesh.