super.doFilter(request, response);
}
};
this.filter.doFilter(this.request, this.response, this.chain);
assertThat(this.chain.getRequest(), equalTo((ServletRequest) this.request));
HttpServletResponseWrapper wrapper = (HttpServletResponseWrapper) this.chain
.getResponse();
assertThat(wrapper.getResponse(), equalTo((ServletResponse) this.response));
assertTrue(this.response.isCommitted());
assertThat(wrapper.getStatus(), equalTo(401));
// The real response has to be 401 as well...
assertThat(this.response.getStatus(), equalTo(401));
assertThat(this.response.getForwardedUrl(), equalTo("/error"));
}