use of org.apache.tapestry5.services.Response in project tapestry-5 by apache.
the class KaptchaUnitTest method cache_control_header.
@SuppressWarnings("unchecked")
@Test
public void cache_control_header() {
PageTester tester = new PageTester("kaptcha.demo", "app");
final TestableResponse response = tester.renderPageAndReturnResponse("KaptchaDemo");
final List<String> headers = (List<String>) response.getHeaders("Cache-Control");
assert "no-store, no-cache, must-revalidate".equals(headers.get(0));
assert "post-check=0, pre-check=0".equals(headers.get(1));
}
Aggregations