From 110356857d149d662ce060d0f70f889b4d1ceb66 Mon Sep 17 00:00:00 2001 From: Anna Shaleva Date: Fri, 31 Mar 2023 10:03:19 +0300 Subject: [PATCH] *: drop go 1.17 support for github actions and tests And support go 1.20 for github workflows. --- .github/workflows/build.yml | 4 ++-- .github/workflows/run_tests.yml | 16 ++++++++-------- README.md | 2 +- cli/vm/cli_test.go | 4 ++-- 4 files changed, 13 insertions(+), 13 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 90e46f211..284c9f3b9 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -55,7 +55,7 @@ jobs: - name: Set up Go uses: actions/setup-go@v3 with: - go-version: 1.19 + go-version: '1.20' cache: true - name: Update Go modules @@ -135,7 +135,7 @@ jobs: - name: Set up Go uses: actions/setup-go@v3 with: - go-version: 1.19 + go-version: '1.20' cache: true - name: Login to DockerHub diff --git a/.github/workflows/run_tests.yml b/.github/workflows/run_tests.yml index 1eb45a742..f4579e1c7 100644 --- a/.github/workflows/run_tests.yml +++ b/.github/workflows/run_tests.yml @@ -20,7 +20,7 @@ jobs: steps: - uses: actions/setup-go@v3 with: - go-version: 1.19 + go-version: '1.20' - uses: actions/checkout@v3 - name: golangci-lint uses: golangci/golangci-lint-action@v3 @@ -103,7 +103,7 @@ jobs: - name: Set up Go uses: actions/setup-go@v3 with: - go-version: 1.19 + go-version: '1.20' cache: true - name: Update Go modules @@ -125,20 +125,20 @@ jobs: strategy: matrix: os: [ubuntu-20.04, windows-2022, macos-12] - go_versions: [ '1.17', '1.18', '1.19' ] + go_versions: [ '1.18', '1.19', '1.20' ] exclude: # Only latest Go version for Windows and MacOS. - os: windows-2022 - go_versions: '1.17' + go_versions: '1.18' - os: windows-2022 - go_versions: '1.18' - - os: macos-12 - go_versions: '1.17' + go_versions: '1.19' - os: macos-12 go_versions: '1.18' + - os: macos-12 + go_versions: '1.19' # Exclude latest Go version for Ubuntu as Coverage uses it. - os: ubuntu-20.04 - go_versions: '1.19' + go_versions: '1.20' fail-fast: false steps: - uses: actions/checkout@v3 diff --git a/README.md b/README.md index bef2d78a2..0fbd656ad 100644 --- a/README.md +++ b/README.md @@ -51,7 +51,7 @@ NeoGo, `:latest` points to the latest release) or build yourself. ### Building -Building NeoGo requires Go 1.17+ and `make`: +Building NeoGo requires Go 1.18+ and `make`: ``` make diff --git a/cli/vm/cli_test.go b/cli/vm/cli_test.go index 2b6e7db45..bd95b0df7 100644 --- a/cli/vm/cli_test.go +++ b/cli/vm/cli_test.go @@ -376,7 +376,7 @@ func TestLoad(t *testing.T) { require.NoError(t, os.WriteFile(filenameErr, []byte(src+"invalid_token"), os.ModePerm)) filenameErr = "'" + filenameErr + "'" goMod := []byte(`module test.example/vmcli -go 1.17`) +go 1.18`) require.NoError(t, os.WriteFile(filepath.Join(tmpDir, "go.mod"), goMod, os.ModePerm)) e := newTestVMCLI(t) @@ -407,7 +407,7 @@ require ( github.com/nspcc-dev/neo-go/pkg/interop v0.0.0 ) replace github.com/nspcc-dev/neo-go/pkg/interop => ` + filepath.Join(wd, "../../pkg/interop") + ` -go 1.17`) +go 1.18`) require.NoError(t, os.WriteFile(filepath.Join(tmpDir, "go.mod"), goMod, os.ModePerm)) return filename }