1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-11-21 06:55:39 +00:00

Skip failing tests on Cygwin with native compilation (bug#62450)

* test/Makefile.in (TEST_NATIVE_COMP): New variable, used to
determine whether to run tests tagged with :nativecomp.  Set it to
"no" on Cygwin and to $(HAVE_NATIVE_COMP) otherwise.

* test/lisp/emacs-lisp/benchmark-tests.el (benchmark-tests): Skip
on Cygwin with native-compilation.
This commit is contained in:
Ken Brown 2023-03-25 16:37:51 -04:00
parent 8b4a494d8d
commit 45b16bfb49
2 changed files with 12 additions and 1 deletions

View File

@ -124,7 +124,14 @@ test_module_dir := src/emacs-module-resources
all: check
ifeq ($(HAVE_NATIVE_COMP),yes)
SYSTEM_TYPE = @SYSTEM_TYPE@
TEST_NATIVE_COMP = $(HAVE_NATIVE_COMP)
# Avoid fork failures on Cygwin. See bug#62450 and etc/PROBLEMS
# ("Fork failures in a build with native compilation").
ifeq ($(SYSTEM_TYPE),cygwin)
TEST_NATIVE_COMP = no
endif
ifeq ($(TEST_NATIVE_COMP),yes)
SELECTOR_DEFAULT = (not (or (tag :expensive-test) (tag :unstable)))
SELECTOR_EXPENSIVE = (not (tag :unstable))
SELECTOR_ALL = t

View File

@ -23,6 +23,10 @@
(require 'ert)
(ert-deftest benchmark-tests ()
;; Avoid fork failures on Cygwin. See bug#62450 and etc/PROBLEMS
;; ("Fork failures in a build with native compilation").
(skip-unless (not (and (eq system-type 'cygwin)
(featurep 'native-compile))))
(let (str t-long t-short m)
(should (consp (benchmark-run nil (setq m (1+ 0)))))
(should (consp (benchmark-run 1 (setq m (1+ 0)))))