Re: Error with contrib/notmuch-pick
[notmuch-archives.git] / fa / 86d14546a7779780c0f7ac270fc779ab34229b
1 Return-Path: <markwalters1009@gmail.com>\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 87C53429E2F\r
6         for <notmuch@notmuchmail.org>; Sun, 22 Jul 2012 07:38:18 -0700 (PDT)\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
8 X-Spam-Flag: NO\r
9 X-Spam-Score: 0.201\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=0.201 tagged_above=-999 required=5\r
12         tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1,\r
13         FREEMAIL_ENVFROM_END_DIGIT=1, FREEMAIL_FROM=0.001,\r
14         RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled\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 8Dcg7-wTF3G2 for <notmuch@notmuchmail.org>;\r
18         Sun, 22 Jul 2012 07:38:16 -0700 (PDT)\r
19 Received: from mail-wi0-f179.google.com (mail-wi0-f179.google.com\r
20         [209.85.212.179]) (using TLSv1 with cipher RC4-SHA (128/128 bits))\r
21         (No client certificate requested)\r
22         by olra.theworths.org (Postfix) with ESMTPS id 8B19B431FB6\r
23         for <notmuch@notmuchmail.org>; Sun, 22 Jul 2012 07:38:13 -0700 (PDT)\r
24 Received: by mail-wi0-f179.google.com with SMTP id hq4so1563921wib.2\r
25         for <notmuch@notmuchmail.org>; Sun, 22 Jul 2012 07:38:13 -0700 (PDT)\r
26 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113;\r
27         h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references;\r
28         bh=f6jmu3XZncueOLqAcFEAyQ9wR4sHczCRzQ4Ha5tShb0=;\r
29         b=g9HMytcoRROkyPJy65b+KEAWxeBt314DP1UkswYhOHFQvmSbxGPO9UKboajomRLIiB\r
30         cSAp1AU3GzZ8y3KllkvIKLTZjCBzAOFslWFv4gUUTvvud/mbtcVzlKAb5p0e+lssx4QQ\r
31         tAeBaSSx/fHxmhuFmxNe8NMYkXk+juqEtuiVpkiUgdEDbdm0HVRVttx3dZMQm3Sxh/pv\r
32         Zz3N2OSC4rxJgeR8N57jmlbYyHzvGfOEE0XPJiEO1Ab+a9DAusPi0QqjTs2N3uv8XR4S\r
33         +LcMuMcx92ZTxBngLnDfyob539lcQcZ5/L39JvSRVxANP7vcNZ2fbFLntmM3+MuS3zVk\r
34         kH2Q==\r
35 Received: by 10.216.85.149 with SMTP id u21mr6701439wee.147.1342967893107;\r
36         Sun, 22 Jul 2012 07:38:13 -0700 (PDT)\r
37 Received: from localhost (94-192-233-223.zone6.bethere.co.uk.\r
38  [94.192.233.223])      by mx.google.com with ESMTPS id\r
39  ex20sm16719766wid.7.2012.07.22.07.38.11        (version=TLSv1/SSLv3 cipher=OTHER);\r
40         Sun, 22 Jul 2012 07:38:12 -0700 (PDT)\r
41 From: Mark Walters <markwalters1009@gmail.com>\r
42 To: notmuch@notmuchmail.org\r
43 Subject: [PATCH 3/4] test: add some tests for --include-text-content option\r
44 Date: Sun, 22 Jul 2012 15:37:58 +0100\r
45 Message-Id: <1342967879-20453-4-git-send-email-markwalters1009@gmail.com>\r
46 X-Mailer: git-send-email 1.7.9.1\r
47 In-Reply-To: <1342967879-20453-1-git-send-email-markwalters1009@gmail.com>\r
48 References: <1342967879-20453-1-git-send-email-markwalters1009@gmail.com>\r
49 X-BeenThere: notmuch@notmuchmail.org\r
50 X-Mailman-Version: 2.1.13\r
51 Precedence: list\r
52 List-Id: "Use and development of the notmuch mail system."\r
53         <notmuch.notmuchmail.org>\r
54 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
55         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
56 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
57 List-Post: <mailto:notmuch@notmuchmail.org>\r
58 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
59 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
60         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
61 X-List-Received-Date: Sun, 22 Jul 2012 14:38:19 -0000\r
62 \r
63 ---\r
64  test/json |    9 +++++++++\r
65  1 files changed, 9 insertions(+), 0 deletions(-)\r
66 \r
67 diff --git a/test/json b/test/json\r
68 index 6439788..53cb039 100755\r
69 --- a/test/json\r
70 +++ b/test/json\r
71 @@ -7,6 +7,15 @@ add_message "[subject]=\"json-show-subject\"" "[date]=\"Sat, 01 Jan 2000 12:00:0\r
72  output=$(notmuch show --format=json "json-show-message")\r
73  test_expect_equal "$output" "[[[{\"id\": \"${gen_msg_id}\", \"match\": true, \"excluded\": false, \"filename\": \"${gen_msg_filename}\", \"timestamp\": 946728000, \"date_relative\": \"2000-01-01\", \"tags\": [\"inbox\",\"unread\"], \"headers\": {\"Subject\": \"json-show-subject\", \"From\": \"Notmuch Test Suite <test_suite@notmuchmail.org>\", \"To\": \"Notmuch Test Suite <test_suite@notmuchmail.org>\", \"Date\": \"Sat, 01 Jan 2000 12:00:00 +0000\"}, \"body\": [{\"id\": 1, \"content-type\": \"text/plain\", \"content\": \"json-show-message\n\"}]}, []]]]"\r
74  \r
75 +# This should be the same output as above.\r
76 +test_begin_subtest "Show message: json --include-text-content=true"\r
77 +output=$(notmuch show --format=json --include-text-content=true "json-show-message")\r
78 +test_expect_equal "$output" "[[[{\"id\": \"${gen_msg_id}\", \"match\": true, \"excluded\": false, \"filename\": \"${gen_msg_filename}\", \"timestamp\": 946728000, \"date_relative\": \"2000-01-01\", \"tags\": [\"inbox\",\"unread\"], \"headers\": {\"Subject\": \"json-show-subject\", \"From\": \"Notmuch Test Suite <test_suite@notmuchmail.org>\", \"To\": \"Notmuch Test Suite <test_suite@notmuchmail.org>\", \"Date\": \"Sat, 01 Jan 2000 12:00:00 +0000\"}, \"body\": [{\"id\": 1, \"content-type\": \"text/plain\", \"content\": \"json-show-message\n\"}]}, []]]]"\r
79 +\r
80 +test_begin_subtest "Show message: json --include-text-content=false"\r
81 +output=$(notmuch show --format=json --include-text-content=false "json-show-message")\r
82 +test_expect_equal "$output" "[[[{\"id\": \"${gen_msg_id}\", \"match\": true, \"excluded\": false, \"filename\": \"${gen_msg_filename}\", \"timestamp\": 946728000, \"date_relative\": \"2000-01-01\", \"tags\": [\"inbox\",\"unread\"], \"headers\": {\"Subject\": \"json-show-subject\", \"From\": \"Notmuch Test Suite <test_suite@notmuchmail.org>\", \"To\": \"Notmuch Test Suite <test_suite@notmuchmail.org>\", \"Date\": \"Sat, 01 Jan 2000 12:00:00 +0000\"}, \"body\": [{\"id\": 1, \"content-type\": \"text/plain\"}]}, []]]]"\r
83 +\r
84  test_begin_subtest "Search message: json"\r
85  add_message "[subject]=\"json-search-subject\"" "[date]=\"Sat, 01 Jan 2000 12:00:00 -0000\"" "[body]=\"json-search-message\""\r
86  output=$(notmuch search --format=json "json-search-message" | notmuch_search_sanitize)\r
87 -- \r
88 1.7.9.1\r
89 \r