diff options
author | Eelco Dolstra <edolstra@gmail.com> | 2020-05-08 11:49:40 +0200 |
---|---|---|
committer | Eelco Dolstra <edolstra@gmail.com> | 2020-05-08 11:49:40 +0200 |
commit | 7898cdb75a721cc21867ccdbcc523e95f2db0354 (patch) | |
tree | 28165f267735bb6bf0dc3075482cd23b4657bb60 /mk | |
parent | 72b9d971bc4ff5b5dcb9349d03526a5ef3e4300e (diff) |
make check: Run unit tests
Diffstat (limited to 'mk')
-rw-r--r-- | mk/programs.mk | 6 | ||||
-rw-r--r-- | mk/tracing.mk | 1 |
2 files changed, 7 insertions, 0 deletions
diff --git a/mk/programs.mk b/mk/programs.mk index d93df4468..2d0c988d4 100644 --- a/mk/programs.mk +++ b/mk/programs.mk @@ -76,4 +76,10 @@ define build-program programs-list += $$($(1)_PATH) clean-files += $$($(1)_PATH) $$(_d)/*.o $$(_d)/.*.dep $$($(1)_DEPS) $$($(1)_OBJS) dist-files += $$(_srcs) + + # Phony target to run this program (typically as a dependency of 'check'). + .PHONY: $(1)_RUN + $(1)_RUN: $$($(1)_PATH) + $(trace-test) $$($(1)_PATH) + endef diff --git a/mk/tracing.mk b/mk/tracing.mk index 13912d3c7..54c77ab60 100644 --- a/mk/tracing.mk +++ b/mk/tracing.mk @@ -11,6 +11,7 @@ ifeq ($(V), 0) trace-javac = @echo " JAVAC " $@; trace-jar = @echo " JAR " $@; trace-mkdir = @echo " MKDIR " $@; + trace-test = @echo " TEST " $@; suppress = @ |