commit ef443467826dc33c6e58081e7af7c68905f6db26 (HEAD, refs/remotes/origin/master) Author: Helmut Eller Date: Sun Mar 2 16:35:33 2014 +0100 Make it easier to abort a series of tests with C-g * emacs-lisp/ert.el (ert-run-tests): Add "interactively" arg. If interactively is true and a test was aborted then ask if the remaining tests should be aborted too. (ert-run-tests-batch, ert-run-tests-interactively): Pass in interactively arg. diff --git a/lisp/emacs-lisp/ert.el b/lisp/emacs-lisp/ert.el index cadd66ca6e..611c67311b 100644 --- a/lisp/emacs-lisp/ert.el +++ b/lisp/emacs-lisp/ert.el @@ -1236,7 +1236,7 @@ SELECTOR is the selector that was used to select TESTS." (funcall listener 'test-ended stats test result)) (setf (ert--stats-current-test stats) nil)))) -(defun ert-run-tests (selector listener) +(defun ert-run-tests (selector listener interactively) "Run the tests specified by SELECTOR, sending progress updates to LISTENER." (let* ((tests (ert-select-tests selector t)) (stats (ert--make-stats tests selector))) @@ -1247,10 +1247,14 @@ SELECTOR is the selector that was used to select TESTS." (let ((ert--current-run-stats stats)) (force-mode-line-update) (unwind-protect - (progn - (cl-loop for test in tests do - (ert-run-or-rerun-test stats test listener)) - (setq abortedp nil)) + (cl-loop for test in tests do + (ert-run-or-rerun-test stats test listener) + (when (and interactively + (ert-test-quit-p + (ert-test-most-recent-result test)) + (y-or-n-p "Abort testing? ")) + (cl-return)) + finally (setq abortedp nil)) (setf (ert--stats-aborted-p stats) abortedp) (setf (ert--stats-end-time stats) (current-time)) (funcall listener 'run-ended stats abortedp))) @@ -1442,7 +1446,8 @@ Returns the stats object." (ert-test-result-expected-p test result)) (1+ (ert--stats-test-pos stats test)) - (ert-test-name test))))))))) + (ert-test-name test))))))) + nil)) ;;;###autoload (defun ert-run-tests-batch-and-exit (&optional selector) @@ -2033,9 +2038,8 @@ and how to display message." test result))) (ert--results-update-stats-display-maybe ewoc stats) (ewoc-invalidate ewoc node)))))))) - (ert-run-tests - selector - listener))) + (ert-run-tests selector listener t))) + ;;;###autoload (defalias 'ert 'ert-run-tests-interactively) commit 21d4db3e816ed7aa6424f632283253db59f5a275 Author: Noam Postavsky Date: Fri Mar 24 20:09:58 2017 -0400 ; lib-src/Makefile.in (exp_archlibdir): Drop extra '&&' from previous commit diff --git a/lib-src/Makefile.in b/lib-src/Makefile.in index 086d0dc9ef..fa8de0bcc9 100644 --- a/lib-src/Makefile.in +++ b/lib-src/Makefile.in @@ -293,7 +293,7 @@ $(DESTDIR)${archlibdir}: all chmod u=rwx,g=rx,o=rx "$(DESTDIR)${gamedir}" else -chgrp ${gamegroup} \ - "$(DESTDIR)${archlibdir}/update-game-score${EXEEXT}" && \ + "$(DESTDIR)${archlibdir}/update-game-score${EXEEXT}" \ "$(DESTDIR)${gamedir}" && \ chmod g+s,o-r \ "$(DESTDIR)${archlibdir}/update-game-score${EXEEXT}" && \ commit 211d41a6fe23fefef0e29d036d8599716e484657 Author: Paul Eggert Date: Fri Mar 24 10:09:25 2017 -0500 Don’t require chown/chgrp for game installation Problem reported by Joseph Mingrone in: http://lists.gnu.org/archive/html/emacs-devel/2017-03/msg00622.html * lib-src/Makefile.in (exp_archlibdir): Don’t fail if chown or chgrp fails with update-game-score and the game directory. Instead, expect the installer to fix this up afterwards. diff --git a/lib-src/Makefile.in b/lib-src/Makefile.in index b2cd66c049..086d0dc9ef 100644 --- a/lib-src/Makefile.in +++ b/lib-src/Makefile.in @@ -266,7 +266,9 @@ need-blessmail: blessmail maybe-blessmail: $(BLESSMAIL_TARGET) ## Install the internal utilities. Until they are installed, we can -## just run them directly from lib-src. +## just run them directly from lib-src. When installing, do not give +## up if chown or chgrp fails, as the package responsible for +## installing Emacs can fix this problem later. $(DESTDIR)${archlibdir}: all @echo @echo "Installing utilities run internally by Emacs." @@ -283,15 +285,19 @@ $(DESTDIR)${archlibdir}: all touch "$(DESTDIR)${gamedir}/snake-scores" \ "$(DESTDIR)${gamedir}/tetris-scores" ifneq (,$(gameuser)) - chown ${gameuser} "$(DESTDIR)${archlibdir}/update-game-score${EXEEXT}" - chmod u+s,go-r "$(DESTDIR)${archlibdir}/update-game-score${EXEEXT}" - chown ${gameuser} "$(DESTDIR)${gamedir}" - chmod u=rwx,g=rx,o=rx "$(DESTDIR)${gamedir}" + -chown ${gameuser} \ + "$(DESTDIR)${archlibdir}/update-game-score${EXEEXT}" \ + "$(DESTDIR)${gamedir}" && \ + chmod u+s,go-r \ + "$(DESTDIR)${archlibdir}/update-game-score${EXEEXT}" && \ + chmod u=rwx,g=rx,o=rx "$(DESTDIR)${gamedir}" else - chgrp ${gamegroup} "$(DESTDIR)${archlibdir}/update-game-score${EXEEXT}" - chmod g+s,o-r "$(DESTDIR)${archlibdir}/update-game-score${EXEEXT}" - chgrp ${gamegroup} "$(DESTDIR)${gamedir}" - chmod u=rwx,g=rwx,o=rx "$(DESTDIR)${gamedir}" + -chgrp ${gamegroup} \ + "$(DESTDIR)${archlibdir}/update-game-score${EXEEXT}" && \ + "$(DESTDIR)${gamedir}" && \ + chmod g+s,o-r \ + "$(DESTDIR)${archlibdir}/update-game-score${EXEEXT}" && \ + chmod u=rwx,g=rwx,o=rx "$(DESTDIR)${gamedir}" endif endif exp_archlibdir=`cd "$(DESTDIR)${archlibdir}" && /bin/pwd` && \ commit e69a5f5e456b39ad37f7d622386063548bea8208 Author: Stefan Monnier Date: Fri Mar 24 09:39:34 2017 -0400 * lisp/emacs-lisp/lisp-mode.el: Don't highlight \( at BOL (elisp--font-lock-backslash): Extract from lisp-el-font-lock-keywords-2. Don't highlight \ at BOL. Don't assume syntax-ppss preserves match-data. diff --git a/lisp/emacs-lisp/lisp-mode.el b/lisp/emacs-lisp/lisp-mode.el index d6293c0304..b7a5eb774d 100644 --- a/lisp/emacs-lisp/lisp-mode.el +++ b/lisp/emacs-lisp/lisp-mode.el @@ -259,6 +259,24 @@ This will generate compile-time constants from BINDINGS." (funcall loop bindings))))))) (funcall loop bindings))) +(defun elisp--font-lock-backslash () + (let* ((beg0 (match-beginning 0)) + (end0 (match-end 0)) + (ppss (save-excursion (syntax-ppss beg0)))) + (and (nth 3 ppss) ;Inside a string. + (not (nth 5 ppss)) ;The \ is not itself \-escaped. + ;; Don't highlight the \( introduced because of + ;; `open-paren-in-column-0-is-defun-start'. + (not (eq ?\n (char-before beg0))) + (equal (ignore-errors + (car (read-from-string + (format "\"%s\"" + (buffer-substring-no-properties + beg0 end0))))) + (buffer-substring-no-properties (1+ beg0) end0)) + `(face ,font-lock-warning-face + help-echo "This \\ has no effect")))) + (let-when-compile ((lisp-fdefs '("defmacro" "defun")) (lisp-vdefs '("defvar")) @@ -413,17 +431,7 @@ This will generate compile-time constants from BINDINGS." (1 font-lock-constant-face prepend)) ;; Ineffective backslashes (typically in need of doubling). ("\\(\\\\\\)\\([^\"\\]\\)" - (1 (let ((ppss (save-excursion (syntax-ppss (match-beginning 0))))) - (and (nth 3 ppss) ;Inside a string. - (not (nth 5 ppss)) ;The \ is not itself \-escaped. - (equal (ignore-errors - (car (read-from-string - (format "\"%s\"" - (match-string-no-properties 0))))) - (match-string-no-properties 2)) - `(face ,font-lock-warning-face - help-echo "This \\ has no effect"))) - prepend)) + (1 (elisp--font-lock-backslash) prepend)) ;; Words inside ‘’ and `' tend to be symbol names. (,(concat "[`‘]\\(\\(?:\\sw\\|\\s_\\|\\\\.\\)" lisp-mode-symbol-regexp "\\)['’]")