http-client-branch: set NO_PROXY in RetryWithCookie http-client-branch
authorchegar
Thu, 26 Apr 2018 14:45:28 +0100
branchhttp-client-branch
changeset 56487 6fc81d0648aa
parent 56486 b664a887e277
child 56496 a3937ca907f1
http-client-branch: set NO_PROXY in RetryWithCookie
test/jdk/java/net/httpclient/RetryWithCookie.java
--- a/test/jdk/java/net/httpclient/RetryWithCookie.java	Thu Apr 26 14:42:36 2018 +0100
+++ b/test/jdk/java/net/httpclient/RetryWithCookie.java	Thu Apr 26 14:45:28 2018 +0100
@@ -69,6 +69,7 @@
 import java.util.concurrent.atomic.AtomicLong;
 
 import static java.lang.System.out;
+import static java.net.http.HttpClient.Builder.NO_PROXY;
 import static java.nio.charset.StandardCharsets.UTF_8;
 import static org.testng.Assert.assertEquals;
 import static org.testng.Assert.assertTrue;
@@ -106,6 +107,7 @@
         out.printf("%n---- starting (%s) ----%n", uriString);
         CookieManager cookieManager = new CookieManager();
         HttpClient client = HttpClient.newBuilder()
+                .proxy(NO_PROXY)
                 .followRedirects(Redirect.ALWAYS)
                 .cookieHandler(cookieManager)
                 .sslContext(sslContext)