@Test
  void followRedirectsIsFalse() throws Throwable {
    String redirectPath = "/redirected";

    server.enqueue(buildMockResponseWithLocationHeader(redirectPath));
    Request.Options options = buildRequestOptions(false);

    final TestInterfaceAsync api =
        new TestInterfaceAsyncBuilder()
            .options(options)
            .target("http://localhost:" + server.getPort());

    Response response = unwrap(api.response());
    final String path = response.headers().get("location").stream().findFirst().orElse(null);
    assertThat(response).isNotNull();
    assertThat(path).isNotNull();
    assertThat(response.status()).isEqualTo(302);
    assertThat(server.takeRequest().getPath()).isEqualTo("/");
    assertThat(path).contains("/redirected");
  }
The type of a parameter value may not be the desired type to encode as. Prefer the interface
type.
hc5/src/test/java/feign/hc5/AsyncApacheHttp5ClientTest.java