diff --git a/config/http_config_test.go b/config/http_config_test.go index 060598b7..c737994b 100644 --- a/config/http_config_test.go +++ b/config/http_config_test.go @@ -693,7 +693,8 @@ func TestMissingBearerAuthFile(t *testing.T) { _, err = client.Get(testServer.URL) require.Errorf(t, err, "No error is returned here") - require.ErrorContainsf(t, err, "unable to read authorization credentials: unable to read file missing/bearer.token: open missing/bearer.token: no such file or directory", "wrong error message being returned") + require.ErrorContainsf(t, err, "unable to read authorization credentials: unable to read file missing/bearer.token", "wrong error message being returned") + require.ErrorIs(t, err, os.ErrNotExist) } func TestBearerAuthRoundTripper(t *testing.T) {