[PATCH] RFC: all deleting all properties with a given key
[notmuch-archives.git] / be / 08f090bfd6662a68e142c471c1a53ed1795224
1 Return-Path: <too@guru-group.fi>\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 0F45C431FD9\r
6         for <notmuch@notmuchmail.org>; Fri,  6 Sep 2013 08:05:57 -0700 (PDT)\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
8 X-Spam-Flag: NO\r
9 X-Spam-Score: 0\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none]\r
12         autolearn=disabled\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 6QkJtuRMXNQu for <notmuch@notmuchmail.org>;\r
16         Fri,  6 Sep 2013 08:05:50 -0700 (PDT)\r
17 Received: from guru.guru-group.fi (guru.guru-group.fi [46.183.73.34])\r
18         by olra.theworths.org (Postfix) with ESMTP id 67BAA431FBD\r
19         for <notmuch@notmuchmail.org>; Fri,  6 Sep 2013 08:05:50 -0700 (PDT)\r
20 Received: by guru.guru-group.fi (Postfix, from userid 501)\r
21         id DA55B100063; Fri,  6 Sep 2013 18:05:45 +0300 (EEST)\r
22 From: Tomi Ollila <tomi.ollila@iki.fi>\r
23 To: notmuch@notmuchmail.org\r
24 Subject: [PATCH 1/1] test: exit with nonzero value when not all tests\r
25         completed successfully\r
26 Date: Fri,  6 Sep 2013 18:05:35 +0300\r
27 Message-Id: <1378479935-26312-1-git-send-email-tomi.ollila@iki.fi>\r
28 X-Mailer: git-send-email 1.8.0\r
29 Cc: tomi.ollila@iki.fi\r
30 X-BeenThere: notmuch@notmuchmail.org\r
31 X-Mailman-Version: 2.1.13\r
32 Precedence: list\r
33 List-Id: "Use and development of the notmuch mail system."\r
34         <notmuch.notmuchmail.org>\r
35 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
36         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
37 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
38 List-Post: <mailto:notmuch@notmuchmail.org>\r
39 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
40 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
41         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
42 X-List-Received-Date: Fri, 06 Sep 2013 15:05:57 -0000\r
43 \r
44 If any of the tests in our test system is not passing the execution\r
45 of the test suite completes with nonzero exit value.\r
46 \r
47 It is better to rely on the exit value of the test system instead\r
48 of some arbitrary strings in test output (or use both).\r
49 ---\r
50  test/aggregate-results.sh |    5 +++++\r
51  test/notmuch-test         |    3 +++\r
52  2 files changed, 8 insertions(+)\r
53 \r
54 diff --git a/test/aggregate-results.sh b/test/aggregate-results.sh\r
55 index 732d6ca..5193d7f 100755\r
56 --- a/test/aggregate-results.sh\r
57 +++ b/test/aggregate-results.sh\r
58 @@ -49,10 +49,12 @@ pluralize () {\r
59  }\r
60  \r
61  echo "Notmuch test suite complete."\r
62 +ev=1\r
63  if [ "$fixed" = "0" ] && [ "$failed" = "0" ]; then\r
64      tests=$(pluralize "test" $total)\r
65      printf "All $total $tests "\r
66      if [ "$broken" = "0" ]; then\r
67 +       ev=0\r
68         echo "passed."\r
69      else\r
70         failures=$(pluralize "failure" $broken)\r
71 @@ -76,6 +78,9 @@ fi\r
72  \r
73  skipped=$(($total - $fixed - $success - $failed - $broken))\r
74  if [ "$skipped" != "0" ]; then\r
75 +    ev=1\r
76      tests=$(pluralize "test" $skipped)\r
77      echo "$skipped $tests skipped."\r
78  fi\r
79 +\r
80 +exit $ev\r
81 diff --git a/test/notmuch-test b/test/notmuch-test\r
82 index 6db7979..aa28bb0 100755\r
83 --- a/test/notmuch-test\r
84 +++ b/test/notmuch-test\r
85 @@ -97,6 +97,9 @@ trap - HUP INT TERM\r
86  \r
87  # Report results\r
88  ./aggregate-results.sh test-results/*\r
89 +ev=$?\r
90  \r
91  # Clean up\r
92  rm -rf test-results corpus.mail\r
93 +\r
94 +exit $ev\r
95 -- \r
96 1.7.10.4\r
97 \r