sahaya / rest-assured

Automatically exported from code.google.com/p/rest-assured
0 stars 0 forks source link

Logging of request's full URI #356

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Is this possible to add logging for the full URI being called?

For example, for:

RestAssured.baseURI = "http://example.com";
RestAssured.basePath = "/somePath";
RestAssured.port = 8080;

given()
.queryParam("param", "value")
.when()
.get("/someResource")
.log().resourceURI();

logged output would be:
http://example.com:8080/somePath/someResource?param=value

Currently I'm using rest-assured version 2.3.2 and couldn't find a similar 
feature.

Original issue reported on code.google.com by b.zulaw...@gmail.com on 29 Sep 2014 at 12:33

GoogleCodeExporter commented 9 years ago
Add log().all() after given() and it should log the request. See usage guide 
(search for logging).

Original comment by johan.ha...@gmail.com on 30 Sep 2014 at 4:34