From: Noam Postavsky Date: Sun, 2 Jul 2017 02:37:12 +0000 (-0400) Subject: Let test summary go through even if some logs were not generated X-Git-Tag: emacs-26.0.90~521^2~11^2~13 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=9a2a7bb6e6e08c2107a94c9a2e90e316a6f91d48;p=emacs.git Let test summary go through even if some logs were not generated * lisp/emacs-lisp/ert.el (ert-summarize-tests-batch-and-exit): Check for existence of log files before reading. --- diff --git a/lisp/emacs-lisp/ert.el b/lisp/emacs-lisp/ert.el index 7edc40188e1..eb2b2e3e11b 100644 --- a/lisp/emacs-lisp/ert.el +++ b/lisp/emacs-lisp/ert.el @@ -1468,7 +1468,7 @@ this exits Emacs, with status as per `ert-run-tests-batch-and-exit'." (with-temp-buffer (while (setq logfile (pop command-line-args-left)) (erase-buffer) - (insert-file-contents logfile) + (when (file-readable-p logfile) (insert-file-contents logfile)) (if (not (re-search-forward "^Running \\([0-9]+\\) tests" nil t)) (push logfile notests) (setq ntests (+ ntests (string-to-number (match-string 1))))