From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from localhost (localhost [127.0.0.1]) by arlo.cworth.org (Postfix) with ESMTP id 9B1F16DE1322 for ; Mon, 5 Sep 2016 08:48:19 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at cworth.org X-Spam-Flag: NO X-Spam-Score: -0.007 X-Spam-Level: X-Spam-Status: No, score=-0.007 tagged_above=-999 required=5 tests=[AWL=0.004, SPF_PASS=-0.001, T_RP_MATCHES_RCVD=-0.01] autolearn=disabled Received: from arlo.cworth.org ([127.0.0.1]) by localhost (arlo.cworth.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id zrsVGcqTRA84 for ; Mon, 5 Sep 2016 08:48:16 -0700 (PDT) Received: from fethera.tethera.net (fethera.tethera.net [198.245.60.197]) by arlo.cworth.org (Postfix) with ESMTPS id 0D9026DE12C0 for ; Mon, 5 Sep 2016 08:48:16 -0700 (PDT) Received: from remotemail by fethera.tethera.net with local (Exim 4.84_2) (envelope-from ) id 1bgw81-0001c3-QJ; Mon, 05 Sep 2016 11:48:09 -0400 Received: (nullmailer pid 24443 invoked by uid 1000); Mon, 05 Sep 2016 15:48:12 -0000 From: David Bremner To: notmuch@notmuchmail.org Subject: [PATCH 3/5] test: add known broken test for nondestructiveness of count Date: Mon, 5 Sep 2016 12:48:04 -0300 Message-Id: <20160905154806.4570-4-david@tethera.net> X-Mailer: git-send-email 2.9.3 In-Reply-To: <20160905154806.4570-1-david@tethera.net> References: <20160905154806.4570-1-david@tethera.net> X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 05 Sep 2016 15:48:19 -0000 Thanks to Lucas (id:147263183913.27784.12274024193186585889@mbp) for the bug report and the test case. I decided to use the python version because the python bindings could use more exercise. --- test/T060-count.sh | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/test/T060-count.sh b/test/T060-count.sh index d6933a7..69ab591 100755 --- a/test/T060-count.sh +++ b/test/T060-count.sh @@ -126,4 +126,32 @@ sed 's/^\(A Xapian exception [^:]*\):.*$/\1/' < OUTPUT > OUTPUT.clean test_expect_equal_file EXPECTED OUTPUT.clean restore_database +test_begin_subtest "count library function is non-destructive" +test_subtest_known_broken +cat< EXPECTED +1: 52 messages +2: 52 messages +Exclude 'spam' +3: 52 messages +4: 52 messages +EOF +test_python <