diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index 3f8094c..15b0e8f 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -7,14 +7,18 @@ on: jobs: build: - name: Build runs-on: ubuntu-latest + strategy: + matrix: + go: ['1.15', '1.16', '1.17', '1.18', '1.19', '1.20'] + name: Go ${{ matrix.go }} sample + steps: - - name: Set up Go 1.14 + - name: Set up Go 1.13 uses: actions/setup-go@v1 with: - go-version: 1.14 + go-version: ${{ matrix.go }} id: go - name: Check out code into the Go module directory diff --git a/hcutil/hcutil_test.go b/hcutil/hcutil_test.go index 86613e6..d08fd18 100644 --- a/hcutil/hcutil_test.go +++ b/hcutil/hcutil_test.go @@ -3,7 +3,6 @@ package hcutil import ( "context" "errors" - "io" "io/ioutil" "net" "net/http" @@ -84,7 +83,7 @@ func TestProxy(t *testing.T) { resp, err := c.Do(req) assert.NoError(t, err) - res, err := io.ReadAll(resp.Body) + res, err := ioutil.ReadAll(resp.Body) assert.NoError(t, err) s = string(res) @@ -129,7 +128,7 @@ func TestUnixSocket(t *testing.T) { resp, err := c.Do(req) assert.NoError(t, err) - all, err := io.ReadAll(resp.Body) + all, err := ioutil.ReadAll(resp.Body) assert.NoError(t, err) s = string(all)