Fix deprecation warning

See gh-23256
pull/23585/head
Phillip Webb 4 years ago
parent 507fae5141
commit f5ae58e8e5

@ -75,7 +75,7 @@ class ErrorMvcAutoConfigurationTests {
ErrorAttributes errorAttributes = context.getBean(ErrorAttributes.class);
DispatcherServletWebRequest webRequest = createWebRequest(new IllegalStateException("Exception message"),
false);
Map<String, Object> attributes = errorAttributes.getErrorAttributes(webRequest, true);
Map<String, Object> attributes = errorAttributes.getErrorAttributes(webRequest, withAllOptions());
attributes.put("timestamp", Clock.systemUTC().instant());
errorView.render(attributes, webRequest.getRequest(), webRequest.getResponse());
assertThat(webRequest.getResponse().getContentType()).isEqualTo("text/html;charset=UTF-8");

Loading…
Cancel
Save