[PATCH 11/25] test: add test for sanitized notmuch-search output

Subject: [PATCH 11/25] test: add test for sanitized notmuch-search output

Date: Sat, 28 May 2011 14:51:46 -0700

To: Notmuch Mail

Cc:

From: Jameson Graef Rollins


From: Florian Friesdorf <flo@chaoflow.net>

Signed-off-by: Jameson Graef Rollins <jrollins@finestructure.net>
---
 test/search-output |    9 +++++++++
 1 files changed, 9 insertions(+), 0 deletions(-)

diff --git a/test/search-output b/test/search-output
index 13f9613..8edc26a 100755
--- a/test/search-output
+++ b/test/search-output
@@ -304,6 +304,15 @@ cat <<EOF >EXPECTED
 EOF
 test_expect_equal_file OUTPUT EXPECTED
 
+test_begin_subtest "santize output for quoted-printable line-breaks in author and subject"
+add_message "[subject]='two =?ISO-8859-1?Q?line=0A_subject?=
+	headers'"
+notmuch search id:"$gen_msg_id" >OUTPUT
+cat <<EOF >EXPECTED
+thread:000000000000001b   2001-01-05 [1/1] Notmuch Test Suite; two line? subject headers (inbox unread)
+EOF
+test_expect_equal_file OUTPUT EXPECTED
+
 test_begin_subtest "notmuch search for non-existent message prints nothing"
 notmuch search "no-message-matches-this" > OUTPUT
 echo -n >EXPECTED
-- 
1.7.4.4


Thread: