Skip to content

Commit 196f870

Browse files
committed
fix: fix static check failures
1 parent 04bafe2 commit 196f870

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

collector/aliyun/aliyun_collector_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ func TestNewCollector(t *testing.T) {
9595
rr2.WriteHeader(http.StatusOK)
9696
htmlData, err := os.ReadFile("./testdata/golang_dl.html")
9797
assert.Nil(t, err)
98-
rr2.Write(htmlData)
98+
_, _ = rr2.Write(htmlData)
9999

100100
patches := gomonkey.ApplyMethodSeq(&http.Client{}, "Get", []gomonkey.OutputCell{
101101
{Values: gomonkey.Params{nil, errors.New("unknown error")}},

collector/official/official_collector_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,7 @@ func TestNewCollector(t *testing.T) {
273273
rr2.WriteHeader(http.StatusOK)
274274
htmlData, err := os.ReadFile("./testdata/golang_dl_with_rc.html")
275275
assert.Nil(t, err)
276-
rr2.Write(htmlData)
276+
_, _ = rr2.Write(htmlData)
277277

278278
patches := gomonkey.ApplyMethodSeq(&http.Client{}, "Get", []gomonkey.OutputCell{
279279
{Values: gomonkey.Params{nil, errors.New("unknown error")}},

0 commit comments

Comments
 (0)