Commit 080a2f5c authored by Andy Wilkinson's avatar Andy Wilkinson

Align with Framework’s removal of charset attribute from application/json

Closes gh-16979
parent 892e517c
......@@ -110,9 +110,8 @@ public class CloudFoundryActuatorAutoConfigurationTests {
"vcap.application.cf_api:https://my-cloud-controller.com")
.run((context) -> {
MockMvc mockMvc = MockMvcBuilders.webAppContextSetup(context).build();
mockMvc.perform(get("/cloudfoundryapplication"))
.andExpect(header().string("Content-Type",
ActuatorMediaType.V2_JSON + ";charset=UTF-8"));
mockMvc.perform(get("/cloudfoundryapplication")).andExpect(
header().string("Content-Type", ActuatorMediaType.V2_JSON));
});
}
......
......@@ -44,8 +44,8 @@ public class WebMvcTestHateoasIntegrationTests {
@Test
public void plainResponse() throws Exception {
this.mockMvc.perform(get("/hateoas/plain")).andExpect(header()
.string(HttpHeaders.CONTENT_TYPE, "application/json;charset=UTF-8"));
this.mockMvc.perform(get("/hateoas/plain"))
.andExpect(header().string(HttpHeaders.CONTENT_TYPE, "application/json"));
}
@Test
......
......@@ -56,7 +56,7 @@ class SampleHateoasApplicationTests {
HttpMethod.GET, request, String.class);
assertThat(response.getStatusCode()).isEqualTo(HttpStatus.OK);
assertThat(response.getHeaders().getContentType())
.isEqualTo(MediaType.parseMediaType("application/json;charset=UTF-8"));
.isEqualTo(MediaType.parseMediaType("application/json"));
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment