Re: [PATCH 2/3] test: show what emacs sees of an encrypted message when crypto is disabled

2019-05-10 Thread David Bremner
Daniel Kahn Gillmor  writes:

> Some users may set notmuch-crypto-process-mime to nil, disabling all
> crypto use.  We should have a baseline for what that looks like.
> ---

pushed to master.
___
notmuch mailing list
notmuch@notmuchmail.org
https://notmuchmail.org/mailman/listinfo/notmuch


[PATCH 2/3] test: show what emacs sees of an encrypted message when crypto is disabled

2019-04-22 Thread Daniel Kahn Gillmor
Some users may set notmuch-crypto-process-mime to nil, disabling all
crypto use.  We should have a baseline for what that looks like.
---
 test/T450-emacs-show.sh|  6 ++
 .../notmuch-show-decrypted-message-no-crypto   | 10 ++
 2 files changed, 16 insertions(+)
 create mode 100644 
test/emacs-show.expected-output/notmuch-show-decrypted-message-no-crypto

diff --git a/test/T450-emacs-show.sh b/test/T450-emacs-show.sh
index 5d4df443..de1755d2 100755
--- a/test/T450-emacs-show.sh
+++ b/test/T450-emacs-show.sh
@@ -223,4 +223,10 @@ test_emacs '(notmuch-show 
"id:simple-encryp...@crypto.notmuchmail.org")
 (test-visible-output)'
 test_expect_equal_file $EXPECTED/notmuch-show-undecryptable-message OUTPUT
 
+test_begin_subtest "show encrypted message when not processing crypto"
+test_emacs '(let ((notmuch-crypto-process-mime nil))
+ (notmuch-show "id:basic-encryp...@crypto.notmuchmail.org")
+ (test-visible-output))'
+test_expect_equal_file $EXPECTED/notmuch-show-decrypted-message-no-crypto 
OUTPUT
+
 test_done
diff --git 
a/test/emacs-show.expected-output/notmuch-show-decrypted-message-no-crypto 
b/test/emacs-show.expected-output/notmuch-show-decrypted-message-no-crypto
new file mode 100644
index ..e302e452
--- /dev/null
+++ b/test/emacs-show.expected-output/notmuch-show-decrypted-message-no-crypto
@@ -0,0 +1,10 @@
+test_su...@notmuchmail.org (2000-01-01) (encrypted inbox)
+Subject: Here is the password
+To: test_su...@notmuchmail.org
+Date: Sat, 01 Jan 2000 12:00:00 +
+
+[ multipart/encrypted ]
+[ Unknown encryption status ]
+[ Unknown signature status ]
+[ application/pgp-encrypted ]
+[ application/octet-stream ]
-- 
2.20.1

___
notmuch mailing list
notmuch@notmuchmail.org
https://notmuchmail.org/mailman/listinfo/notmuch