mirror of
https://github.com/ceph/ceph-csi.git
synced 2024-12-18 11:00:25 +00:00
tests: fail when "make mod-check" detects a modified go.mod file
`go mod verify` does not fail when all moduled under vendor/ are updated. However it does update `go.mod` in case it does not reflect the downloaded versions. By adding this additional verification in `make mod-check`, future updates to vendor/ will require a correct go.mod as well. Signed-off-by: Niels de Vos <ndevos@redhat.com>
This commit is contained in:
parent
b3664cd631
commit
22c0baa4b0
3
Makefile
3
Makefile
@ -52,7 +52,8 @@ go-test:
|
|||||||
./scripts/test-go.sh
|
./scripts/test-go.sh
|
||||||
|
|
||||||
mod-check:
|
mod-check:
|
||||||
go mod verify
|
@echo 'running: go mod verify'
|
||||||
|
@go mod verify && [ "$(shell sha512sum go.mod)" = "`sha512sum go.mod`" ] || ( echo "ERROR: go.mod was modified by 'go mod verify'" && false )
|
||||||
|
|
||||||
go-lint:
|
go-lint:
|
||||||
./scripts/lint-go.sh
|
./scripts/lint-go.sh
|
||||||
|
Loading…
Reference in New Issue
Block a user