mirror of
https://github.com/anchore/syft.git
synced 2026-11-02 07:26:34 +01:00
add apk/alpine support (#98)
This commit is contained in:
@@ -114,7 +114,7 @@ check-licenses:
|
||||
.PHONY: unit
|
||||
unit: ## Run unit tests (with coverage)
|
||||
$(call title,Running unit tests)
|
||||
go test --race -coverprofile $(COVER_REPORT) ./...
|
||||
go test -coverprofile $(COVER_REPORT) ./...
|
||||
@go tool cover -func $(COVER_REPORT) | grep total | awk '{print substr($$3, 1, length($$3)-1)}' > $(COVER_TOTAL)
|
||||
@echo "Coverage: $$(cat $(COVER_TOTAL))"
|
||||
@if [ $$(echo "$$(cat $(COVER_TOTAL)) >= $(COVERAGE_THRESHOLD)" | bc -l) -ne 1 ]; then echo "$(RED)$(BOLD)Failed coverage quality gate (> $(COVERAGE_THRESHOLD)%)$(RESET)" && false; fi
|
||||
|
||||
Reference in New Issue
Block a user