remove deprecated of package io/ioutil (#3395)

This commit is contained in:
Qt
2022-11-17 22:35:55 +08:00
committed by GitHub
parent 234a1d33f7
commit 6150c488e7
8 changed files with 27 additions and 31 deletions
+2 -2
View File
@@ -9,7 +9,7 @@ import (
"crypto/tls"
"fmt"
"html/template"
"io/ioutil"
"io"
"net"
"net/http"
"net/http/httptest"
@@ -43,7 +43,7 @@ func testRequest(t *testing.T, params ...string) {
assert.NoError(t, err)
defer resp.Body.Close()
body, ioerr := ioutil.ReadAll(resp.Body)
body, ioerr := io.ReadAll(resp.Body)
assert.NoError(t, ioerr)
var responseStatus = "200 OK"