# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
+# Run the tests with the shell detected at configure time.
+LOG_COMPILER = $(SHELL)
+
TEST_EXTENSIONS = .test .tap
+TEST_LOG_COMPILER = $(LOG_COMPILER)
+TAP_LOG_COMPILER = $(LOG_COMPILER)
+
TAP_LOG_DRIVER = AM_TAP_AWK='$(AWK)' $(SHELL) $(top_srcdir)/lib/tap-driver.sh
- TAP_LOG_DRIVER_FLAGS = --merge --comments
-AM_TAP_LOG_DRIVER_FLAGS = --merge
++
++AM_TAP_LOG_DRIVER_FLAGS = --merge --comments
+## Avoid spurious TAP diagnostic. We use an awful indirection with a
+## shell command substitution here, since the string needs to contain
+## `#' characters, and these can't be escaped portably in a make macro
+## definition.
+## FIXME: this is quite inefficient though, as it adds one extra fork
+## FIXME: per TAP test script; this is OK for the moment, since we have
+## FIXME: few such scripts, but might become an issue in the future.
+## Keep this in sync with the definition of $diag_string_ in tests/defs.
- TAP_LOG_DRIVER_FLAGS += --diagnostic-string `printf '\043%%\043\n'`
++AM_TAP_LOG_DRIVER_FLAGS += --diagnostic-string `printf '\043%%\043\n'`
MAINTAINERCLEANFILES =
EXTRA_DIST = ChangeLog-old
AM_TESTS_ENVIRONMENT = \
test x"$$me" = x || unset me; \
test x"$$required" = x || unset required; \
- test x"$$use_tap" = x || unset use_tap; \
+ test x"$$using_tap" = x || unset using_tap; \
test x"$$parallel_tests" = x || unset parallel_tests; \
+ test x"$$test_prefer_config_shell" || unset test_prefer_config_shell; \
test x"$$original_AUTOMAKE" = x || unset original_AUTOMAKE; \
test x"$$original_ACLOCAL" = x || unset original_ACLOCAL;
+# The `AM_TESTS_REEXEC=no' setting tells the tests not to needlessly
+# re-execute themselves with the shell detected at configure time, since
+# we are already running them under it explicitly in our setup (see e.g.
+# the definition of TEST_LOG_COMPILER above).
+AM_TESTS_ENVIRONMENT += AM_TESTS_REEXEC=no; export AM_TESTS_REEXEC;
+# We want warning messages and explanations for skipped tests to go to
+# the console if possible, so set up `stderr_fileno_' properly.
+AM_TESTS_FD_REDIRECT = 9>&2
+AM_TESTS_ENVIRONMENT += stderr_fileno_=9; export stderr_fileno_;
TESTS = \
+ $(handwritten_tests) \
+ $(config_shell_tests) \
+ $(parallel_tests)
+
+EXTRA_DIST += $(handwritten_tests)
+
+handwritten_tests = \
+## This tests might quite a long time, since they run various checks
+## sequentially; so place them early first to improve performance on
+## concurrent testsuite runs.
+depmod.tap \
+instspc.tap \
aclocal.test \
aclocal3.test \
aclocal4.test \
top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
-TEST_EXTENSIONS = .test .tap
+
+# Run the tests with the shell detected at configure time.
+LOG_COMPILER = $(SHELL)
+TEST_EXTENSIONS = .test .tap .ptest .shtst
+TEST_LOG_COMPILER = $(LOG_COMPILER)
+TAP_LOG_COMPILER = $(LOG_COMPILER)
TAP_LOG_DRIVER = AM_TAP_AWK='$(AWK)' $(SHELL) $(top_srcdir)/lib/tap-driver.sh
- TAP_LOG_DRIVER_FLAGS = --merge --comments --diagnostic-string `printf \
- '\043%%\043\n'`
-AM_TAP_LOG_DRIVER_FLAGS = --merge
-MAINTAINERCLEANFILES = $(parallel_tests) $(instspc_tests)
-EXTRA_DIST = ChangeLog-old gen-parallel-tests instspc-tests.sh \
- $(TESTS) tap-functions.sh plain-functions.sh \
++AM_TAP_LOG_DRIVER_FLAGS = --merge --comments --diagnostic-string \
++ `printf '\043%%\043\n'`
+MAINTAINERCLEANFILES =
+EXTRA_DIST = ChangeLog-old gen-parallel-tests parallel-tests.sh \
+ gen-config-shell-tests config-shell-tests.sh \
+ $(handwritten_tests) tap-functions.sh plain-functions.sh \
trivial-test-driver testsuite-summary-checks.sh \
extract-testsuite-summary tap-setup.sh tap-summary-aux.sh
-XFAIL_TESTS = all.test auxdir2.test cond17.test gcj6.test \
- override-conditional-2.test pr8365-remake-timing.test \
- yacc-dist-nobuild-subdir.test txinfo5.test \
- $(instspc_xfail_tests)
-parallel_tests = check-concurrency-bug9245-p.test \
- check-exported-srcdir-p.test check-fd-redirect-p.test \
- check-tests-in-builddir-p.test check-p.test check11-p.test \
- check12-p.test check2-p.test check3-p.test check4-p.test \
- check5-p.test check6-p.test check7-p.test check8-p.test \
- check9-p.test color-p.test color2-p.test comment9-p.test \
- dejagnu-p.test exeext4-p.test maken3-p.test maken4-p.test \
- posixsubst-tests-p.test tests-environment-p.test
-instspc_tests = instspc-squote-build.test instspc-squote-install.test \
- instspc-dquote-build.test instspc-dquote-install.test \
- instspc-bquote-build.test instspc-bquote-install.test \
- instspc-sharp-build.test instspc-sharp-install.test \
- instspc-dollar-build.test instspc-dollar-install.test \
- instspc-bang-build.test instspc-bang-install.test \
- instspc-bslash-build.test instspc-bslash-install.test \
- instspc-ampersand-build.test instspc-ampersand-install.test \
- instspc-percent-build.test instspc-percent-install.test \
- instspc-leftpar-build.test instspc-leftpar-install.test \
- instspc-rightpar-build.test instspc-rightpar-install.test \
- instspc-pipe-build.test instspc-pipe-install.test \
- instspc-caret-build.test instspc-caret-install.test \
- instspc-tilde-build.test instspc-tilde-install.test \
- instspc-qmark-build.test instspc-qmark-install.test \
- instspc-star-build.test instspc-star-install.test \
- instspc-plus-build.test instspc-plus-install.test \
- instspc-minus-build.test instspc-minus-install.test \
- instspc-comma-build.test instspc-comma-install.test \
- instspc-colon-build.test instspc-colon-install.test \
- instspc-semicol-build.test instspc-semicol-install.test \
- instspc-equal-build.test instspc-equal-install.test \
- instspc-less-build.test instspc-less-install.test \
- instspc-more-build.test instspc-more-install.test \
- instspc-at-build.test instspc-at-install.test \
- instspc-lqbrack-build.test instspc-lqbrack-install.test \
- instspc-rqbrack-build.test instspc-rqbrack-install.test \
- instspc-lcbrack-build.test instspc-lcbrack-install.test \
- instspc-rcbrack-build.test instspc-rcbrack-install.test \
- instspc-space-build.test instspc-space-install.test \
- instspc-tab-build.test instspc-tab-install.test \
- instspc-linefeed-build.test instspc-linefeed-install.test \
- instspc-backspace-build.test instspc-backspace-install.test \
- instspc-formfeed-build.test instspc-formfeed-install.test \
- instspc-carriageret-build.test \
- instspc-carriageret-install.test \
- instspc-quadrigraph0-build.test \
- instspc-quadrigraph0-install.test \
- instspc-quadrigraph1-build.test \
- instspc-quadrigraph1-install.test \
- instspc-quadrigraph2-build.test \
- instspc-quadrigraph2-install.test \
- instspc-quadrigraph3-build.test \
- instspc-quadrigraph3-install.test \
- instspc-quadrigraph4-build.test \
- instspc-quadrigraph4-install.test instspc-a_b-build.test \
- instspc-a_b-install.test instspc-a__b-build.test \
- instspc-a__b-install.test instspc-a_lf_b-build.test \
- instspc-a_lf_b-install.test instspc-dotdotdot-build.test \
- instspc-dotdotdot-install.test instspc-dosdrive-build.test \
- instspc-dosdrive-install.test instspc-miscglob1-build.test \
- instspc-miscglob1-install.test instspc-miscglob2-build.test \
- instspc-miscglob2-install.test
-instspc_xfail_tests = instspc-squote-build.test \
- instspc-dquote-build.test instspc-bquote-build.test \
- instspc-sharp-build.test instspc-dollar-build.test \
- instspc-bslash-build.test instspc-ampersand-build.test \
- instspc-linefeed-build.test instspc-quadrigraph0-build.test \
- instspc-a_lf_b-build.test instspc-squote-install.test \
- instspc-dquote-install.test instspc-bquote-install.test \
- instspc-sharp-install.test instspc-dollar-install.test \
- instspc-linefeed-install.test instspc-a_lf_b-install.test
+XFAIL_TESTS = \
+all.test \
+cond17.test \
+gcj6.test \
+override-conditional-2.test \
+pr8365-remake-timing.test \
+yacc-dist-nobuild-subdir.test \
+txinfo5.test
+
- parallel_tests = backcompat5-p.ptest check-concurrency-bug9245-p.ptest \
++parallel_tests = check-concurrency-bug9245-p.ptest \
+ check-exported-srcdir-p.ptest check-fd-redirect-p.ptest \
+ check-subst-prog-p.ptest check-subst-p.ptest \
+ check-tests-in-builddir-p.ptest check-p.ptest check11-p.ptest \
+ check12-p.ptest check2-p.ptest check3-p.ptest check4-p.ptest \
+ check5-p.ptest check6-p.ptest check7-p.ptest check8-p.ptest \
+ color-p.ptest color2-p.ptest comment9-p.ptest dejagnu-p.ptest \
+ exeext4-p.ptest maken3-p.ptest maken4-p.ptest \
+ posixsubst-tests-p.ptest tests-environment-p.ptest
+PTEST_LOG_COMPILER = $(LOG_COMPILER) $(srcdir)/parallel-tests.sh
+config_shell_tests = ar-lib-w.shtst compile-w.shtst compile2-w.shtst \
+ compile3-w.shtst compile4-w.shtst compile5-w.shtst \
+ compile6-w.shtst instsh2-w.shtst instsh3-w.shtst \
+ mdate5-w.shtst mdate6-w.shtst missing-w.shtst missing2-w.shtst \
+ missing3-w.shtst missing5-w.shtst mkinst3-w.shtst
+SHTST_LOG_COMPILER = $(LOG_COMPILER) $(srcdir)/config-shell-tests.sh
# Some testsuite-influential variables should be overridable from the
# test scripts, but not from the environment.
-AM_TESTS_ENVIRONMENT = \
- test x"$$me" = x || unset me; \
- test x"$$required" = x || unset required; \
- test x"$$using_tap" = x || unset using_tap; \
- test x"$$parallel_tests" = x || unset parallel_tests; \
- test x"$$original_AUTOMAKE" = x || unset original_AUTOMAKE; \
- test x"$$original_ACLOCAL" = x || unset original_ACLOCAL;
-
+# The `AM_TESTS_REEXEC=no' setting tells the tests not to needlessly
+# re-execute themselves with the shell detected at configure time, since
+# we are already running them under it explicitly in our setup (see e.g.
+# the definition of TEST_LOG_COMPILER above).
+AM_TESTS_ENVIRONMENT = test x"$$me" = x || unset me; test \
- x"$$required" = x || unset required; test x"$$use_tap" = x || \
- unset use_tap; test x"$$parallel_tests" = x || unset \
++ x"$$required" = x || unset required; test x"$$using_tap" = x \
++ || unset using_tap; test x"$$parallel_tests" = x || unset \
+ parallel_tests; test x"$$test_prefer_config_shell" || unset \
+ test_prefer_config_shell; test x"$$original_AUTOMAKE" = x || \
+ unset original_AUTOMAKE; test x"$$original_ACLOCAL" = x || \
+ unset original_ACLOCAL; AM_TESTS_REEXEC=no; export \
+ AM_TESTS_REEXEC; stderr_fileno_=9; export stderr_fileno_;
+# We want warning messages and explanations for skipped tests to go to
+# the console if possible, so set up `stderr_fileno_' properly.
+AM_TESTS_FD_REDIRECT = 9>&2
TESTS = \
+ $(handwritten_tests) \
+ $(config_shell_tests) \
+ $(parallel_tests)
+
+handwritten_tests = \
+depmod.tap \
+instspc.tap \
aclocal.test \
aclocal3.test \
aclocal4.test \