Registro si se produce un error de validación de la api

Ejemplos de código

0
0

registro si se produce un error de validación de la api

Log if validation fails
Since REST Assured 2.3.1 you can log the
request or response only if the validation fails.
To log the request do:

given().log().ifValidationFails(). ..
To log the response do:

.. .then().log().ifValidationFails(). ..
It's also possible to enable this for both
the request and the response at the same time using the LogConfig:

given().config(RestAssured.config().
logConfig(logConfig().enableLoggingO
fRequestAndResponseIfValidationFails(HEADERS))). ..
This will log only the headers if validation fails.

There's also a shortcut for enabling logging
of the request and response for all requests if validation fails:

RestAssured.enableLoggingOfRequestAndResponseIfValidationFails();

Páginas relacionadas

Páginas de ejemplo relacionadas

En otros idiomas

Esta página está en otros idiomas

Русский
..................................................................................................................
English
..................................................................................................................
Italiano
..................................................................................................................
Polski
..................................................................................................................
Română
..................................................................................................................
한국어
..................................................................................................................
हिन्दी
..................................................................................................................
Français
..................................................................................................................
Türk
..................................................................................................................
Česk
..................................................................................................................
Português
..................................................................................................................
ไทย
..................................................................................................................
中文
..................................................................................................................
Slovenský
..................................................................................................................
Íslensk
..................................................................................................................