use of io.vertx.core.net.ProxyOptions in project vert.x by eclipse.
the class Http1xProxyTest method testWsNonProxyHosts.
@Test
public void testWsNonProxyHosts() throws Exception {
startProxy(null, ProxyType.HTTP);
testWebSocket(createBaseServerOptions(), new HttpClientOptions().addNonProxyHost("localhost").setProxyOptions(new ProxyOptions().setType(ProxyType.HTTP).setHost(DEFAULT_HTTP_HOST).setPort(proxy.getPort())), false);
}
use of io.vertx.core.net.ProxyOptions in project vert.x by eclipse.
the class Http1xProxyTest method testWsSocks5Proxy.
@Test
public void testWsSocks5Proxy() throws Exception {
startProxy(null, ProxyType.SOCKS5);
testWebSocket(createBaseServerOptions(), new HttpClientOptions().setProxyOptions(new ProxyOptions().setType(ProxyType.SOCKS5).setHost(DEFAULT_HTTP_HOST).setPort(proxy.getPort())), true);
}
use of io.vertx.core.net.ProxyOptions in project vert.x by eclipse.
the class Http1xProxyTest method testWssSocks5Proxy.
@Test
public void testWssSocks5Proxy() throws Exception {
startProxy(null, ProxyType.SOCKS5);
testWebSocket(createBaseServerOptions().setSsl(true).setKeyCertOptions(Cert.SERVER_JKS.get()), new HttpClientOptions().setSsl(true).setTrustOptions(Cert.SERVER_JKS.get()).setProxyOptions(new ProxyOptions().setType(ProxyType.SOCKS5).setHost(DEFAULT_HTTP_HOST).setPort(proxy.getPort())), true);
}
Aggregations