Run go mod tidy as part of GitHub actions

Make sure go.mod and go.sum match the current source in the module.

Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
This commit is contained in:
Tobias Klauser authored and Brad Fitzpatrick committed 2021-03-18 12:08:34 -07:00
1 parent 738f593fd1
commit 4259e17bb7
2 files changed
+6 -4

No files matched your search

+6
View File
@@ -29,5 +29,11 @@ jobs:
if: matrix.go-version == '1.16' && matrix.platform == 'ubuntu-latest'
run: diff -u <(echo -n) <(go fmt $(go list ./...))
- name: Check Go modules
if: matrix.go-version == '1.16'
run: |
go mod tidy
git diff --exit-code
- name: Run unit tests
run: go test -v ./...