@@ -503,7 +503,7 @@ public void doesntRetryAfterResponseIsSent() throws Throwable {
503503 public void throwsFeignExceptionIncludingBody () throws Throwable {
504504 server .enqueue (new MockResponse ().setBody ("success!" ));
505505
506- TestInterfaceAsync api = AsyncFeign .asyncBuilder ().decoder ((response , type ) -> {
506+ TestInterfaceAsync api = AsyncFeign .builder ().decoder ((response , type ) -> {
507507 throw new IOException ("timeout" );
508508 }).target (TestInterfaceAsync .class , "http://localhost:" + server .getPort ());
509509
@@ -524,7 +524,7 @@ public void throwsFeignExceptionIncludingBody() throws Throwable {
524524 public void throwsFeignExceptionWithoutBody () {
525525 server .enqueue (new MockResponse ().setBody ("success!" ));
526526
527- TestInterfaceAsync api = AsyncFeign .asyncBuilder ().decoder ((response , type ) -> {
527+ TestInterfaceAsync api = AsyncFeign .builder ().decoder ((response , type ) -> {
528528 throw new IOException ("timeout" );
529529 }).target (TestInterfaceAsync .class , "http://localhost:" + server .getPort ());
530530
@@ -549,7 +549,7 @@ public void whenReturnTypeIsResponseNoErrorHandling() throws Throwable {
549549 ExecutorService execs = Executors .newSingleThreadExecutor ();
550550
551551 // fake client as Client.Default follows redirects.
552- TestInterfaceAsync api = AsyncFeign .<Void >asyncBuilder ()
552+ TestInterfaceAsync api = AsyncFeign .<Void >builder ()
553553 .client (new AsyncClient .Default <>((request , options ) -> response , execs ))
554554 .target (TestInterfaceAsync .class , "http://localhost:" + server .getPort ());
555555
@@ -625,10 +625,10 @@ public void equalsHashCodeAndToStringWork() {
625625 Target <OtherTestInterfaceAsync > t3 =
626626 new HardCodedTarget <>(OtherTestInterfaceAsync .class ,
627627 "http://localhost:8080" );
628- TestInterfaceAsync i1 = AsyncFeign .asyncBuilder ().target (t1 );
629- TestInterfaceAsync i2 = AsyncFeign .asyncBuilder ().target (t1 );
630- TestInterfaceAsync i3 = AsyncFeign .asyncBuilder ().target (t2 );
631- OtherTestInterfaceAsync i4 = AsyncFeign .asyncBuilder ().target (t3 );
628+ TestInterfaceAsync i1 = AsyncFeign .builder ().target (t1 );
629+ TestInterfaceAsync i2 = AsyncFeign .builder ().target (t1 );
630+ TestInterfaceAsync i3 = AsyncFeign .builder ().target (t2 );
631+ OtherTestInterfaceAsync i4 = AsyncFeign .builder ().target (t3 );
632632
633633 assertThat (i1 ).isEqualTo (i2 ).isNotEqualTo (i3 ).isNotEqualTo (i4 );
634634
@@ -651,7 +651,7 @@ public void decodeLogicSupportsByteArray() throws Throwable {
651651 byte [] expectedResponse = {12 , 34 , 56 };
652652 server .enqueue (new MockResponse ().setBody (new Buffer ().write (expectedResponse )));
653653
654- OtherTestInterfaceAsync api = AsyncFeign .asyncBuilder ().target (OtherTestInterfaceAsync .class ,
654+ OtherTestInterfaceAsync api = AsyncFeign .builder ().target (OtherTestInterfaceAsync .class ,
655655 "http://localhost:" + server .getPort ());
656656
657657 assertThat (unwrap (api .binaryResponseBody ())).containsExactly (expectedResponse );
@@ -662,7 +662,7 @@ public void encodeLogicSupportsByteArray() throws Exception {
662662 byte [] expectedRequest = {12 , 34 , 56 };
663663 server .enqueue (new MockResponse ());
664664
665- OtherTestInterfaceAsync api = AsyncFeign .asyncBuilder ().target (OtherTestInterfaceAsync .class ,
665+ OtherTestInterfaceAsync api = AsyncFeign .builder ().target (OtherTestInterfaceAsync .class ,
666666 "http://localhost:" + server .getPort ());
667667
668668 CompletableFuture <?> cf = api .binaryRequestBody (expectedRequest );
@@ -733,7 +733,7 @@ public void mapAndDecodeExecutesMapFunction() throws Throwable {
733733 server .enqueue (new MockResponse ().setBody ("response!" ));
734734
735735 TestInterfaceAsync api =
736- AsyncFeign .asyncBuilder ().mapAndDecode (upperCaseResponseMapper (), new StringDecoder ())
736+ AsyncFeign .builder ().mapAndDecode (upperCaseResponseMapper (), new StringDecoder ())
737737 .target (TestInterfaceAsync .class , "http://localhost:" + server .getPort ());
738738
739739 assertEquals ("RESPONSE!" , unwrap (api .post ()));
@@ -962,7 +962,7 @@ public Exception decode(String methodKey, Response response) {
962962
963963 static final class TestInterfaceAsyncBuilder {
964964
965- private final AsyncFeign .AsyncBuilder <Void > delegate = AsyncFeign .<Void >asyncBuilder ()
965+ private final AsyncFeign .AsyncBuilder <Void > delegate = AsyncFeign .<Void >builder ()
966966 .decoder (new Decoder .Default ()).encoder (new Encoder () {
967967
968968 @ SuppressWarnings ("deprecation" )
@@ -1018,31 +1018,31 @@ TestInterfaceAsync target(String url) {
10181018 @ Test
10191019 public void testNonInterface () {
10201020 thrown .expect (IllegalArgumentException .class );
1021- AsyncFeign .asyncBuilder ().target (NonInterface .class , "http://localhost" );
1021+ AsyncFeign .builder ().target (NonInterface .class , "http://localhost" );
10221022 }
10231023
10241024 @ Test
10251025 public void testExtendedCFReturnType () {
10261026 thrown .expect (IllegalArgumentException .class );
1027- AsyncFeign .asyncBuilder ().target (ExtendedCFApi .class , "http://localhost" );
1027+ AsyncFeign .builder ().target (ExtendedCFApi .class , "http://localhost" );
10281028 }
10291029
10301030 @ Test
10311031 public void testLowerWildReturnType () {
10321032 thrown .expect (IllegalArgumentException .class );
1033- AsyncFeign .asyncBuilder ().target (LowerWildApi .class , "http://localhost" );
1033+ AsyncFeign .builder ().target (LowerWildApi .class , "http://localhost" );
10341034 }
10351035
10361036 @ Test
10371037 public void testUpperWildReturnType () {
10381038 thrown .expect (IllegalArgumentException .class );
1039- AsyncFeign .asyncBuilder ().target (UpperWildApi .class , "http://localhost" );
1039+ AsyncFeign .builder ().target (UpperWildApi .class , "http://localhost" );
10401040 }
10411041
10421042 @ Test
10431043 public void testrWildReturnType () {
10441044 thrown .expect (IllegalArgumentException .class );
1045- AsyncFeign .asyncBuilder ().target (WildApi .class , "http://localhost" );
1045+ AsyncFeign .builder ().target (WildApi .class , "http://localhost" );
10461046 }
10471047
10481048
0 commit comments