Move all actuators under /application

Context path can be configured via `management.context-path`.

Closes gh-6886
This commit is contained in:
Madhura Bhave
2016-10-13 10:32:38 -07:00
parent 92468d4ffc
commit bcd79dd992
47 changed files with 242 additions and 186 deletions

View File

@@ -105,7 +105,7 @@ public class SampleMethodSecurityApplicationTests {
@Test
public void testManagementProtected() throws Exception {
ResponseEntity<String> entity = this.restTemplate.getForEntity("/beans",
ResponseEntity<String> entity = this.restTemplate.getForEntity("/application/beans",
String.class);
assertThat(entity.getStatusCode()).isEqualTo(HttpStatus.UNAUTHORIZED);
}
@@ -116,7 +116,7 @@ public class SampleMethodSecurityApplicationTests {
"admin", "admin");
this.restTemplate.getRestTemplate().getInterceptors().add(basicAuthInterceptor);
try {
ResponseEntity<String> entity = this.restTemplate.getForEntity("/beans",
ResponseEntity<String> entity = this.restTemplate.getForEntity("/application/beans",
String.class);
assertThat(entity.getStatusCode()).isEqualTo(HttpStatus.OK);
}
@@ -132,7 +132,7 @@ public class SampleMethodSecurityApplicationTests {
"user", "user");
this.restTemplate.getRestTemplate().getInterceptors().add(basicAuthInterceptor);
try {
ResponseEntity<String> entity = this.restTemplate.getForEntity("/beans",
ResponseEntity<String> entity = this.restTemplate.getForEntity("/application/beans",
String.class);
assertThat(entity.getStatusCode()).isEqualTo(HttpStatus.FORBIDDEN);
}