Hi,
I want to show up rest assured logs (Request & Response both) in my reports (Surefire/ TestNG) for all the failed test cases.
I am able to print the logs (both request & response) in console whenever failure occurs using below Rest Assured inbuilt method:
given().config(RestAssured.config().logConfig(logConfig().enableLoggingOfRequestAndResponseIfValidationFails())).
But not able to integrate with my reports, Reports only shows the partial logs like below
createTestAction(com.restapitest.actions.TestAction) Time elapsed: 1.102 s <<< FAILURE!
java.lang.AssertionError:
1 expectation failed.
Expected status code <201> but was <500>.
at com.restapitest.actions.createTestAction.(TestAction.java:45)
Can someone help me to achieve this?
---
Thanks,
Tausif