The test cases consists of REST type steps and groovy scripts. There is a need to log failed REST request url and body
Is there any way, for example in Tear Down script to log failed REST step endpoint url and request json body which was sent?
An example to look at:
If your url endpoint was a variable, you could use that in your log because you know what it it.
def ep = testRunner.testCase.testSteps["Request Step"].testRequest.endpoint
Hi @tos ,
Yes sure you can achieve this by writing your own custom groovy code to capute both endpoint with request and response.