emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] emacs-25 4e62197 1/2: Introduce check-expensive tests.


From: Michael Albinus
Subject: [Emacs-diffs] emacs-25 4e62197 1/2: Introduce check-expensive tests.
Date: Mon, 04 Jan 2016 22:29:02 +0000

branch: emacs-25
commit 4e62197a64e6386e24b328c40d6020412ea3031d
Author: Michael Albinus <address@hidden>
Commit: Michael Albinus <address@hidden>

    Introduce check-expensive tests.
    
    * Makefile.in (check-expensive):
    * test/automated/Makefile.in (check-expensive): New target.
    
    * test/automated/auto-revert-tests.el
    (auto-revert-test01-auto-revert-several-files):
    * test/automated/file-notify-tests.el (file-notify--deftest-remote):
    * test/automated/tramp-tests.el (tramp-test26-process-file)
    (tramp-test27-start-file-process, tramp-test28-shell-command)
    (tramp-test29-vc-registered)
    (tramp-test31-special-characters-with-stat)
    (tramp-test31-special-characters-with-perl)
    (tramp-test31-special-characters-with-ls)
    (tramp-test32-utf8-with-stat, tramp-test32-utf8-with-perl)
    (tramp-test32-utf8-with-ls, tramp-test33-asynchronous-requests)
    (tramp-test35-unload): Tag the tests as :expensive-test.
---
 Makefile.in                         |    6 +++---
 test/automated/Makefile.in          |   10 +++++++++-
 test/automated/auto-revert-tests.el |    1 +
 test/automated/file-notify-tests.el |    1 +
 test/automated/tramp-tests.el       |   12 ++++++++++++
 5 files changed, 26 insertions(+), 4 deletions(-)

diff --git a/Makefile.in b/Makefile.in
index c6a7bda..b792e7c 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -921,12 +921,12 @@ extraclean: $(extraclean_dirs:=_extraclean)
 TAGS tags: lib lib-src src
        $(MAKE) -C src tags
 
-check: all
+check check-expensive: all
        @if test ! -d test/automated; then \
          echo "You do not seem to have the test/ directory."; \
          echo "Maybe you are using a release tarfile, rather than a repository 
checkout."; \
        else \
-         $(MAKE) -C test/automated check; \
+         $(MAKE) -C test/automated $@; \
        fi
 
 dist:
@@ -943,7 +943,7 @@ $(DOCS):
        $(MAKE) -C doc/$(subst -, ,$@)
 
 .PHONY: $(DOCS) docs pdf ps
-.PHONY: info dvi dist check html info-real info-dir check-info
+.PHONY: info dvi dist check check-expensive html info-real info-dir check-info
 
 ## TODO add etc/refcards.
 docs: $(DOCS)
diff --git a/test/automated/Makefile.in b/test/automated/Makefile.in
index b36e7f9..43e3905 100644
--- a/test/automated/Makefile.in
+++ b/test/automated/Makefile.in
@@ -87,6 +87,9 @@ WRITE_LOG = > $@ 2>&1 || { stat=ERROR; cat $@; }; echo 
$$stat: $@
 ## 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=(not (tag :expensive-test))
+SELECTOR_EXPENSIVE=nil
+SELECTOR=${SELECTOR_DEFAULT}
 %.log: ${srcdir}/%.el
        @if grep '^;.*no-byte-compile: t' $< > /dev/null; then \
          loadfile=$<; \
@@ -97,7 +100,7 @@ WRITE_LOG = > $@ 2>&1 || { stat=ERROR; cat $@; }; echo 
$$stat: $@
        echo Testing $$loadfile; \
        stat=OK ; \
        $(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 = $(sort $(wildcard ${srcdir}/*.el))
 LOGFILES = $(patsubst %.el,%.log,$(notdir ${ELFILES}))
@@ -124,6 +127,11 @@ check:
        address@hidden f in *.log; do test ! -f $$f || mv $$f $$f~; done
        @${MAKE} check-maybe
 
+## Rerun also expensive tests.
+.PHONY: check-expensive
+check-expensive:
+       @${MAKE} check SELECTOR=${SELECTOR_EXPENSIVE}
+
 ## Only re-run tests whose .log is older than the test.
 .PHONY: check-maybe
 check-maybe: ${LOGFILES}
diff --git a/test/automated/auto-revert-tests.el 
b/test/automated/auto-revert-tests.el
index 2d67465..a6f8cb2 100644
--- a/test/automated/auto-revert-tests.el
+++ b/test/automated/auto-revert-tests.el
@@ -94,6 +94,7 @@
 ;; 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"))
diff --git a/test/automated/file-notify-tests.el 
b/test/automated/file-notify-tests.el
index 5479eb1..7bf7b0b 100644
--- a/test/automated/file-notify-tests.el
+++ b/test/automated/file-notify-tests.el
@@ -138,6 +138,7 @@ being the result.")
   (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)))
diff --git a/test/automated/tramp-tests.el b/test/automated/tramp-tests.el
index f072584..b664204 100644
--- a/test/automated/tramp-tests.el
+++ b/test/automated/tramp-tests.el
@@ -1394,6 +1394,7 @@ This tests also `make-symbolic-link', `file-truename' and 
`add-name-to-file'."
 
 (ert-deftest tramp-test26-process-file ()
   "Check `process-file'."
+  :tags '(:expensive-test)
   (skip-unless (tramp--test-enabled))
   (skip-unless
    (not
@@ -1440,6 +1441,7 @@ This tests also `make-symbolic-link', `file-truename' and 
`add-name-to-file'."
 
 (ert-deftest tramp-test27-start-file-process ()
   "Check `start-file-process'."
+  :tags '(:expensive-test)
   (skip-unless (tramp--test-enabled))
   (skip-unless
    (not
@@ -1509,6 +1511,7 @@ This tests also `make-symbolic-link', `file-truename' and 
`add-name-to-file'."
 
 (ert-deftest tramp-test28-shell-command ()
   "Check `shell-command'."
+  :tags '(:expensive-test)
   (skip-unless (tramp--test-enabled))
   (skip-unless
    (not
@@ -1596,6 +1599,7 @@ This tests also `make-symbolic-link', `file-truename' and 
`add-name-to-file'."
 
 (ert-deftest tramp-test29-vc-registered ()
   "Check `vc-registered'."
+  :tags '(:expensive-test)
   (skip-unless (tramp--test-enabled))
   (skip-unless
    (eq
@@ -1971,6 +1975,7 @@ Several special characters do not work properly there."
 (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
@@ -1989,6 +1994,7 @@ Use the `stat' command."
 (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
@@ -2010,6 +2016,7 @@ Use the `perl' command."
 (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
@@ -2050,6 +2057,7 @@ Use the `ls' command."
 (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
@@ -2068,6 +2076,7 @@ Use the `stat' command."
 (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
@@ -2089,6 +2098,7 @@ Use the `perl' command."
 (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
@@ -2114,6 +2124,7 @@ Such requests could arrive from timers, process filters 
and
 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
@@ -2225,6 +2236,7 @@ process sentinels.  They shall not disturb each other."
 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.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]