1 Return-Path: <bremner@tethera.net>
\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 E6571431FBD
\r
6 for <notmuch@notmuchmail.org>; Fri, 1 Nov 2013 17:02:19 -0700 (PDT)
\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org
\r
11 X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none]
\r
13 Received: from olra.theworths.org ([127.0.0.1])
\r
14 by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)
\r
15 with ESMTP id EgXnCqfeTXpN for <notmuch@notmuchmail.org>;
\r
16 Fri, 1 Nov 2013 17:02:15 -0700 (PDT)
\r
17 Received: from yantan.tethera.net (yantan.tethera.net [199.188.72.155])
\r
18 (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits))
\r
19 (No client certificate requested)
\r
20 by olra.theworths.org (Postfix) with ESMTPS id D59DD431FAF
\r
21 for <notmuch@notmuchmail.org>; Fri, 1 Nov 2013 17:02:15 -0700 (PDT)
\r
22 Received: from remotemail by yantan.tethera.net with local (Exim 4.80)
\r
23 (envelope-from <bremner@tethera.net>)
\r
24 id 1VcOfN-0002Oj-Ba; Fri, 01 Nov 2013 21:02:13 -0300
\r
25 Received: (nullmailer pid 24363 invoked by uid 1000); Sat, 02 Nov 2013
\r
27 From: David Bremner <david@tethera.net>
\r
28 To: notmuch@notmuchmail.org
\r
29 Subject: [PATCH] test: fix compact backup / restore test
\r
30 Date: Fri, 1 Nov 2013 21:01:55 -0300
\r
31 Message-Id: <1383350515-24320-1-git-send-email-david@tethera.net>
\r
32 X-Mailer: git-send-email 1.8.4.rc3
\r
33 X-BeenThere: notmuch@notmuchmail.org
\r
34 X-Mailman-Version: 2.1.13
\r
36 List-Id: "Use and development of the notmuch mail system."
\r
37 <notmuch.notmuchmail.org>
\r
38 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,
\r
39 <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>
\r
40 List-Archive: <http://notmuchmail.org/pipermail/notmuch>
\r
41 List-Post: <mailto:notmuch@notmuchmail.org>
\r
42 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>
\r
43 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,
\r
44 <mailto:notmuch-request@notmuchmail.org?subject=subscribe>
\r
45 X-List-Received-Date: Sat, 02 Nov 2013 00:02:20 -0000
\r
47 It was looking in completely the wrong place for the backup and the
\r
48 (test) xapian database. Unfortunately test_begin_subtest hides the
\r
52 I found this bug because
\r
54 id:9ee3f2334a117b0a1b88650f44432423cbe95fd7.1383315568.git.jani@nikula.org
\r
56 did _not_ break any tests. Which was puzzling.
\r
58 test/compact | 7 ++++---
\r
59 1 file changed, 4 insertions(+), 3 deletions(-)
\r
61 diff --git a/test/compact b/test/compact
\r
62 index 5bb5cea..afab537 100755
\r
65 @@ -19,10 +19,11 @@ thread:XXX 2001-01-05 [1/1] Notmuch Test Suite; One (inbox tag1 unread)
\r
66 thread:XXX 2001-01-05 [1/1] Notmuch Test Suite; Two (inbox tag1 tag2 unread)
\r
67 thread:XXX 2001-01-05 [1/1] Notmuch Test Suite; Three (inbox tag3 unread)"
\r
69 -test_begin_subtest "Restoring backup"
\r
70 -rm -Rf ${TEST_TMPDIR}/mail/xapian
\r
71 -mv ${TEST_TMPDIR}/mail/xapian.old ${TEST_TMPDIR}/mail/xapian
\r
72 +test_expect_success 'Restoring Backup' \
\r
73 + 'rm -Rf ${MAIL_DIR}/.notmuch/xapian &&
\r
74 + mv ${MAIL_DIR}/xapian.old ${MAIL_DIR}/.notmuch/xapian'
\r
76 +test_begin_subtest "Checking restored backup"
\r
77 output=$(notmuch search \* | notmuch_search_sanitize)
\r
78 test_expect_equal "$output" "\
\r
79 thread:XXX 2001-01-05 [1/1] Notmuch Test Suite; One (inbox tag1 unread)
\r