From 721dd1b6424b832a8a71f9bcfa32fa4b2489a894 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Manuel=20R=C3=BCger?= Date: Thu, 5 Jan 2023 11:25:14 +0100 Subject: [PATCH] Makefile: Add test target --- .gitignore | 1 + Makefile | 3 +++ 2 files changed, 4 insertions(+) diff --git a/.gitignore b/.gitignore index bc9f460..edd1254 100644 --- a/.gitignore +++ b/.gitignore @@ -3,3 +3,4 @@ /testdata .idea/ /mark.test +/profile.cov diff --git a/Makefile b/Makefile index 9ede00b..9f1df9b 100644 --- a/Makefile +++ b/Makefile @@ -18,6 +18,9 @@ build: -ldflags "-X main.version=$(VERSION)" \ -gcflags "-trimpath $(GOPATH)/src" +test: + go test -race -coverprofile=profile.cov ./... + image: @echo :: building image $(NAME):$(VERSION) @docker build -t $(NAME):$(VERSION) -f Dockerfile .