diff --git a/.bazelci/presubmit.yml b/.bazelci/presubmit.yml index ab6d36b24..bfc967168 100644 --- a/.bazelci/presubmit.yml +++ b/.bazelci/presubmit.yml @@ -3,12 +3,12 @@ validate_config: 1 tasks: ubuntu1804: environment: - GO_HOME: "$HOME/go-1.19.5" + GO_HOME: "$HOME/go-1.20.7" PATH: "$PATH:$GO_HOME/bin" shell_commands: - - "echo --- Downloading and extracting Go 1.19.5 to $GO_HOME" + - "echo --- Downloading and extracting Go 1.20.7 to $GO_HOME" - "mkdir $GO_HOME" - - "curl https://mirror.bazel.build/golang.org/dl/go1.19.5.linux-amd64.tar.gz | tar xvz --strip-components=1 -C $GO_HOME" + - "curl https://mirror.bazel.build/go.dev/dl/go1.20.7.linux-amd64.tar.gz | tar xvz --strip-components=1 -C $GO_HOME" - "echo +++ Check go format" - "./check-gofmt.sh `find go -name '*.go'`" - "./check-golint.sh" @@ -23,12 +23,12 @@ tasks: platform: ubuntu1804 name: "go build / test" environment: - GO_HOME: "$HOME/go-1.19.5" + GO_HOME: "$HOME/go-1.20.7" PATH: "$PATH:$GO_HOME/bin" shell_commands: - - "echo --- Downloading and extracting Go 1.19.5 to $GO_HOME" + - "echo --- Downloading and extracting Go 1.20.7 to $GO_HOME" - "mkdir $GO_HOME" - - "curl https://mirror.bazel.build/golang.org/dl/go1.19.5.linux-amd64.tar.gz | tar xvz --strip-components=1 -C $GO_HOME" + - "curl https://mirror.bazel.build/go.dev/dl/go1.20.7.linux-amd64.tar.gz | tar xvz --strip-components=1 -C $GO_HOME" - "echo +++ Running go build" - "go build ./..." - "echo +++ Running go test" diff --git a/WORKSPACE b/WORKSPACE index 270f2e5c5..6cfa19ab9 100644 --- a/WORKSPACE +++ b/WORKSPACE @@ -25,7 +25,7 @@ load("@io_bazel_rules_go//go:deps.bzl", "go_register_toolchains", "go_rules_depe go_rules_dependencies() -go_register_toolchains(version = "1.19.8") +go_register_toolchains(version = "1.20.7") # Need "build_file_proto_mode" argument. go_repository( diff --git a/go.mod b/go.mod index 77cbb6e36..9a5b749a5 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module github.com/bazelbuild/remote-apis-sdks -go 1.19 +go 1.20 require ( github.com/bazelbuild/remote-apis v0.0.0-20230411132548-35aee1c4a425 diff --git a/go/pkg/reader/reader_test.go b/go/pkg/reader/reader_test.go index 2bf54824b..2bb1a2d5f 100644 --- a/go/pkg/reader/reader_test.go +++ b/go/pkg/reader/reader_test.go @@ -39,6 +39,7 @@ func TestFileReaderSeeks(t *testing.T) { } for _, tc := range tests { + tc := tc t.Run(tc.name, func(t *testing.T) { t.Parallel() path, err := testutil.CreateFile(t, false, tc.blob)