From 6278bb5e8a01ddf4a9e6dd2d1f2f8b6400d55e9e Mon Sep 17 00:00:00 2001 From: Anuj Khandelwal Date: Thu, 24 Oct 2024 15:22:30 +0530 Subject: [PATCH 1/2] chore: fix files to consider for test coverage --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index dd341af11..3b53a4eb7 100644 --- a/Makefile +++ b/Makefile @@ -30,7 +30,7 @@ lint-fix: golangci-lint run --fix test: ## Run tests - @go test -race $(shell go list ./... | grep -v /ui | grep -v /vendor/ | grep -v /test/) -coverprofile=coverage.out -count 2 -timeout 150s + @go test -race $(shell go list ./... | grep -v /ui | grep -v /vendor/ | grep -v /test/ | grep -v mocks | grep -v postgres/migrations) -coverprofile=coverage.out -count 2 -timeout 150s test-all: lint test e2e-test ## Run all tests From 2fc0fc846de2c2e421ab5e48a014f08887e148d7 Mon Sep 17 00:00:00 2001 From: Anuj Khandelwal Date: Thu, 24 Oct 2024 16:05:49 +0530 Subject: [PATCH 2/2] chore: do not include mocks folder in test coverage --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 3b53a4eb7..6468924aa 100644 --- a/Makefile +++ b/Makefile @@ -30,7 +30,7 @@ lint-fix: golangci-lint run --fix test: ## Run tests - @go test -race $(shell go list ./... | grep -v /ui | grep -v /vendor/ | grep -v /test/ | grep -v mocks | grep -v postgres/migrations) -coverprofile=coverage.out -count 2 -timeout 150s + @go test -race $(shell go list ./... | grep -v /ui | grep -v /vendor/ | grep -v /test/ | grep -v /mocks | grep -v postgres/migrations) -coverprofile=coverage.out -count 2 -timeout 150s test-all: lint test e2e-test ## Run all tests