summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile7
1 files changed, 6 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index e6d24fa..3699644 100644
--- a/Makefile
+++ b/Makefile
@@ -1,6 +1,9 @@
## SPDX-FileCopyrightText: 2025 M. Shulhan <ms@kilabit.info>
## SPDX-License-Identifier: GPL-3.0-only
+COVER_OUT:=cover.out
+COVER_HTML:=cover.html
+
.PHONY: all
all: lint test
@@ -11,4 +14,6 @@ lint:
.PHONY: test
test:
- go test ./...
+ CGO_ENABLED=1 go test -failfast -timeout=1m -race \
+ -coverprofile=$(COVER_OUT) ./...
+ go tool cover -html=$(COVER_OUT) -o $(COVER_HTML)