@@ -165,27 +165,30 @@ public void testExpect100ContinueFailureInAppend() throws Exception {
165165        (AbfsOutputStream ) fs .create (path ).getWrappedStream ());
166166    AbfsClient  spiedClient  = Mockito .spy (os .getClient ());
167167    AbfsHttpOperation [] httpOpForAppendTest  = new  AbfsHttpOperation [2 ];
168-     readyMocksForAppendTest (httpOpForAppendTest , spiedClient );
168+     mockSetupForAppend (httpOpForAppendTest , spiedClient );
169169    Mockito .doReturn (spiedClient ).when (os ).getClient ();
170170    fs .delete (path , true );
171171    os .write (1 );
172172    LambdaTestUtils .intercept (FileNotFoundException .class , () -> {
173173      os .close ();
174174    });
175175    Assertions .assertThat (httpOpForAppendTest [0 ].getExpect100failureReceived ())
176-         .isTrue ();
176+         .describedAs ("First try from AbfsClient will have expect-100 " 
177+             + "header and should fail with expect-100 error." ).isTrue ();
177178    Mockito .verify (httpOpForAppendTest [0 ], Mockito .times (0 ))
178179        .processConnHeadersAndInputStreams (Mockito .any (byte [].class ),
179180            Mockito .anyInt (), Mockito .anyInt ());
180181
181182    Assertions .assertThat (httpOpForAppendTest [1 ].getExpect100failureReceived ())
182-         .isFalse ();
183+         .describedAs ("The retried operation from AbfsClient should not " 
184+             + "fail with expect-100 error. The retried operation does not have" 
185+             + "expect-100 header." ).isFalse ();
183186    Mockito .verify (httpOpForAppendTest [1 ], Mockito .times (1 ))
184187        .processConnHeadersAndInputStreams (Mockito .any (byte [].class ),
185188            Mockito .anyInt (), Mockito .anyInt ());
186189  }
187190
188-   private  void  readyMocksForAppendTest (final  AbfsHttpOperation [] httpOpForAppendTest ,
191+   private  void  mockSetupForAppend (final  AbfsHttpOperation [] httpOpForAppendTest ,
189192      final  AbfsClient  spiedClient ) {
190193    int [] index  = new  int [1 ];
191194    index [0 ] = 0 ;
0 commit comments