summaryrefslogtreecommitdiff
path: root/t/Makefile
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2010-11-17 15:00:46 -0800
committerJunio C Hamano <gitster@pobox.com>2010-11-17 15:00:46 -0800
commit4739c19d7f905b326375083e60866e8977251ba3 (patch)
treed7666d7f98bc924a1de9fec7be335f9516383eb1 /t/Makefile
parentf5b868f81d2176120040b4c7ca223753f2dd5c1d (diff)
parent28d836c81586e6b49131c69bbc5228a41667f1da (diff)
downloadgit-4739c19d7f905b326375083e60866e8977251ba3.tar.gz
Merge branch 'mg/make-prove'
* mg/make-prove: test: allow running the tests under "prove"
Diffstat (limited to 't/Makefile')
-rw-r--r--t/Makefile10
1 files changed, 9 insertions, 1 deletions
diff --git a/t/Makefile b/t/Makefile
index 7aa409ab64..73c6ec473d 100644
--- a/t/Makefile
+++ b/t/Makefile
@@ -11,6 +11,8 @@ SHELL_PATH ?= $(SHELL)
PERL_PATH ?= /usr/bin/perl
TAR ?= $(TAR)
RM ?= rm -f
+PROVE ?= prove
+DEFAULT_TEST_TARGET ?= test
# Shell quote;
SHELL_PATH_SQ = $(subst ','\'',$(SHELL_PATH))
@@ -19,9 +21,15 @@ T = $(wildcard t[0-9][0-9][0-9][0-9]-*.sh)
TSVN = $(wildcard t91[0-9][0-9]-*.sh)
TGITWEB = $(wildcard t95[0-9][0-9]-*.sh)
-all: pre-clean
+all: $(DEFAULT_TEST_TARGET)
+
+test: pre-clean
$(MAKE) aggregate-results-and-cleanup
+prove: pre-clean
+ @echo "*** prove ***"; GIT_CONFIG=.git/config $(PROVE) --exec '$(SHELL_PATH_SQ)' $(GIT_PROVE_OPTS) $(T) :: $(GIT_TEST_OPTS)
+ $(MAKE) clean
+
$(T):
@echo "*** $@ ***"; GIT_CONFIG=.git/config '$(SHELL_PATH_SQ)' $@ $(GIT_TEST_OPTS)