private void mockUnsuccessfulRequest(String nonProxyHosts, String fakeHost)
            throws Exception {
        HttpClient client = createHttpClient(nonProxyHosts);
        HttpUriRequest uriRequest = new HttpGet("http://" + fakeHost);
        executeWithRetries(client, uriRequest);
        fail("UnknownHostException is expected!");
    }
The fakeHost does match the nonProxyHosts pattern, so that requests to this fakeHost
will bypass the proxy and throw an UnknownHostException.
aws-java-sdk-core/src/test/java/com/amazonaws/internal/SdkProxyRoutePlannerIntegrationTest.java