HttpServletRequestWrapper extends ServletRequestWrapper implements HttpServletRequest { @Override public boolean authenticate(HttpServletResponse response) throws IOException, ServletException { return getWrapped().authenticate(response); } HttpServletRequestWrapper(HttpServletRequest request); @Override boolean authenticate(HttpServletResponse response); @Override String changeSessionId(); @Override String getAuthType(); @Override String getContextPath(); @Override Cookie[] getCookies(); @Override long getDateHeader(String name); @Override String getHeader(String name); @Override Enumeration<String> getHeaderNames(); @Override Enumeration<String> getHeaders(String name); @Override int getIntHeader(String name); @Override String getMethod(); @Override Part getPart(String name); @Override Collection<Part> getParts(); @Override String getPathInfo(); @Override String getPathTranslated(); @Override String getQueryString(); @Override String getRemoteUser(); @Override String getRequestURI(); @Override StringBuffer getRequestURL(); @Override String getRequestedSessionId(); @Override String getServletPath(); @Override HttpSession getSession(); @Override HttpSession getSession(boolean create); @Override Principal getUserPrincipal(); @Override boolean isRequestedSessionIdFromCookie(); @Override boolean isRequestedSessionIdFromURL(); @Deprecated @Override boolean isRequestedSessionIdFromUrl(); @Override boolean isRequestedSessionIdValid(); @Override boolean isUserInRole(String role); @Override void login(String username, String password); @Override void logout(); @Override T upgrade(Class<T> handlerClass);  }
@Test void testAuthenticate() throws Exception { HttpServletRequestWrapper wrapper = new TestHttpServletRequest(null); HttpServletResponseWrapper response = new HttpServletResponseWrapper(null); assertFalse(wrapper.authenticate(response)); }