* BAEL-4825

* BAEL-4825 added integration tests

* BAEL-4825 Fix line continuation indents

* BAEL-4825 Fix line continuation indents
This commit is contained in:
Amy DeGregorio
2021-04-01 11:14:25 -04:00
committed by GitHub
parent 9706d7b6fd
commit 86575c861b
2 changed files with 14 additions and 14 deletions
@@ -21,16 +21,16 @@ public class EndpointEnablingIntegrationTest {
@WithMockUser(username = "user", password = "password", roles = "USER")
public void givenWrongAuthentication_whenCallingActuator_thenReturns401() throws Exception {
mockMvc.perform(get("/actuator"))
.andExpect(status().isForbidden());
.andExpect(status().isForbidden());
}
@Test
@WithMockUser(username = "admin", password = "admin", roles = "ADMIN")
public void givenProperAuthentication_whenCallingActuator_thenReturnsExpectedEndpoints() throws Exception {
mockMvc.perform(get("/actuator"))
.andExpect(jsonPath("$._links").exists())
.andExpect(jsonPath("$._links.beans").exists())
.andExpect(jsonPath("$._links.env").exists())
.andExpect(jsonPath("$._links.shutdown").exists());
.andExpect(jsonPath("$._links").exists())
.andExpect(jsonPath("$._links.beans").exists())
.andExpect(jsonPath("$._links.env").exists())
.andExpect(jsonPath("$._links.shutdown").exists());
}
}