Reputation: 128
As an example, this scenario will fail with an error, "cannot convert, not a json string: [type: NULL, value: null]":
@report=false Scenario: POST request; 200 response Given url 'http://localhost:8080' And request { "id": "123" } When method post * def requestBody = karate.prevRequest.body * json requestJson = requestBody
However, if you remove the @report=false tag (or set it to 'true'), the request body is captured just fine.
Is this a bug or am I missing something obvious here?
Thanks!
Upvotes: 1
Views: 189
Reputation: 58088
It may be a bug, but can you please use the 1.0 series: https://github.com/intuit/karate/wiki/1.0-upgrade-guide
All development is focusing on that, and as of now you should be able to test 0.9.9.RC4 - and if you still see an issue, please follow this process: https://github.com/intuit/karate/wiki/How-to-Submit-an-Issue
Upvotes: 0