]> git.eshelyaron.com Git - emacs.git/commitdiff
Fix EMBA failure for ert-test-record-backtrace
authorLars Ingebrigtsen <larsi@gnus.org>
Sat, 12 Mar 2022 21:40:49 +0000 (22:40 +0100)
committerLars Ingebrigtsen <larsi@gnus.org>
Sat, 12 Mar 2022 21:40:49 +0000 (22:40 +0100)
* test/lisp/emacs-lisp/ert-tests.el (ert-test-record-backtrace): Make
  this work with AOT.

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

index 7573d2ed05600a7161edbf432097f06a43655ae4..84c28e11315f764b30771f64ccc5d1ff4dfd26b6 100644 (file)
@@ -377,8 +377,11 @@ This macro is used to test if macroexpansion in `should' works."
          (test (make-ert-test :body test-body))
          (result (ert-run-test test)))
     (should (ert-test-failed-p result))
-    (should (eq (backtrace-frame-fun (car (ert-test-failed-backtrace result)))
-                'signal))))
+    (should (memq (backtrace-frame-fun (car (ert-test-failed-backtrace result)))
+                  ;;; This is `ert-fail' on nativecomp and `signal'
+                  ;;; otherwise.  It's not clear whether that's a bug
+                  ;;; or not (bug#51308).
+                  '(ert-fail signal)))))
 
 (ert-deftest ert-test-messages ()
   :tags '(:causes-redisplay)