[PATCH 1/2] test: remove "Generate some messages" test from raw
authorDmitry Kurochkin <dmitry.kurochkin@gmail.com>
Mon, 30 Jan 2012 22:06:34 +0000 (02:06 +0400)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 17:43:44 +0000 (09:43 -0800)
66/010591636e1d8605508708caa0cf12ea3bcab7 [new file with mode: 0644]

diff --git a/66/010591636e1d8605508708caa0cf12ea3bcab7 b/66/010591636e1d8605508708caa0cf12ea3bcab7
new file mode 100644 (file)
index 0000000..404c314
--- /dev/null
@@ -0,0 +1,103 @@
+Return-Path: <dmitry.kurochkin@gmail.com>\r
+X-Original-To: notmuch@notmuchmail.org\r
+Delivered-To: notmuch@notmuchmail.org\r
+Received: from localhost (localhost [127.0.0.1])\r
+       by olra.theworths.org (Postfix) with ESMTP id 941AB431E64\r
+       for <notmuch@notmuchmail.org>; Mon, 30 Jan 2012 14:07:49 -0800 (PST)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: -0.799\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=-0.799 tagged_above=-999 required=5\r
+       tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1,\r
+       FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled\r
+Received: from olra.theworths.org ([127.0.0.1])\r
+       by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
+       with ESMTP id bcFJjFIxyPu8 for <notmuch@notmuchmail.org>;\r
+       Mon, 30 Jan 2012 14:07:49 -0800 (PST)\r
+Received: from mail-bk0-f53.google.com (mail-bk0-f53.google.com\r
+       [209.85.214.53]) (using TLSv1 with cipher RC4-SHA (128/128 bits))\r
+       (No client certificate requested)\r
+       by olra.theworths.org (Postfix) with ESMTPS id DA9A6431FBC\r
+       for <notmuch@notmuchmail.org>; Mon, 30 Jan 2012 14:07:48 -0800 (PST)\r
+Received: by bke11 with SMTP id 11so1911694bke.26\r
+       for <notmuch@notmuchmail.org>; Mon, 30 Jan 2012 14:07:47 -0800 (PST)\r
+Received-SPF: pass (google.com: domain of dmitry.kurochkin@gmail.com\r
+       designates 10.204.157.25 as permitted sender)\r
+       client-ip=10.204.157.25; \r
+Authentication-Results: mr.google.com; spf=pass (google.com: domain of\r
+       dmitry.kurochkin@gmail.com designates 10.204.157.25 as\r
+       permitted sender) smtp.mail=dmitry.kurochkin@gmail.com;\r
+       dkim=pass header.i=dmitry.kurochkin@gmail.com\r
+Received: from mr.google.com ([10.204.157.25])\r
+       by 10.204.157.25 with SMTP id z25mr10576111bkw.25.1327961267590\r
+       (num_hops = 1); Mon, 30 Jan 2012 14:07:47 -0800 (PST)\r
+DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma;\r
+       h=from:to:subject:date:message-id:x-mailer;\r
+       bh=sSHzwFaGTzED7MrQFyVNTKWKc4t5LH0H+F8AtuNNCtU=;\r
+       b=oWl0xQtPCSmhTkn7xIKSyk6jbqmRgO7411WimUN2WboxOaX8zzl3DL5OQ9V8q8LzTI\r
+       J1pFXmaXj5QEAREqyc+VTOLgUtw6s6qMLzudQqSF94ODRQWdgvzfc9EMtGu6AjjVfCN6\r
+       6yNYCMt4jABOW49vRJPPD5k/3F58xZ0m6aQK0=\r
+Received: by 10.204.157.25 with SMTP id z25mr9190633bkw.25.1327961267490;\r
+       Mon, 30 Jan 2012 14:07:47 -0800 (PST)\r
+Received: from localhost ([91.144.186.21])\r
+       by mx.google.com with ESMTPS id cg2sm40505272bkb.12.2012.01.30.14.07.46\r
+       (version=TLSv1/SSLv3 cipher=OTHER);\r
+       Mon, 30 Jan 2012 14:07:46 -0800 (PST)\r
+From: Dmitry Kurochkin <dmitry.kurochkin@gmail.com>\r
+To: notmuch@notmuchmail.org\r
+Subject: [PATCH 1/2] test: remove "Generate some messages" test from raw\r
+Date: Tue, 31 Jan 2012 02:06:34 +0400\r
+Message-Id: <1327961195-4204-1-git-send-email-dmitry.kurochkin@gmail.com>\r
+X-Mailer: git-send-email 1.7.8.3\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.13\r
+Precedence: list\r
+List-Id: "Use and development of the notmuch mail system."\r
+       <notmuch.notmuchmail.org>\r
+List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
+List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
+List-Post: <mailto:notmuch@notmuchmail.org>\r
+List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
+List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
+X-List-Received-Date: Mon, 30 Jan 2012 22:07:49 -0000\r
+\r
+Before the change, the first subtest in raw format tests just\r
+generated messages and checked that they are added successfully.  This\r
+is not really a raw format test, it is creating of environment\r
+required for other subtests to run.  The patch removes the first\r
+subtest from raw and replaces it with bare add_message calls, similar\r
+to how it is done in other tests.\r
+\r
+TODO: we should check that test environment was created successfully.\r
+Currently, many tests do add_message(), notmuch new and other calls\r
+without checking the results.  We should come up with a general\r
+solution for this, i.e. if any command during test initialization\r
+fails, all tests should be skipped with appropriate error message.\r
+---\r
+ test/raw |    7 ++-----\r
+ 1 files changed, 2 insertions(+), 5 deletions(-)\r
+\r
+diff --git a/test/raw b/test/raw\r
+index 0171e64..de0b867 100755\r
+--- a/test/raw\r
++++ b/test/raw\r
+@@ -3,11 +3,8 @@\r
+ test_description='notmuch show --format=raw'\r
+ . ./test-lib.sh\r
+ \r
+-test_begin_subtest "Generate some messages"\r
+-generate_message\r
+-generate_message\r
+-output=$(NOTMUCH_NEW)\r
+-test_expect_equal "$output" "Added 2 new messages to the database."\r
++add_message\r
++add_message\r
+ \r
+ test_begin_subtest "Attempt to show multiple raw messages"\r
+ output=$(notmuch show --format=raw "*" 2>&1)\r
+-- \r
+1.7.8.3\r
+\r