1 Return-Path: <m.walters@qmul.ac.uk>
\r
2 X-Original-To: notmuch@notmuchmail.org
\r
3 Delivered-To: notmuch@notmuchmail.org
\r
4 Received: from localhost (localhost [127.0.0.1])
\r
5 by olra.theworths.org (Postfix) with ESMTP id A1976431FC2
\r
6 for <notmuch@notmuchmail.org>; Sun, 18 Jan 2015 10:11:59 -0800 (PST)
\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org
\r
11 X-Spam-Status: No, score=1.34 tagged_above=-999 required=5
\r
12 tests=[DKIM_ADSP_CUSTOM_MED=0.001, DNS_FROM_AHBL_RHSBL=2.438,
\r
13 FREEMAIL_FROM=0.001, NML_ADSP_CUSTOM_MED=1.2, RCVD_IN_DNSWL_MED=-2.3]
\r
15 Received: from olra.theworths.org ([127.0.0.1])
\r
16 by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)
\r
17 with ESMTP id uegCrfMIGDPF for <notmuch@notmuchmail.org>;
\r
18 Sun, 18 Jan 2015 10:11:56 -0800 (PST)
\r
19 Received: from mail2.qmul.ac.uk (mail2.qmul.ac.uk [138.37.6.6])
\r
20 (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits))
\r
21 (No client certificate requested)
\r
22 by olra.theworths.org (Postfix) with ESMTPS id 36D82431FAF
\r
23 for <notmuch@notmuchmail.org>; Sun, 18 Jan 2015 10:11:56 -0800 (PST)
\r
24 Received: from smtp.qmul.ac.uk ([138.37.6.40])
\r
25 by mail2.qmul.ac.uk with esmtp (Exim 4.71)
\r
26 (envelope-from <m.walters@qmul.ac.uk>)
\r
27 id 1YCuKI-0006P2-7y; Sun, 18 Jan 2015 18:11:54 +0000
\r
28 Received: from 5751dfa2.skybroadband.com ([87.81.223.162] helo=localhost)
\r
29 by smtp.qmul.ac.uk with esmtpsa (TLSv1:AES128-SHA:128) (Exim 4.71)
\r
30 (envelope-from <m.walters@qmul.ac.uk>)
\r
31 id 1YCuKH-00079q-Rw; Sun, 18 Jan 2015 18:11:54 +0000
\r
32 From: Mark Walters <markwalters1009@gmail.com>
\r
33 To: David Edmondson <dme@dme.org>, notmuch@notmuchmail.org
\r
34 Subject: Re: [PATCH v2 3/3] test: Update tests for 'authors_matched'
\r
35 and authors_non_matched'.
\r
36 In-Reply-To: <1414172643-28270-4-git-send-email-dme@dme.org>
\r
37 References: <1414172643-28270-1-git-send-email-dme@dme.org>
\r
38 <1414172643-28270-4-git-send-email-dme@dme.org>
\r
39 User-Agent: Notmuch/0.18.1+86~gef5e66a (http://notmuchmail.org) Emacs/24.4.1
\r
40 (x86_64-pc-linux-gnu)
\r
41 Date: Sun, 18 Jan 2015 18:12:13 +0000
\r
42 Message-ID: <87lhl0j6v6.fsf@qmul.ac.uk>
\r
44 Content-Type: text/plain; charset=utf-8
\r
45 Content-Transfer-Encoding: quoted-printable
\r
46 X-Sender-Host-Address: 87.81.223.162
\r
47 X-QM-Geographic: According to ripencc,
\r
48 this message was delivered by a machine in Britain (UK) (GB).
\r
49 X-QM-SPAM-Info: Sender has good ham record. :)
\r
50 X-QM-Body-MD5: 00fd39bf4b9b2d8345d0d89e2b43fc21 (of first 20000 bytes)
\r
51 X-SpamAssassin-Score: -0.1
\r
52 X-SpamAssassin-SpamBar: /
\r
53 X-SpamAssassin-Report: The QM spam filters have analysed this message to
\r
55 spam. We require at least 5.0 points to mark a message as spam.
\r
56 This message scored -0.1 points.
\r
57 Summary of the scoring:
\r
58 * 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail
\r
59 provider * (markwalters1009[at]gmail.com)
\r
60 * -0.0 T_RP_MATCHES_RCVD Envelope sender domain matches handover relay
\r
62 * -0.1 AWL AWL: Adjusted score from AWL reputation of From: address
\r
63 X-QM-Scan-Virus: ClamAV says the message is clean
\r
64 X-BeenThere: notmuch@notmuchmail.org
\r
65 X-Mailman-Version: 2.1.13
\r
67 List-Id: "Use and development of the notmuch mail system."
\r
68 <notmuch.notmuchmail.org>
\r
69 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,
\r
70 <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>
\r
71 List-Archive: <http://notmuchmail.org/pipermail/notmuch>
\r
72 List-Post: <mailto:notmuch@notmuchmail.org>
\r
73 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>
\r
74 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,
\r
75 <mailto:notmuch-request@notmuchmail.org?subject=subscribe>
\r
76 X-List-Received-Date: Sun, 18 Jan 2015 18:11:59 -0000
\r
81 Only one small comment here: it would be nice to have a test that has a
\r
82 non-empty authors_non_matched field.
\r
88 On Fri, 24 Oct 2014, David Edmondson <dme@dme.org> wrote:
\r
90 > test/T160-json.sh | 9 +++++++++
\r
91 > test/T170-sexp.sh | 4 ++--
\r
92 > test/T470-missing-headers.sh | 8 ++++++++
\r
93 > 3 files changed, 19 insertions(+), 2 deletions(-)
\r
95 > diff --git a/test/T160-json.sh b/test/T160-json.sh
\r
96 > index c1cf649..0a8df18 100755
\r
97 > --- a/test/T160-json.sh
\r
98 > +++ b/test/T160-json.sh
\r
99 > @@ -25,6 +25,10 @@ test_expect_equal_json "$output" "[{\"thread\": \"XXX\=
\r
103 > \"authors\": \"Notmuch Test Suite\",
\r
104 > + \"authors_matched\": [
\r
105 > + \"Notmuch Test Suite\"
\r
107 > + \"authors_non_matched\": [],
\r
108 > \"subject\": \"json-search-subject\",
\r
109 > \"query\": [\"id:$gen_msg_id\", null],
\r
110 > \"tags\": [\"inbox\",
\r
111 > @@ -59,6 +63,11 @@ test_expect_equal_json "$output" "[{\"thread\": \"XXX\=
\r
115 > \"authors\": \"Notmuch Test Suite\",
\r
116 > + \"authors\": \"Notmuch Test Suite\",
\r
117 > + \"authors_matched\": [
\r
118 > + \"Notmuch Test Suite\"
\r
120 > + \"authors_non_matched\": [],
\r
121 > \"subject\": \"json-search-utf8-body-s=C3=BCbj=C3=A9ct\",
\r
122 > \"query\": [\"id:$gen_msg_id\", null],
\r
123 > \"tags\": [\"inbox\",
\r
124 > diff --git a/test/T170-sexp.sh b/test/T170-sexp.sh
\r
125 > index 667e319..f2a08bf 100755
\r
126 > --- a/test/T170-sexp.sh
\r
127 > +++ b/test/T170-sexp.sh
\r
128 > @@ -19,7 +19,7 @@ test_expect_equal "$output" "((((:id \"${gen_msg_id}\" =
\r
129 :match t :excluded nil :f
\r
130 > test_begin_subtest "Search message: sexp"
\r
131 > add_message "[subject]=3D\"sexp-search-subject\"" "[date]=3D\"Sat, 01 Ja=
\r
132 n 2000 12:00:00 -0000\"" "[body]=3D\"sexp-search-message\""
\r
133 > output=3D$(notmuch search --format=3Dsexp "sexp-search-message" | notmuc=
\r
135 > -test_expect_equal "$output" "((:thread \"0000000000000002\" :timestamp 9=
\r
136 46728000 :date_relative \"2000-01-01\" :matched 1 :total 1 :authors \"Notmu=
\r
137 ch Test Suite\" :subject \"sexp-search-subject\" :query (\"id:$gen_msg_id\"=
\r
138 nil) :tags (\"inbox\" \"unread\")))"
\r
139 > +test_expect_equal "$output" "((:thread \"0000000000000002\" :timestamp 9=
\r
140 46728000 :date_relative \"2000-01-01\" :matched 1 :total 1 :authors \"Notmu=
\r
141 ch Test Suite\" :authors_matched (\"Notmuch Test Suite\") :authors_non_matc=
\r
142 hed () :subject \"sexp-search-subject\" :query (\"id:$gen_msg_id\" nil) :ta=
\r
143 gs (\"inbox\" \"unread\")))"
\r
145 > test_begin_subtest "Show message: sexp, utf-8"
\r
146 > add_message "[subject]=3D\"sexp-show-utf8-body-s=C3=BCbj=C3=A9ct\"" "[da=
\r
147 te]=3D\"Sat, 01 Jan 2000 12:00:00 -0000\"" "[body]=3D\"js=C3=B6n-show-m=C3=
\r
149 > @@ -44,7 +44,7 @@ test_expect_equal "$output" "((((:id \"$id\" :match t :=
\r
150 excluded nil :filename \"
\r
151 > test_begin_subtest "Search message: sexp, utf-8"
\r
152 > add_message "[subject]=3D\"sexp-search-utf8-body-s=C3=BCbj=C3=A9ct\"" "[=
\r
153 date]=3D\"Sat, 01 Jan 2000 12:00:00 -0000\"" "[body]=3D\"js=C3=B6n-search-m=
\r
155 > output=3D$(notmuch search --format=3Dsexp "js=C3=B6n-search-m=C3=A9ssage=
\r
156 " | notmuch_search_sanitize)
\r
157 > -test_expect_equal "$output" "((:thread \"0000000000000005\" :timestamp 9=
\r
158 46728000 :date_relative \"2000-01-01\" :matched 1 :total 1 :authors \"Notmu=
\r
159 ch Test Suite\" :subject \"sexp-search-utf8-body-s=C3=BCbj=C3=A9ct\" :query=
\r
160 (\"id:$gen_msg_id\" nil) :tags (\"inbox\" \"unread\")))"
\r
161 > +test_expect_equal "$output" "((:thread \"0000000000000005\" :timestamp 9=
\r
162 46728000 :date_relative \"2000-01-01\" :matched 1 :total 1 :authors \"Notmu=
\r
163 ch Test Suite\" :authors_matched (\"Notmuch Test Suite\") :authors_non_matc=
\r
164 hed () :subject \"sexp-search-utf8-body-s=C3=BCbj=C3=A9ct\" :query (\"id:$g=
\r
165 en_msg_id\" nil) :tags (\"inbox\" \"unread\")))"
\r
169 > diff --git a/test/T470-missing-headers.sh b/test/T470-missing-headers.sh
\r
170 > index cb38301..250a370 100755
\r
171 > --- a/test/T470-missing-headers.sh
\r
172 > +++ b/test/T470-missing-headers.sh
\r
173 > @@ -34,6 +34,10 @@ test_expect_equal_json "$output" '
\r
177 > + "authors_matched": [
\r
180 > + "authors_non_matched": [],
\r
181 > "date_relative": "2001-01-05",
\r
184 > @@ -48,6 +52,10 @@ test_expect_equal_json "$output" '
\r
187 > "authors": "Notmuch Test Suite",
\r
188 > + "authors_matched": [
\r
189 > + "Notmuch Test Suite"
\r
191 > + "authors_non_matched": [],
\r
192 > "date_relative": "1970-01-01",
\r
198 > _______________________________________________
\r
199 > notmuch mailing list
\r
200 > notmuch@notmuchmail.org
\r
201 > http://notmuchmail.org/mailman/listinfo/notmuch
\r