Forum Discussion
MConneely
4 years agoStaff
A couple of things to mention.
ReadyAPI offers out of the box assertions, so that you don't necessarily have to script assertions. There may be one available that might assist you
https://support.smartbear.com/readyapi/docs/testing/assertions/reference/index.html
On the script itself, there doesn't seem to be any brackets ( [ ] ) at the start/end of your JSON. When added in, and I tried some of your script, I logged the following (debug purposes).
slurpedResponse*.isProcess = [false, true]
slurpedResponse[0].isProcess = false
slurpedResponse[1].isProcess = true
Have you thought about iterating through your array of responses to check your values as a test? its useful to use the log.info() to write script logs to console for checking values
Related Content
- 6 years ago
- 9 years ago
- 8 years ago
- 11 years ago