[PATCH v2 1/2] test: remove "Generate some messages" test from raw
authorDmitry Kurochkin <dmitry.kurochkin@gmail.com>
Sat, 10 Mar 2012 01:24:50 +0000 (05:24 +0400)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 17:45:22 +0000 (09:45 -0800)
c6/532a97e39b78816ac59abb889a28f5171c092f [new file with mode: 0644]

diff --git a/c6/532a97e39b78816ac59abb889a28f5171c092f b/c6/532a97e39b78816ac59abb889a28f5171c092f
new file mode 100644 (file)
index 0000000..dee6edb
--- /dev/null
@@ -0,0 +1,99 @@
+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 C46A1431FC3\r
+       for <notmuch@notmuchmail.org>; Fri,  9 Mar 2012 17:26:32 -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 zjD6JEPxNir5 for <notmuch@notmuchmail.org>;\r
+       Fri,  9 Mar 2012 17:26:32 -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 232C6431FBC\r
+       for <notmuch@notmuchmail.org>; Fri,  9 Mar 2012 17:26:32 -0800 (PST)\r
+Received: by bkwj4 with SMTP id j4so1791450bkw.26\r
+       for <notmuch@notmuchmail.org>; Fri, 09 Mar 2012 17:26:30 -0800 (PST)\r
+DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113;\r
+       h=from:to:subject:date:message-id:x-mailer:in-reply-to:references;\r
+       bh=hY3rBCqQooueK7mqUgA0UDlErn9H/dO2MM/yrDX4Sh4=;\r
+       b=IIt056a6wMuDtd53+DhqLuZfHy7DVefsqhmcDGlMqnmTx3a06NZgqWl44orKFZitXg\r
+       UyRA01f9MrmAs9thoMLJqkU8puPCHYji5aLX1AyqjZxp3tu4AtvfOYiFbFAh0voMeJ0S\r
+       KbZ5xHiX+rTOjyWJ/Ee63qBFvJ/zxDCvScw+2IOECm72rwForepfjRmuI4WvtR4ySk+1\r
+       A58sUle51jBZspqyQTBRWNLFIG0UBqH1xOMk+iGh1/nmVfscWAV9xBdrtUOS/kwpFsSW\r
+       S2qKrtJbrKD47YkhvhvbiM4/iobWZkye9vwUxNki/rdEqNJKuBsfgqnL+y87W6nsmqLX\r
+       w+/w==\r
+Received: by 10.204.156.12 with SMTP id u12mr1804622bkw.33.1331342790707;\r
+       Fri, 09 Mar 2012 17:26:30 -0800 (PST)\r
+Received: from localhost ([91.144.186.21])\r
+       by mx.google.com with ESMTPS id jw10sm137654bkb.10.2012.03.09.17.26.29\r
+       (version=TLSv1/SSLv3 cipher=OTHER);\r
+       Fri, 09 Mar 2012 17:26:29 -0800 (PST)\r
+From: Dmitry Kurochkin <dmitry.kurochkin@gmail.com>\r
+To: notmuch@notmuchmail.org\r
+Subject: [PATCH v2 1/2] test: remove "Generate some messages" test from raw\r
+Date: Sat, 10 Mar 2012 05:24:50 +0400\r
+Message-Id: <1331342691-26899-2-git-send-email-dmitry.kurochkin@gmail.com>\r
+X-Mailer: git-send-email 1.7.9.1\r
+In-Reply-To: <1331342691-26899-1-git-send-email-dmitry.kurochkin@gmail.com>\r
+References: <1327961195-4204-1-git-send-email-dmitry.kurochkin@gmail.com>\r
+       <1331342691-26899-1-git-send-email-dmitry.kurochkin@gmail.com>\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: Sat, 10 Mar 2012 01:26:32 -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.9.1\r
+\r