@@ -497,19 +497,19 @@ func TestClient_Do_fails(t *testing.T) {
497497 url : ts .URL ,
498498 name : "default_retry_policy" ,
499499 cr : DefaultRetryPolicy ,
500- err : "giving up after 3 attempt(s)" ,
500+ err : "giving up after 3 attempt(s) [last statusCode: 500] " ,
501501 },
502502 {
503503 url : serverUrlWithBasicAuth .String (),
504504 name : "default_retry_policy_url_with_basic_auth" ,
505505 cr : DefaultRetryPolicy ,
506- err : redactURL (serverUrlWithBasicAuth ) + " giving up after 3 attempt(s)" ,
506+ err : redactURL (serverUrlWithBasicAuth ) + " giving up after 3 attempt(s) [last statusCode: 500] " ,
507507 },
508508 {
509509 url : ts .URL ,
510510 name : "error_propagated_retry_policy" ,
511511 cr : ErrorPropagatedRetryPolicy ,
512- err : "giving up after 3 attempt(s): unexpected HTTP status 500 Internal Server Error" ,
512+ err : "giving up after 3 attempt(s) [last statusCode: 500] : unexpected HTTP status 500 Internal Server Error" ,
513513 },
514514 }
515515
@@ -787,7 +787,7 @@ func TestClient_CheckRetry(t *testing.T) {
787787 t .Fatalf ("CheckRetry called %d times, expected 1" , called )
788788 }
789789
790- if err .Error () != fmt .Sprintf ("GET %s giving up after 2 attempt(s): retryError" , ts .URL ) {
790+ if err .Error () != fmt .Sprintf ("GET %s giving up after 2 attempt(s) [last statusCode: 500] : retryError" , ts .URL ) {
791791 t .Fatalf ("Expected retryError, got:%v" , err )
792792 }
793793}
0 commit comments