lilinkevin / rest-assured

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

Better support for RestAssured.enableLoggingOfRequestAndResponseIfValidationFails() when using specifications #323

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago

    @BeforeClass public static void
    given_response_status_code_is_equal_to_bad_request() {
        RestAssured.responseSpecification = new ResponseSpecBuilder().expectStatusCode(SC_BAD_REQUEST).build();
    }

    @BeforeClass public static void
    given_request_includes_valid_api_key() {
        RestAssured.requestSpecification = new RequestSpecBuilder().addHeader("Api-Key", "1234").build();
    }

    @Test public void
    test() {
        // This doesn't work
        RestAssured.enableLoggingOfRequestAndResponseIfValidationFails();
        get(V1);
    }

Original issue reported on code.google.com by johan.ha...@gmail.com on 4 Apr 2014 at 9:25

GoogleCodeExporter commented 9 years ago

Original comment by johan.ha...@gmail.com on 4 Jun 2014 at 8:18