diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index 66f4bb5f..427ff389 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -68,6 +68,23 @@ jobs: - name: Run make verify-fmt run: | make verify-fmt + verify-fmt: + name: Verify tidy + runs-on: ubuntu-latest + steps: + - name: Set up Go 1.20.x + uses: actions/setup-go@v4 + with: + go-version: 1.20.x + id: go + - name: Check out code + uses: actions/checkout@v3 + - name: Run go mod tidy + run: | + go mod tidy + - name: Run make verify-fmt + run: | + make verify-tidy lint: name: Lint runs-on: ubuntu-latest diff --git a/make/verify.mk b/make/verify.mk index 25d11a5b..b480a047 100644 --- a/make/verify.mk +++ b/make/verify.mk @@ -16,3 +16,7 @@ verify-bundle: bundle ## Verify bundle update. .PHONY: verify-fmt verify-fmt: fmt ## Verify fmt update. git diff --exit-code ./api ./controllers + +.PHONY: verify-fmt +verify-tidy: fmt ## Verify fmt update. + git diff --exit-code -- go.mod go.sum