X-Git-Url: https://git.notmuchmail.org/git?p=notmuch;a=blobdiff_plain;f=test%2Ftest-lib.el;h=496626f6b482e92d37f830d8674d5c6b4a6f3d6a;hp=36afe630e5edb35d0a007bcb3be6a2131d9e8d20;hb=6a833a6e83865f6999707cc30768d07e1351c2cb;hpb=eed6c75556e18d943ac690598edceef0c4ee59d5 diff --git a/test/test-lib.el b/test/test-lib.el index 36afe630..496626f6 100644 --- a/test/test-lib.el +++ b/test/test-lib.el @@ -16,7 +16,7 @@ ;; General Public License for more details. ;; ;; You should have received a copy of the GNU General Public License -;; along with Notmuch. If not, see . +;; along with Notmuch. If not, see . ;; ;; Authors: Dmitry Kurochkin @@ -59,7 +59,9 @@ "Save visible text in current buffer to file FILENAME. Default FILENAME is OUTPUT." (notmuch-post-command) - (let ((text (visible-buffer-string))) + (let ((text (visible-buffer-string)) + ;; Tests expect output in UTF-8 encoding + (coding-system-for-write 'utf-8)) (with-temp-file (or filename "OUTPUT") (insert text)))) (defun visible-buffer-string () @@ -181,3 +183,18 @@ nothing." ;; suite (setq notmuch-tag-deleted-formats '((".*" nil))) + +;; force a common html renderer, to avoid test variations between +;; environments + +(setq mm-text-html-renderer 'html2text) + +;; Set some variables for S/MIME tests. + +(setq smime-keys '(("" "test_suite.pem" nil))) + +(setq mml-smime-use 'openssl) + +;; all test keys are without passphrase +(eval-after-load 'smime + '(defun smime-ask-passphrase (cache) nil))