[PATCH v2 10/11] emacs: Add known-broken tests for search tagging races
authorAustin Clements <amdragon@MIT.EDU>
Thu, 24 Oct 2013 15:19:10 +0000 (11:19 +2000)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 17:57:36 +0000 (09:57 -0800)
46/08aff503852bc275c9ae7a39a821075d8c3760 [new file with mode: 0644]

diff --git a/46/08aff503852bc275c9ae7a39a821075d8c3760 b/46/08aff503852bc275c9ae7a39a821075d8c3760
new file mode 100644 (file)
index 0000000..7dd0db0
--- /dev/null
@@ -0,0 +1,118 @@
+Return-Path: <amdragon@mit.edu>\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 B4F1E421179\r
+       for <notmuch@notmuchmail.org>; Thu, 24 Oct 2013 08:20:13 -0700 (PDT)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: -0.7\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=-0.7 tagged_above=-999 required=5\r
+       tests=[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 j9WLKiMzRTSW for <notmuch@notmuchmail.org>;\r
+       Thu, 24 Oct 2013 08:20:11 -0700 (PDT)\r
+Received: from dmz-mailsec-scanner-3.mit.edu (dmz-mailsec-scanner-3.mit.edu\r
+       [18.9.25.14])\r
+       by olra.theworths.org (Postfix) with ESMTP id 2CB30429E5C\r
+       for <notmuch@notmuchmail.org>; Thu, 24 Oct 2013 08:19:31 -0700 (PDT)\r
+X-AuditID: 1209190e-b7f828e0000009cf-ad-52693a82fed4\r
+Received: from mailhub-auth-2.mit.edu ( [18.7.62.36])\r
+       by dmz-mailsec-scanner-3.mit.edu (Symantec Messaging Gateway) with SMTP\r
+       id 23.F8.02511.28A39625; Thu, 24 Oct 2013 11:19:30 -0400 (EDT)\r
+Received: from outgoing.mit.edu (outgoing-auth-1.mit.edu [18.9.28.11])\r
+       by mailhub-auth-2.mit.edu (8.13.8/8.9.2) with ESMTP id r9OFJJft011807; \r
+       Thu, 24 Oct 2013 11:19:20 -0400\r
+Received: from drake.dyndns.org\r
+       (216-15-114-40.c3-0.arl-ubr1.sbo-arl.ma.cable.rcn.com\r
+       [216.15.114.40]) (authenticated bits=0)\r
+       (User authenticated as amdragon@ATHENA.MIT.EDU)\r
+       by outgoing.mit.edu (8.13.8/8.12.4) with ESMTP id r9OFJDiT012925\r
+       (version=TLSv1/SSLv3 cipher=AES256-SHA bits=256 verify=NOT);\r
+       Thu, 24 Oct 2013 11:19:19 -0400\r
+Received: from amthrax by drake.dyndns.org with local (Exim 4.77)\r
+       (envelope-from <amdragon@mit.edu>)\r
+       id 1VZMgq-0006e7-TH; Thu, 24 Oct 2013 11:19:12 -0400\r
+From: Austin Clements <amdragon@MIT.EDU>\r
+To: notmuch@notmuchmail.org\r
+Subject: [PATCH v2 10/11] emacs: Add known-broken tests for search tagging\r
+       races\r
+Date: Thu, 24 Oct 2013 11:19:10 -0400\r
+Message-Id: <1382627951-25252-11-git-send-email-amdragon@mit.edu>\r
+X-Mailer: git-send-email 1.8.4.rc3\r
+In-Reply-To: <1382627951-25252-1-git-send-email-amdragon@mit.edu>\r
+References: <1382627951-25252-1-git-send-email-amdragon@mit.edu>\r
+X-Brightmail-Tracker:\r
+ H4sIAAAAAAAAA+NgFjrKIsWRmVeSWpSXmKPExsUixG6nottklRlksKDB0KJpurPF6rk8Ftdv\r
+       zmR2YPbYOesuu8et+6/ZPZ6tusUcwBzFZZOSmpNZllqkb5fAldH/ehVjwTeeirenAhsY/3N1\r
+       MXJySAiYSFycNY8NwhaTuHBvPZDNxSEksI9RYvuURYwQzkZGiUcTj7BCOHeYJNb190M5cxkl\r
+       Tjy7zQrSzyagIbFt/3JGEFtEQFpi593ZYHFmgWiJI5dngO0QFgiQuHLhDAuIzSKgKtHw5xET\r
+       iM0r4Chx4tc3Fog7lCQWntoG1ssJFP/5+hrYTCEBB4lfv8+wTGDkX8DIsIpRNiW3Sjc3MTOn\r
+       ODVZtzg5MS8vtUjXWC83s0QvNaV0EyMotDgl+XYwfj2odIhRgINRiYdX40N6kBBrYllxZe4h\r
+       RkkOJiVR3nummUFCfEn5KZUZicUZ8UWlOanFhxglOJiVRHin6QHleFMSK6tSi/JhUtIcLEri\r
+       vDc57IOEBNITS1KzU1MLUotgsjIcHEoSvJ2WQI2CRanpqRVpmTklCGkmDk6Q4TxAw9NBaniL\r
+       CxJzizPTIfKnGBWlxHmTQBICIImM0jy4Xljsv2IUB3pFmLccpIoHmDbgul8BDWYCGjxlSRrI\r
+       4JJEhJRUA6PQmZbDD9mrP7Q+VjXeJNu29/Wvy6/duZ5KpSWtsnrqvXlK5rTYJz/ObZ9129hv\r
+       +YdzW96wLw2q2/glLnJZ/rXnM08HK7sLy287KfKpLubjNuaIBXbt597s3yW/6coRd/XJOst8\r
+       3Kec2HZ86uQpb2b/v33xdOWzgx7czrMi0oz8G90273Vna3WzV2Ipzkg01GIuKk4EADUIIw3Y        AgAA\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: Thu, 24 Oct 2013 15:20:14 -0000\r
+\r
+These tests check that both thread-local and global search tagging\r
+operations are race-free.  They are currently known-broken because\r
+they aren't race-free.\r
+---\r
+ test/emacs | 26 ++++++++++++++++++++++++++\r
+ 1 file changed, 26 insertions(+)\r
+\r
+diff --git a/test/emacs b/test/emacs\r
+index 5fbee12..7503e96 100755\r
+--- a/test/emacs\r
++++ b/test/emacs\r
+@@ -922,4 +922,30 @@ This is a warning (see *Notmuch errors* for more details)\r
+ This is a warning\r
+ This is another warning"\r
\r
++test_begin_subtest "Search thread tag operations are race-free"\r
++test_subtest_known_broken\r
++add_message '[subject]="Search race test"'\r
++gen_msg_id_1=$gen_msg_id\r
++generate_message '[in-reply-to]="<'$gen_msg_id_1'>"' \\r
++          '[references]="<'$gen_msg_id_1'>"' \\r
++          '[subject]="Search race test two"'\r
++test_emacs '(notmuch-search "subject:\"search race test\"")\r
++          (notmuch-test-wait)\r
++          (notmuch-poll)\r
++          (execute-kbd-macro "+search-thread-race-tag")'\r
++output=$(notmuch search --output=messages 'tag:search-thread-race-tag')\r
++test_expect_equal "$output" "id:$gen_msg_id_1"\r
++\r
++test_begin_subtest "Search global tag operations are race-free"\r
++test_subtest_known_broken\r
++generate_message '[in-reply-to]="<'$gen_msg_id_1'>"' \\r
++          '[references]="<'$gen_msg_id_1'>"' \\r
++          '[subject]="Re: Search race test"'\r
++test_emacs '(notmuch-search "subject:\"search race test\" -subject:two")\r
++          (notmuch-test-wait)\r
++          (notmuch-poll)\r
++          (execute-kbd-macro "*+search-global-race-tag")'\r
++output=$(notmuch search --output=messages 'tag:search-global-race-tag')\r
++test_expect_equal "$output" "id:$gen_msg_id_1"\r
++\r
+ test_done\r
+-- \r
+1.8.4.rc3\r
+\r