BAEL-4825 (#10616)
* BAEL-4825 * BAEL-4825 added integration tests * BAEL-4825 Fix line continuation indents * BAEL-4825 Fix line continuation indents
This commit is contained in:
+5
-5
@@ -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());
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user