1
0
Fork 0
forked from forgejo/forgejo

Remove deprecated packages & staticcheck fixes (#22012)

`ioutil` is deprecated and should use `io` instead
This commit is contained in:
Chongyi Zheng 2022-12-02 17:06:23 -05:00 committed by GitHub
parent 21bcb92926
commit 8698458f48
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 15 additions and 16 deletions

View file

@ -5,7 +5,7 @@ package integration
import (
"fmt"
"io/ioutil"
"io"
"net/http"
"testing"
@ -41,7 +41,7 @@ func TestAPIViewPulls(t *testing.T) {
pull := pulls[0]
if assert.EqualValues(t, 5, pull.ID) {
resp = ctx.Session.MakeRequest(t, NewRequest(t, "GET", pull.DiffURL), http.StatusOK)
_, err := ioutil.ReadAll(resp.Body)
_, err := io.ReadAll(resp.Body)
assert.NoError(t, err)
// TODO: use diff to generate stats to test against