[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] scratch/flymake-refactor b30fb9c 03/52: Allow running flym
From: |
Jo�o T�vora |
Subject: |
[Emacs-diffs] scratch/flymake-refactor b30fb9c 03/52: Allow running flymake-tests.el from interactive sessions |
Date: |
Sun, 1 Oct 2017 12:40:42 -0400 (EDT) |
branch: scratch/flymake-refactor
commit b30fb9cdbe9e0c2b3d536c7c4bb6a40c0b7f6286
Author: João Távora <address@hidden>
Commit: João Távora <address@hidden>
Allow running flymake-tests.el from interactive sessions
* test/lisp/progmodes/flymake-tests.el (flymake-tests-data-directory):
Expand to reasonable value if no
EMACS_TEST_DIRECTORY. (flymake-tests--current-face): Work around
"weirdness" of bug 17647 with read-event.
---
test/lisp/progmodes/flymake-tests.el | 15 ++++++++++++++-
1 file changed, 14 insertions(+), 1 deletion(-)
diff --git a/test/lisp/progmodes/flymake-tests.el
b/test/lisp/progmodes/flymake-tests.el
index 9bf6e7a..a5ad317 100644
--- a/test/lisp/progmodes/flymake-tests.el
+++ b/test/lisp/progmodes/flymake-tests.el
@@ -26,7 +26,11 @@
(require 'flymake)
(defvar flymake-tests-data-directory
- (expand-file-name "lisp/progmodes/flymake-resources" (getenv
"EMACS_TEST_DIRECTORY"))
+ (expand-file-name "lisp/progmodes/flymake-resources"
+ (or (getenv "EMACS_TEST_DIRECTORY")
+ (expand-file-name "../../.."
+ (or load-file-name
+ buffer-file-name))))
"Directory containing flymake test data.")
@@ -42,7 +46,16 @@
(goto-char (point-min))
(flymake-mode 1)
;; Weirdness here... http://debbugs.gnu.org/17647#25
+ ;; ... meaning `sleep-for', and even
+ ;; `accept-process-output', won't suffice as ways to get
+ ;; process filters and sentinels to run, though they do work
+ ;; fine in a non-interactive batch session. The only thing
+ ;; that will indeed unblock pending process output is
+ ;; reading an input event, so, as a workaround, use a dummy
+ ;; `read-event' with a very short timeout.
+ (unless noninteractive (read-event "" nil 0.1))
(while (and flymake-is-running (< (setq i (1+ i)) 10))
+ (unless noninteractive (read-event "" nil 0.1))
(sleep-for (+ 0.5 flymake-no-changes-timeout)))
(flymake-goto-next-error)
(face-at-point))
- [Emacs-diffs] branch scratch/flymake-refactor created (now 51a2b7b), Jo�o T�vora, 2017/10/01
- [Emacs-diffs] scratch/flymake-refactor b30fb9c 03/52: Allow running flymake-tests.el from interactive sessions,
Jo�o T�vora <=
- [Emacs-diffs] scratch/flymake-refactor e7e9d4f 01/52: Fix flymake-backends defcustom's docstring and usage, Jo�o T�vora, 2017/10/01
- [Emacs-diffs] scratch/flymake-refactor 3b06b52 02/52: Adjust flymake's UI/backend split started in earlier commit, Jo�o T�vora, 2017/10/01
- [Emacs-diffs] scratch/flymake-refactor dc39d65 04/52: flymake-ui.el provides new flymake-report as a re-entry point for backends., Jo�o T�vora, 2017/10/01
- [Emacs-diffs] scratch/flymake-refactor 46e0721 08/52: Fix test failure introduced by previous commit, Jo�o T�vora, 2017/10/01
- [Emacs-diffs] scratch/flymake-refactor 205c444 10/52: Use non-obsolete variable names in flymake-tests.el, Jo�o T�vora, 2017/10/01
- [Emacs-diffs] scratch/flymake-refactor 50a6920 11/52: Make flymake-tests.el friendlier to interactive runs, Jo�o T�vora, 2017/10/01
- [Emacs-diffs] scratch/flymake-refactor 46b4391 16/52: flymake-proc.el parses column numbers from gcc/javac errors, Jo�o T�vora, 2017/10/01
- [Emacs-diffs] scratch/flymake-refactor 4292342 13/52: Further simplify progmodes/flymake-ui.el, Jo�o T�vora, 2017/10/01
- [Emacs-diffs] scratch/flymake-refactor c5cc7e9 17/52: Make debugging flymake-proc.el easier, Jo�o T�vora, 2017/10/01
- [Emacs-diffs] scratch/flymake-refactor 2693054 14/52: Flymake faces are not just for "lines" anymore, Jo�o T�vora, 2017/10/01