From ed42d7ffb07da6d4cbfee5357384371cf0f2f00f Mon Sep 17 00:00:00 2001 From: Lars Ingebrigtsen Date: Sat, 12 Mar 2022 22:40:49 +0100 Subject: [PATCH] Fix EMBA failure for ert-test-record-backtrace * test/lisp/emacs-lisp/ert-tests.el (ert-test-record-backtrace): Make this work with AOT. --- test/lisp/emacs-lisp/ert-tests.el | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/test/lisp/emacs-lisp/ert-tests.el b/test/lisp/emacs-lisp/ert-tests.el index 7573d2ed056..84c28e11315 100644 --- a/test/lisp/emacs-lisp/ert-tests.el +++ b/test/lisp/emacs-lisp/ert-tests.el @@ -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) -- 2.39.2