summaryrefslogtreecommitdiff
path: root/test/lisp/progmodes/flymake-tests.el
diff options
context:
space:
mode:
authorJoão Távora <joaotavora@gmail.com>2017-09-26 01:35:43 +0100
committerJoão Távora <joaotavora@gmail.com>2017-10-03 14:18:54 +0100
commitf930963dd48e8c912a7623e204315b02433866cd (patch)
tree8830e585a70c774e45c528a72b1e199876e24214 /test/lisp/progmodes/flymake-tests.el
parent94a88c1ae98b1bf7ab80ae9cdd4d6e16b36597ef (diff)
downloademacs-f930963dd48e8c912a7623e204315b02433866cd.tar.gz
Simplify Flymake logging and erroring
Use display-warning and a dedicated *Flymake log* buffer. To ease readability, flymake log messages are now prefixed with a common prefix and the buffer that originated them. Some situations of over-zealous logging are fixed. Use byte-compiler info, if available, to determine whence the flymake-related log message is coming. * lisp/progmodes/flymake-proc.el (flymake-proc--diagnostics-for-pattern): Improve log message. (flymake-proc--panic): Always flymake-log an error (flymake-proc--safe-delete-file) (flymake-proc--safe-delete-directory): Downgrade warning (flymake-proc-start-syntax-check): Simplify slightly. (flymake-proc--start-syntax-check-process): Simplify. (flymake-proc--init-find-buildfile-dir) (flymake-proc--init-create-temp-source-and-master-buffer-copy): No need to warn twice. * lisp/progmodes/flymake.el (flymake-log): Convert to macro. (flymake--log-1): New helper. (flymake-log-level): Deprecate. (flymake-error): New helper. (flymake-ler-make-ler, flymake--handle-report, flymake-mode): Use flymake-error. (flymake-on-timer-event) (flymake--handle-report, flymake--disable-backend) (flymake--run-backend, flymake-start, flymake-mode-on) (flymake-mode-off, flymake-after-change-function) (flymake-after-save-hook, flymake-find-file-hook): Adjust flymake-log calls. * test/lisp/progmodes/flymake-tests.el (flymake-tests--call-with-fixture): Only log errors.
Diffstat (limited to 'test/lisp/progmodes/flymake-tests.el')
-rw-r--r--test/lisp/progmodes/flymake-tests.el3
1 files changed, 2 insertions, 1 deletions
diff --git a/test/lisp/progmodes/flymake-tests.el b/test/lisp/progmodes/flymake-tests.el
index c2deb1dc5c7..921c2f648a4 100644
--- a/test/lisp/progmodes/flymake-tests.el
+++ b/test/lisp/progmodes/flymake-tests.el
@@ -46,7 +46,8 @@ SEVERITY-PREDICATE is used to setup
(visiting (find-buffer-visiting file))
(buffer (or visiting (find-file-noselect file)))
(process-environment (cons "LC_ALL=C" process-environment))
- (i 0))
+ (i 0)
+ (warning-minimum-log-level :error))
(unwind-protect
(with-current-buffer buffer
(save-excursion