[PATCH] makefile: add ability to run specific test files

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Running a specific test file manually does not obtain the exact
environment setup by the Makefile. Add ability to run any of the tests
in the t/ directory so that a user can more quickly debug a failing
test. Otherwise, the entire test suite needs to be run, which can take a
vary long time.

Signed-off-by: Jacob Keller <jacob.e.keller@xxxxxxxxx>
---
 Makefile | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/Makefile b/Makefile
index 07ea1058379a..86bdc4ed1ee9 100644
--- a/Makefile
+++ b/Makefile
@@ -2262,13 +2262,18 @@ export TEST_NO_MALLOC_CHECK
 
 ### Testing rules
 
+T = $(sort $(wildcard t/t[0-9][0-9][0-9][0-9]-*.sh))
+
+$(T):
+	$(MAKE) -C t $(notdir $@)
+
 test: all
 	$(MAKE) -C t/ all
 
 perf: all
 	$(MAKE) -C t/perf/ all
 
-.PHONY: test perf
+.PHONY: test perf $(T)
 
 test-ctype$X: ctype.o
 
-- 
2.0.1.475.g9b8d714

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]