@Override
  public void doFilter(ServletRequest req, ServletResponse resp, FilterChain chain) throws IOException, ServletException {
    doHttpFilter((HttpServletRequest) req, (HttpServletResponse) resp, chain);
  }
@Test
  public void set_security_headers_secure_request() throws ServletException, IOException {
    HttpServletRequest request = newRequest("GET", "/");
    when(request.getHeader("x-forwarded-proto")).thenReturn("https");

    underTest.doFilter(request, response, chain);

    verify(response).setHeader("X-Frame-Options", "SAMEORIGIN");
    verify(response).setHeader("X-XSS-Protection", "1; mode=block");
    verify(response).setHeader("X-Content-Type-Options", "nosniff");
    verify(response).setHeader("Strict-Transport-Security", "max-age=31536000; includeSubDomains;");
  }