@Test
public void testNoDefaultHeadersForConnectRequest() throws Exception {

    HttpRequest request = new BasicHttpRequest("CONNECT", "www.somedomain.com");
    List<Header> defheaders = new ArrayList<Header>();
    defheaders.add(new BasicHeader("custom", "stuff"));
    request.getParams().setParameter(AllClientPNames.DEFAULT_HEADERS, defheaders);
    HttpContext context = new BasicHttpContext();
    HttpRequestInterceptor interceptor = new RequestDefaultHeaders();
    interceptor.process(request, context);
    Header header1 = request.getFirstHeader("custom");
    Assert.assertNull(header1);
}