Update test to correct name of metric for request that returns a 401

The request is being made to '/' and, while the application does have
a mapping for '/', that mapping is not looked for before Spring
Security's filter rejects the request with a 401. This means that the
request is considered to be unmapped and this is reflected in the
metric's name.

See #1331 and #1333
This commit is contained in:
Andy Wilkinson 2014-08-06 13:38:42 +01:00
parent 1259057acb
commit e185793396

View File

@ -79,7 +79,7 @@ public class UnsecureManagementSampleActuatorApplicationTests {
assertEquals(HttpStatus.OK, entity.getStatusCode());
@SuppressWarnings("unchecked")
Map<String, Object> body = entity.getBody();
assertTrue("Wrong body: " + body, body.containsKey("counter.status.401.root"));
assertTrue("Wrong body: " + body, body.containsKey("counter.status.401.unmapped"));
}
}