]> git.eshelyaron.com Git - emacs.git/commitdiff
Give more information in a bytecomp test failure
authorGlenn Morris <rgm@gnu.org>
Wed, 12 Jun 2019 23:48:33 +0000 (16:48 -0700)
committerGlenn Morris <rgm@gnu.org>
Wed, 12 Jun 2019 23:49:06 +0000 (16:49 -0700)
* test/lisp/emacs-lisp/bytecomp-tests.el (test-suppression):
More informative failure messages.

test/lisp/emacs-lisp/bytecomp-tests.el

index 6fe7f5b571d5ab934105ae521258914cc8b2bbea..86cf2edec8b8615a0c668099ffb7276887a28cc0 100644 (file)
@@ -698,7 +698,7 @@ literals (Bug#20852)."
       (unless match
         (error "%s" (buffer-string)))
       (goto-char (point-min))
-      (should (re-search-forward match nil t)))
+      (should (string-match match (buffer-string))))
     ;; And that it's gone now.
     (with-current-buffer byte-compile-log-buffer
       (let ((inhibit-read-only t))
@@ -708,7 +708,7 @@ literals (Bug#20852)."
         ,form))
     (with-current-buffer byte-compile-log-buffer
       (goto-char (point-min))
-      (should-not (re-search-forward match nil t)))
+      (should-not (string-match match (buffer-string))))
     ;; Also check that byte compiled forms are identical.
     (should (equal (byte-compile form)
                    (byte-compile