summaryrefslogtreecommitdiff
path: root/test/Makefile.in
diff options
context:
space:
mode:
authorMichael Albinus <michael.albinus@gmx.de>2021-10-16 18:08:25 +0200
committerMichael Albinus <michael.albinus@gmx.de>2021-10-16 18:08:25 +0200
commitffff168d5fb14fbfa74f7c04fab0235a14bb7e64 (patch)
tree58acfcf59b97852d4182fa24128f738832139b22 /test/Makefile.in
parent4c468c6b3c12c12a96a6efce7a49c9b77e73bbd0 (diff)
downloademacs-ffff168d5fb14fbfa74f7c04fab0235a14bb7e64.tar.gz
Set EMACS_TEST_TIMEOUT for emba
* test/Makefile.in: Support EMACS_TEST_TIMEOUT environment variable. * test/README: Mention EMACS_TEST_TIMEOUT environment variable. * test/infra/gitlab-ci.yml (variables): Set default value of EMACS_TEST_TIMEOUT. (.job-template): Propagate EMACS_TEST_TIMEOUT and EMACS_TEST_VERBOSE. (test-all-inotify): Set specific EMACS_TEST_TIMEOUT.
Diffstat (limited to 'test/Makefile.in')
-rw-r--r--test/Makefile.in9
1 files changed, 7 insertions, 2 deletions
diff --git a/test/Makefile.in b/test/Makefile.in
index a5720b25714..7bef1c36605 100644
--- a/test/Makefile.in
+++ b/test/Makefile.in
@@ -77,9 +77,14 @@ EMACSOPT = --no-init-file --no-site-file --no-site-lisp -L "$(SEPCHAR)$(srcdir)"
# Prevent any settings in the user environment causing problems.
unexport EMACSDATA EMACSDOC EMACSPATH GREP_OPTIONS XDG_CONFIG_HOME
-## To run tests under a debugger, set this to eg: "gdb --args".
+# To run tests under a debugger, set this to eg: "gdb --args".
GDB =
+# Whether a timeout shall be given, writing possibly a core dump.
+ifneq (${EMACS_TEST_TIMEOUT},)
+TEST_TIMEOUT = timeout -s ABRT ${EMACS_TEST_TIMEOUT}
+endif
+
# Set this to 'yes' to run the tests in an interactive instance.
TEST_INTERACTIVE ?= no
@@ -117,7 +122,7 @@ endif
# and prevent locals to influence the text of the errors we expect to receive.
emacs = LANG=C EMACSLOADPATH= \
EMACS_TEST_DIRECTORY=$(abspath $(srcdir)) \
- $(GDB) "$(EMACS)" $(MODULES_EMACSOPT) $(EMACSOPT)
+ $(GDB) $(TEST_TIMEOUT) "$(EMACS)" $(MODULES_EMACSOPT) $(EMACSOPT)
# Set HOME to a nonexistent directory to prevent tests from accessing
# it accidentally (e.g., popping up a gnupg dialog if ~/.authinfo.gpg