diff options
Diffstat (limited to 'jdisc_http_service/src/test/java/com/yahoo/jdisc/http/client/ProxyServerFactoryTestCase.java')
-rw-r--r-- | jdisc_http_service/src/test/java/com/yahoo/jdisc/http/client/ProxyServerFactoryTestCase.java | 42 |
1 files changed, 0 insertions, 42 deletions
diff --git a/jdisc_http_service/src/test/java/com/yahoo/jdisc/http/client/ProxyServerFactoryTestCase.java b/jdisc_http_service/src/test/java/com/yahoo/jdisc/http/client/ProxyServerFactoryTestCase.java deleted file mode 100644 index 7f5e22e48da..00000000000 --- a/jdisc_http_service/src/test/java/com/yahoo/jdisc/http/client/ProxyServerFactoryTestCase.java +++ /dev/null @@ -1,42 +0,0 @@ -// Copyright 2016 Yahoo Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. -package com.yahoo.jdisc.http.client; - -import com.ning.http.client.ProxyServer; -import org.testng.annotations.Test; - -import java.net.URI; - -import static org.testng.AssertJUnit.assertEquals; -import static org.testng.AssertJUnit.assertNull; - -/** - * @author <a href="mailto:simon@yahoo-inc.com">Simon Thoresen Hult</a> - */ -public class ProxyServerFactoryTestCase { - - @Test(enabled = false) - public void requireThatProxyServerFactoryWorks() { - assertNull(ProxyServerFactory.newInstance(null)); - - ProxyServer proxy = ProxyServerFactory.newInstance(URI.create("http://localhost:1234")); - assertEquals(ProxyServer.Protocol.HTTP, proxy.getProtocol()); - assertEquals("localhost", proxy.getHost()); - assertEquals(1234, proxy.getPort()); - assertNull(proxy.getPrincipal()); - assertNull(proxy.getPassword()); - - proxy = ProxyServerFactory.newInstance(URI.create("http://foo@localhost:1234")); - assertEquals(ProxyServer.Protocol.HTTP, proxy.getProtocol()); - assertEquals("localhost", proxy.getHost()); - assertEquals(1234, proxy.getPort()); - assertEquals("foo", proxy.getPrincipal()); - assertNull(proxy.getPassword()); - - proxy = ProxyServerFactory.newInstance(URI.create("https://foo:bar@localhost:1234")); - assertEquals(ProxyServer.Protocol.HTTPS, proxy.getProtocol()); - assertEquals("localhost", proxy.getHost()); - assertEquals(1234, proxy.getPort()); - assertEquals("foo", proxy.getPrincipal()); - assertEquals("bar", proxy.getPassword()); - } -} |