From 20047484fdaabc2aadfc103a574450a397cedff7 Mon Sep 17 00:00:00 2001 From: Stephen Finucane Date: Wed, 24 Sep 2025 16:29:58 +0100 Subject: [PATCH 1/2] Split lint, unit test jobs There's no reason we need to constrain our version of Go for linters: It is only necessary for unit tests. Make this possible by splitting our workflows. Signed-off-by: Stephen Finucane --- .github/workflows/{unit.yml => lint.yaml} | 11 ++--------- .github/workflows/unit.yaml | 17 +++++++++++++++++ 2 files changed, 19 insertions(+), 9 deletions(-) rename .github/workflows/{unit.yml => lint.yaml} (59%) create mode 100644 .github/workflows/unit.yaml diff --git a/.github/workflows/unit.yml b/.github/workflows/lint.yaml similarity index 59% rename from .github/workflows/unit.yml rename to .github/workflows/lint.yaml index fb7fd8d..68c9755 100644 --- a/.github/workflows/unit.yml +++ b/.github/workflows/lint.yaml @@ -5,23 +5,16 @@ jobs: runs-on: ubuntu-latest strategy: fail-fast: false - matrix: - go-version: - - "1.22" steps: - name: Checkout source uses: actions/checkout@v5 - - name: Setup Go ${{ matrix.go-version }} + - name: Setup Go uses: actions/setup-go@v5 with: - go-version: ${{ matrix.go-version }} + go-version: "1" - name: Run linters run: | make lint - - - name: Run unit tests - run: | - make unit diff --git a/.github/workflows/unit.yaml b/.github/workflows/unit.yaml new file mode 100644 index 0000000..90f061a --- /dev/null +++ b/.github/workflows/unit.yaml @@ -0,0 +1,17 @@ +name: Unit Testing +on: [push, pull_request] +jobs: + test: + runs-on: ubuntu-latest + steps: + - name: Checkout source + uses: actions/checkout@v5 + + - name: Setup Go + uses: actions/setup-go@v5 + with: + go-version-file: 'go.mod' + + - name: Run unit tests + run: | + make unit From 390670e0333004b9f291540098886fefa4b2c0a6 Mon Sep 17 00:00:00 2001 From: Stephen Finucane Date: Wed, 24 Sep 2025 16:31:02 +0100 Subject: [PATCH 2/2] Bump golangci-lint, gotestsum Signed-off-by: Stephen Finucane --- Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index de944b9..95d435d 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,7 @@ undefine GOFLAGS -GOLANGCI_LINT_VERSION?=v2.1.6 -GOTESTSUM_VERSION?=v1.12.2 +GOLANGCI_LINT_VERSION?=v2.5.0 +GOTESTSUM_VERSION?=v1.13.0 GO_TEST?=go run gotest.tools/gotestsum@$(GOTESTSUM_VERSION) --format testname -- TIMEOUT := "60m"