all: move from io/ioutil to io and os packages (#353)

The io/ioutil package has been deprecated as of Go 1.16, see
https://golang.org/doc/go1.16#ioutil. This commit replaces the existing
io/ioutil functions with their new definitions in io and os packages.

Signed-off-by: Eng Zer Jun <engzerjun@gmail.com>
This commit is contained in:
Eng Zer Jun
2021-12-18 12:06:22 -05:00
committed by GitHub
parent 08f52cc125
commit 7665b87dc2
4 changed files with 10 additions and 13 deletions
+1 -2
View File
@@ -10,7 +10,6 @@ import (
"encoding/pem"
"fmt"
"io"
"io/ioutil"
"log"
"strings"
"testing"
@@ -121,7 +120,7 @@ func testArmor(t *testing.T, size int) {
}
r := armor.NewReader(buf)
out, err := ioutil.ReadAll(r)
out, err := io.ReadAll(r)
if err != nil {
t.Fatal(err)
}