From ae3ca24b92a8097f8742f428fe4bcae9a4f7ee78 Mon Sep 17 00:00:00 2001 From: lubtd Date: Wed, 2 Aug 2023 13:11:32 +0200 Subject: [PATCH 1/2] update Makefile --- Makefile | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index 09738fd648..19a4c942e2 100644 --- a/Makefile +++ b/Makefile @@ -26,7 +26,7 @@ TEST_DIR?="./..." TEST_BUILD_FLAGS := -tags TESTNET,pebbledb,ledger PRIV_BUILD_FLAGS := -tags PRIVNET,pebbledb,ledger -clean: clean-binaries clean-dir clean-test-dir +clean: clean-binaries clean-dir clean-test-dir clean-coverage clean-binaries: @rm -rf ${GOBIN}/zetacored @@ -39,13 +39,18 @@ clean-dir: all: install test-coverage-exclude-core: - @go test {TEST_BUILD_FLAGS} -v -coverprofile coverage.out $(go list ./... | grep -v /x/zetacore/) + @go test ${TEST_BUILD_FLAGS} -v -coverprofile coverage.out $(go list ./... | grep -v /x/zetacore/) test-coverage: - @go test ${TEST_BUILD_FLAGS} -v -coverprofile coverage.out ${TEST_DIR} + -@go test ${TEST_BUILD_FLAGS} -v -coverprofile coverage.out ${TEST_DIR} coverage-report: test-coverage - @go tool cover -html=cover.txt + @go tool cover -html=coverage.out -o coverage.html + +clean-coverage: + @rm -f coverage.out + @rm -f coverage.html + clean-test-dir: @rm -rf x/crosschain/client/integrationtests/.zetacored @rm -rf x/crosschain/client/querytests/.zetacored From 5e9ab15b3b899717bfcf833ca1eecff381491fc3 Mon Sep 17 00:00:00 2001 From: lubtd Date: Wed, 2 Aug 2023 13:11:47 +0200 Subject: [PATCH 2/2] add coverage html to gitignire --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index 9dba8ee04e..d53a2695bd 100644 --- a/.gitignore +++ b/.gitignore @@ -10,6 +10,7 @@ coverage coverage.json coverage.out +coverage.html node_modules release/ typechain