From 3df0821aa3de806755b5e3448fe6b8b04455d428 Mon Sep 17 00:00:00 2001 From: "Johan T. Halseth" Date: Fri, 24 May 2019 14:17:48 +0200 Subject: [PATCH] make: add backend tag for itests Defaults to running itests with btcd. --- Makefile | 4 ++-- make/testing_flags.mk | 8 ++++++++ 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 79b7e04f..bf099bda 100644 --- a/Makefile +++ b/Makefile @@ -115,7 +115,7 @@ scratch: build check: unit itest itest-only: - @$(call print, "Running integration tests.") + @$(call print, "Running integration tests with ${backend} backend.") $(ITEST) itest: btcd build-itest itest-only @@ -148,7 +148,7 @@ travis-itest: lint itest # ============= flakehunter: build-itest - @$(call print, "Flake hunting integration tests.") + @$(call print, "Flake hunting ${backend} integration tests.") while [ $$? -eq 0 ]; do $(ITEST); done flake-unit: diff --git a/make/testing_flags.mk b/make/testing_flags.mk index eb5b43b1..49b906ed 100644 --- a/make/testing_flags.mk +++ b/make/testing_flags.mk @@ -55,4 +55,12 @@ endif # Construct the integration test command with the added build flags. ITEST_TAGS := $(DEV_TAGS) rpctest chainrpc walletrpc signrpc invoicesrpc autopilotrpc routerrpc + +# Default to btcd backend if not set. +ifneq ($(backend),) +ITEST_TAGS += ${backend} +else +ITEST_TAGS += btcd +endif + ITEST := rm output*.log; date; $(GOTEST) -tags="$(ITEST_TAGS)" $(TEST_FLAGS) -logoutput