containsString("bodyFileName\" : \"body-please-record-this"));
}
@Test
public void recordsRequestHeadersWhenSpecifiedOnCommandLine() throws Exception {
WireMock otherServerClient = start8084ServerAndCreateClient();
startRunner("--record-mappings", "--match-headers", "Accept");
givenThat(get(urlEqualTo("/please/record-headers"))
.willReturn(aResponse().proxiedFrom("http://localhost:8084")));
otherServerClient.register(
get(urlEqualTo("/please/record-headers"))
.willReturn(aResponse().withStatus(HTTP_OK).withBody("Proxied body")));
testClient.get("/please/record-headers", withHeader("accept", "application/json"));