X-Git-Url: https://git.notmuchmail.org/git?p=notmuch;a=blobdiff_plain;f=test%2Femacs-attachment-warnings.el;h=a23692d722e51d15d7020df3610dbda169ad2fdb;hp=a3067b1463070f3dfdefcd958659e1cb7c965749;hb=11ac932a4503872c19987b843d58513c4b9ef76f;hpb=7b756d1e3885b70e81647a85432e0f2d043167c9 diff --git a/test/emacs-attachment-warnings.el b/test/emacs-attachment-warnings.el index a3067b14..a23692d7 100644 --- a/test/emacs-attachment-warnings.el +++ b/test/emacs-attachment-warnings.el @@ -1,3 +1,4 @@ +(require 'cl-lib) (require 'notmuch-mua) (defun attachment-check-test (&optional fn) @@ -12,7 +13,8 @@ Return `t' if the message would be sent, otherwise `nil'" (condition-case nil ;; Force `y-or-n-p' to always return `nil', as if the user ;; pressed "n". - (letf (((symbol-function 'y-or-n-p) (lambda (&rest args) nil))) + (cl-letf (((symbol-function 'y-or-n-p) + (lambda (&rest args) nil))) (notmuch-mua-attachment-check) t) ('error nil))