summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorFred Sundvik <fsundvik@gmail.com>2016-08-27 13:29:54 +0300
committerFred Sundvik <fsundvik@gmail.com>2016-08-27 21:57:49 +0300
commitfc855cb30e86aadee7b1d9ee62f83d85cc0447ea (patch)
treec09180b775d723e9d8d63f39b7a5c6c1fa20ede8 /Makefile
parentf4429ba48ca8346a208b711cd63e7413ac3efeff (diff)
Fix running multiple tests
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile6
1 files changed, 4 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index 054aa31ec5..5f5c46860c 100644
--- a/Makefile
+++ b/Makefile
@@ -414,10 +414,12 @@ define BUILD_TEST
MAKE_VARS := TEST=$$(TEST_NAME)
MAKE_MSG := $$(MSG_MAKE_TEST)
$$(eval $$(call BUILD))
- TESTS += $$(TEST_DIR)/$$(TEST_NAME).elf
+ TEST_EXECUTABLE := $$(TEST_DIR)/$$(TEST_NAME).elf
+ TESTS += $$(TEST_EXECUTABLE)
endef
define PARSE_TEST
+ TESTS :=
TEST_NAME := $$(firstword $$(subst -, ,$$(RULE)))
TEST_TARGET := $$(subst $$(TEST_NAME),,$$(subst $$(TEST_NAME)-,,$$(RULE)))
MATCHED_TESTS := $$(foreach TEST,$$(TEST_LIST),$$(if $$(findstring $$(TEST_NAME),$$(TEST)),$$(TEST),))
@@ -470,7 +472,7 @@ $(SUBPROJECTS): %: %-allkm
+error_occured=0; \
$(foreach COMMAND,$(COMMANDS),$(RUN_COMMAND)) \
if [ $$error_occured -gt 0 ]; then printf "$(MSG_ERRORS)" & exit $$error_occured; fi;\
- $(foreach TEST,$(TESTS),$(TEST))
+ $(foreach TEST,$(TESTS),$(TEST);)
# All should compile everything
.PHONY: all