Skip to content
This repository was archived by the owner on Mar 11, 2025. It is now read-only.

Commit f5c5bdb

Browse files
committed
Fix error formatting
1 parent 8f9845f commit f5c5bdb

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

s3creds/access_service_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ func TestGetAccess(t *testing.T) {
1616

1717
muxCreds.HandleFunc("/core/credentials/Access", func(w http.ResponseWriter, r *http.Request) {
1818
if k := r.Header.Get("X-Product-Key"); k != productKey {
19-
t.Errorf(ErrMissingProductKey.Error())
19+
t.Error(ErrMissingProductKey.Error())
2020
w.WriteHeader(http.StatusForbidden)
2121
return
2222
}

s3creds/policy_service_test.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ func TestCreatePolicy(t *testing.T) {
3939

4040
muxCreds.HandleFunc("/core/credentials/Policy", func(w http.ResponseWriter, r *http.Request) {
4141
if k := r.Header.Get("X-Product-Key"); k != productKey {
42-
t.Errorf(ErrMissingProductKey.Error())
42+
t.Error(ErrMissingProductKey.Error())
4343
w.WriteHeader(http.StatusForbidden)
4444
return
4545
}
@@ -90,7 +90,7 @@ func TestDeletePolicy(t *testing.T) {
9090

9191
muxCreds.HandleFunc("/core/credentials/Policy/"+id, func(w http.ResponseWriter, r *http.Request) {
9292
if k := r.Header.Get("X-Product-Key"); k != productKey {
93-
t.Errorf(ErrMissingProductKey.Error())
93+
t.Error(ErrMissingProductKey.Error())
9494
w.WriteHeader(http.StatusForbidden)
9595
return
9696
}
@@ -117,7 +117,7 @@ func TestGetPolicy(t *testing.T) {
117117
id := "1"
118118
muxCreds.HandleFunc("/core/credentials/Policy", func(w http.ResponseWriter, r *http.Request) {
119119
if k := r.Header.Get("X-Product-Key"); k != productKey {
120-
t.Errorf(ErrMissingProductKey.Error())
120+
t.Error(ErrMissingProductKey.Error())
121121
w.WriteHeader(http.StatusForbidden)
122122
return
123123
}

0 commit comments

Comments
 (0)