@Test
  void supportComplexHeaders() throws Exception {
    TestInterface api = new TestInterfaceBuilder().target("http://localhost:" + server.getPort());

    server.enqueue(new MockResponse());
    /* demonstrate that a complex header, like a JSON document, is supported */
    String complex = "{ \"object\": \"value\", \"second\": \"string\" }";

    api.supportComplexHttpHeaders(complex);
    assertThat(server.takeRequest())
        .hasHeaders(MapEntry.entry("custom", Collections.singletonList(complex)))
        .hasPath("/settings");
  }
when you must parse a 2xx status to determine if the operation succeeded or not.
core/src/test/java/feign/FeignTest.java