WebClientBuilder extends AbstractWebClientBuilder { public WebClient build() { return buildWebClient(); } WebClientBuilder();   WebClientBuilder(URI uri);   WebClientBuilder(SessionProtocol sessionProtocol, EndpointGroup endpointGroup, @Nullable String path); WebClient build(); @Override WebClientBuilder rpcDecorator(Function<? super RpcClient, ? extends RpcClient> decorator); @Override WebClientBuilder rpcDecorator(DecoratingRpcClientFunction decorator); @Override WebClientBuilder options(ClientOptions options); @Override WebClientBuilder options(ClientOptionValue<?>... options); @Override WebClientBuilder options(Iterable<ClientOptionValue<?>> options); @Override WebClientBuilder option(ClientOption<T> option, T value); @Override WebClientBuilder option(ClientOptionValue<T> optionValue); @Override WebClientBuilder factory(ClientFactory factory); @Override WebClientBuilder writeTimeout(Duration writeTimeout); @Override WebClientBuilder writeTimeoutMillis(long writeTimeoutMillis); @Override WebClientBuilder responseTimeout(Duration responseTimeout); @Override WebClientBuilder responseTimeoutMillis(long responseTimeoutMillis); @Override WebClientBuilder maxResponseLength(long maxResponseLength); @Override WebClientBuilder requestIdGenerator(Supplier<RequestId> requestIdGenerator); @Override WebClientBuilder endpointRemapper(
            Function<? super Endpoint, ? extends EndpointGroup> endpointRemapper); @Override WebClientBuilder decorator(
            Function<? super HttpClient, ? extends HttpClient> decorator); @Override WebClientBuilder decorator(DecoratingHttpClientFunction decorator); @Override WebClientBuilder clearDecorators(); @Override WebClientBuilder addHeader(CharSequence name, Object value); @Override WebClientBuilder addHeaders(
            Iterable<? extends Entry<? extends CharSequence, ?>> headers); @Override WebClientBuilder setHeader(CharSequence name, Object value); @Override WebClientBuilder setHeaders(
            Iterable<? extends Entry<? extends CharSequence, ?>> headers); @Override WebClientBuilder auth(BasicToken token); @Override WebClientBuilder auth(OAuth1aToken token); @Override WebClientBuilder auth(OAuth2Token token);  }
@Test void uriWithNonePlusProtocol() throws Exception { final WebClient client = WebClient.builder("none+https: assertThat(client.uri().toString()).isEqualTo("https: }
@Test void uriWithoutNone() { final WebClient client = WebClient.builder("https: assertThat(client.uri().toString()).isEqualTo("https: }
@Test void endpointWithoutPath() { final WebClient client = WebClient.builder("http", Endpoint.of("127.0.0.1")) .build(); assertThat(client.uri().toString()).isEqualTo("http: }
@Test void endpointWithPath() { final WebClient client = WebClient.builder("http", Endpoint.of("127.0.0.1"), "/foo") .build(); assertThat(client.uri().toString()).isEqualTo("http: }
@Test void authorityHeader() { final String path = "/echo-path?foo=bar"; final RequestHeadersBuilder requestHeadersBuilder = RequestHeaders.builder() .authority("localhost:" + server.httpPort()) .scheme("h2c") .add("param1", "val1") .path(path); final AggregatedHttpRequest request = AggregatedHttpRequest.of( requestHeadersBuilder.method(HttpMethod.GET).build()); final HttpResponse response = WebClient.of().execute(request); assertThat(response.aggregate().join().contentUtf8()).isEqualTo(path); }