[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 05/17] tests: use suffix, not exec-bit, to tell which files are t
From: |
Stefano Lattarini |
Subject: |
[PATCH 05/17] tests: use suffix, not exec-bit, to tell which files are tests |
Date: |
Sun, 2 Sep 2012 21:55:07 +0200 |
* tests/Makefile.am (vc_exe_in_TESTS): Adjust to look, in the 'tests/'
subdirectory, for files that have one of the extensions listed in
$(TEST_EXTENSIONS), rather than for executable files.
---
tests/Makefile.am | 16 +++++++++-------
1 file changed, 9 insertions(+), 7 deletions(-)
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 9e47f28..1b344f8 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -21,18 +21,20 @@
TESTS = $(all_tests)
root_tests = $(all_root_tests)
-# Ensure that all version-controlled executable files are listed
+# Ensure that all version-controlled filestable files are listed
# in $(all_tests).
vc_exe_in_TESTS:
$(AM_V_GEN)test -d $(top_srcdir)/.git || exit 1; \
- { \
+ bs="\\"; \
+ test_extensions_rx=`echo $(TEST_EXTENSIONS) \
+ | sed -e "s/ /|/g" -e "s/$$bs./$$bs$$bs./g"`; \
+ { \
for t in $(all_tests); do echo $$t; done; \
cd $(top_srcdir); \
- for f in `$(SHELL) build-aux/vc-list-files $(subdir) \
- | sed 's!^$(subdir)/!!'`; do \
- test -f "tests/$$f" && test -x "tests/$$f" && echo "$$f"; \
- done; \
- } | sort | uniq -u | grep . && exit 1; :
+ $(SHELL) build-aux/vc-list-files $(subdir) \
+ | sed 's!^$(subdir)/!!' | grep -v '^init\.sh$$' \
+ | $(EGREP) "$$test_extensions_rx\$$"; \
+ } | sort | uniq -u | grep . && exit 1; :
check-local: vc_exe_in_TESTS
.PHONY: vc_exe_in_TESTS
--
1.7.12
- [PATCH 00/17] De-recursion for the 'tests' subdirectory., Stefano Lattarini, 2012/09/02
- [PATCH 01/17] build: use 'check-local' to extend the 'check' target, Stefano Lattarini, 2012/09/02
- [PATCH 03/17] maint: remove useless dependency for vc_exe_in_TESTS, Stefano Lattarini, 2012/09/02
- [PATCH 02/17] maint: avoid parsing of Makefile.am from vc_exe_in_TESTS, Stefano Lattarini, 2012/09/02
- [PATCH 04/17] maint: make vc_exe_in_TESTS also work in VPATH builds, Stefano Lattarini, 2012/09/02
- [PATCH 05/17] tests: use suffix, not exec-bit, to tell which files are tests,
Stefano Lattarini <=
- [PATCH 06/17] tests: remove the unused 'root-hint' target, Stefano Lattarini, 2012/09/02
- [PATCH 08/17] maint: remove anachronistic syntax-check, Stefano Lattarini, 2012/09/02
- [PATCH 07/17] maint: remove duplicated declaration of the 'sc_check-AUTHORS' target, Stefano Lattarini, 2012/09/02
- [PATCH 09/17] maint: list of names of built programs available in the Makefiles, Stefano Lattarini, 2012/09/02
- [PATCH 11/17] tests: put test-suite.log back in 'tests/', Stefano Lattarini, 2012/09/02
- [PATCH 12/17] build: remove two now-useless convenience targets, Stefano Lattarini, 2012/09/02
- [PATCH 14/17] maint: avoid a spurious syntax-check error, Stefano Lattarini, 2012/09/02
- [PATCH 13/17] maint: vc_exe_in_TESTS should actually be a syntax check, Stefano Lattarini, 2012/09/02
- [PATCH 15/17] maint: fix syntax checks 'sc_root_tests', Stefano Lattarini, 2012/09/02
- [PATCH 17/17] maint: fix a spurious syntax-check failure, Stefano Lattarini, 2012/09/02