exit 1; \
fi
-check check-maybe: have-tests all
+check check-maybe check-expensive: have-tests all
$(MAKE) -C test $@
dist:
$(MAKE) -C doc/$(subst -, ,$@)
.PHONY: $(DOCS) docs pdf ps
-.PHONY: info dvi dist check check-maybe html info-real info-dir check-info
+.PHONY: info dvi dist check check-maybe check-expensive html info-real info-dir check-info
## TODO add etc/refcards.
docs: $(DOCS)
## to change this; bug#17848 - if that gets done, this can be simplified).
##
## Beware: it approximates 'no-byte-compile', so watch out for false-positives!
+SELECTOR_DEFAULT=(quote (not (tag :expensive-test)))
+SELECTOR_EXPENSIVE=nil
+SELECTOR=
%.log: %.el
@if grep '^;.*no-byte-compile: t' $< > /dev/null; then \
loadfile=$<; \
stat=OK ; \
mkdir --parents $(dir $@) ; \
$(emacs) -l ert -l $$loadfile \
- -f ert-run-tests-batch-and-exit ${WRITE_LOG}
+ --eval "(ert-run-tests-batch-and-exit ${SELECTOR})" ${WRITE_LOG}
ELFILES = $(shell find ${srcdir} -path "${srcdir}/manual" -prune -o \
-path "*resources" -prune -o -name "*el" -print)
-include make-test-deps.mk
## Rerun default tests.
check:
- -@for f in $(LOGFILES); do test ! -f $$f || mv $$f $$f~; done
+ @${MAKE} check-doit SELECTOR="${SELECTOR_DEFAULT}"
+
+## Rerun also expensive tests.
+.PHONY: check-expensive
+check-expensive:
+ @${MAKE} check-doit SELECTOR="${SELECTOR_EXPENSIVE}"
+
+## Re-run all the tests every time.
+.PHONY: check-doit
+check-doit:
+ -@for f in *.log; do test ! -f $$f || mv $$f $$f~; done
@${MAKE} check-maybe
## Only re-run tests whose .log is older than the test.
;; This is inspired by Bug#21841.
(ert-deftest auto-revert-test01-auto-revert-several-files ()
"Check autorevert for several files at once."
+ :tags '(:expensive-test)
(skip-unless (executable-find "cp"))
(let* ((cp (executable-find "cp"))
;; Strange, that `copy-directory' does not work as expected.
;; The following shell command is not portable on all
;; platforms, unfortunately.
- (shell-command (format "%s %s/* %s" cp tmpdir2 tmpdir1))
+ (shell-command (format "%s -f %s/* %s" cp tmpdir2 tmpdir1))
;; Check, that the buffers have been reverted.
(dolist (buf (list buf1 buf2))
(declare (indent 1))
`(ert-deftest ,(intern (concat (symbol-name test) "-remote")) ()
,docstring
+ :tags '(:expensive-test)
(let* ((temporary-file-directory
file-notify-test-remote-temporary-file-directory)
(ert-test (ert-get-test ',test)))
(ert-deftest file-notify-test06-many-events ()
"Check that events are not dropped."
+ :tags '(:expensive-test)
(skip-unless (file-notify--test-local-enabled))
;; Under cygwin events arrive in random order. Impossible to define a test.
(skip-unless (not (eq system-type 'cygwin)))
(ert-deftest tramp-test26-process-file ()
"Check `process-file'."
+ :tags '(:expensive-test)
(skip-unless (tramp--test-enabled))
(skip-unless
(not
(ert-deftest tramp-test27-start-file-process ()
"Check `start-file-process'."
+ :tags '(:expensive-test)
(skip-unless (tramp--test-enabled))
(skip-unless
(not
(ert-deftest tramp-test28-shell-command ()
"Check `shell-command'."
+ :tags '(:expensive-test)
(skip-unless (tramp--test-enabled))
(skip-unless
(not
(ert-deftest tramp-test29-vc-registered ()
"Check `vc-registered'."
+ :tags '(:expensive-test)
(skip-unless (tramp--test-enabled))
(skip-unless
(eq
(ert-deftest tramp-test31-special-characters-with-stat ()
"Check special characters in file names.
Use the `stat' command."
+ :tags '(:expensive-test)
(skip-unless (tramp--test-enabled))
(skip-unless
(eq
(ert-deftest tramp-test31-special-characters-with-perl ()
"Check special characters in file names.
Use the `perl' command."
+ :tags '(:expensive-test)
(skip-unless (tramp--test-enabled))
(skip-unless
(eq
(ert-deftest tramp-test31-special-characters-with-ls ()
"Check special characters in file names.
Use the `ls' command."
+ :tags '(:expensive-test)
(skip-unless (tramp--test-enabled))
(skip-unless
(eq
(ert-deftest tramp-test32-utf8-with-stat ()
"Check UTF8 encoding in file names and file contents.
Use the `stat' command."
+ :tags '(:expensive-test)
(skip-unless (tramp--test-enabled))
(skip-unless
(eq
(ert-deftest tramp-test32-utf8-with-perl ()
"Check UTF8 encoding in file names and file contents.
Use the `perl' command."
+ :tags '(:expensive-test)
(skip-unless (tramp--test-enabled))
(skip-unless
(eq
(ert-deftest tramp-test32-utf8-with-ls ()
"Check UTF8 encoding in file names and file contents.
Use the `ls' command."
+ :tags '(:expensive-test)
(skip-unless (tramp--test-enabled))
(skip-unless
(eq
process sentinels. They shall not disturb each other."
;; Mark as failed until bug has been fixed.
:expected-result :failed
+ :tags '(:expensive-test)
(skip-unless (tramp--test-enabled))
(skip-unless
(eq
Since it unloads Tramp, it shall be the last test to run."
;; Mark as failed until all symbols are unbound.
:expected-result (if (featurep 'tramp) :failed :passed)
+ :tags '(:expensive-test)
(when (featurep 'tramp)
(unload-feature 'tramp 'force)
;; No Tramp feature must be left.