From 0114a4df1fd7970ca83b164c1fb05ac9d2542a7e Mon Sep 17 00:00:00 2001 From: Max Revitt Date: Wed, 7 Sep 2022 12:38:45 +0100 Subject: [PATCH] feat(hive): add makefile command to run hive locally (#5305) --- Makefile | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index a092970e1b4..cfa1b974505 100644 --- a/Makefile +++ b/Makefile @@ -267,10 +267,16 @@ user_macos: sudo -u $(ERIGON_USER) mkdir -p $(ERIGON_USER_XDG_DATA_HOME) ## coverage: run code coverage report and output total coverage % +.PHONY: coverage coverage: @go test -coverprofile=coverage.out ./... > /dev/null 2>&1 && go tool cover -func coverage.out | grep total | awk '{print substr($$3, 1, length($$3)-1)}' +## hive: run hive test suite locally using docker e.g. OUTPUT_DIR=~/results/hive SIM=ethereum/engine make hive +.PHONY: hive +hive: + DOCKER_TAG=thorax/erigon:ci-local make docker + docker run --rm -v /var/run/docker.sock:/var/run/docker.sock -v $(OUTPUT_DIR):/work thorax/hive:latest --sim $(SIM) --results-root=/work/results --client erigon_ci-local # run erigon + ## help: print commands help help : Makefile @sed -n 's/^##//p' $< -