1 Return-Path: <tomi.ollila@iki.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 A224C431FBC
\r
6 for <notmuch@notmuchmail.org>; Wed, 13 Nov 2013 00:37:02 -0800 (PST)
\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 uXrxqhfSkeYL for <notmuch@notmuchmail.org>;
\r
16 Wed, 13 Nov 2013 00:36:57 -0800 (PST)
\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 BA489431FB6
\r
19 for <notmuch@notmuchmail.org>; Wed, 13 Nov 2013 00:36:57 -0800 (PST)
\r
20 Received: from guru.guru-group.fi (localhost [IPv6:::1])
\r
21 by guru.guru-group.fi (Postfix) with ESMTP id B61A1100033;
\r
22 Wed, 13 Nov 2013 10:36:49 +0200 (EET)
\r
23 From: Tomi Ollila <tomi.ollila@iki.fi>
\r
24 To: Austin Clements <amdragon@MIT.EDU>
\r
25 Subject: Re: [PATCH 3/3] test: implement and document NOTMUCH_TEST_QUIET
\r
27 In-Reply-To: <20131112230259.GD13399@mit.edu>
\r
28 References: <1384288868-23903-1-git-send-email-tomi.ollila@iki.fi>
\r
29 <1384288868-23903-3-git-send-email-tomi.ollila@iki.fi>
\r
30 <20131112230259.GD13399@mit.edu>
\r
31 User-Agent: Notmuch/0.16+119~g219c55f (http://notmuchmail.org) Emacs/24.3.1
\r
32 (x86_64-unknown-linux-gnu)
\r
33 X-Face: HhBM'cA~<r"^Xv\KRN0P{vn'Y"Kd;zg_y3S[4)KSN~s?O\"QPoL
\r
34 $[Xv_BD:i/F$WiEWax}R(MPS`^UaptOGD`*/=@\1lKoVa9tnrg0TW?"r7aRtgk[F
\r
35 !)g;OY^,BjTbr)Np:%c_o'jj,Z
\r
36 Date: Wed, 13 Nov 2013 10:36:49 +0200
\r
37 Message-ID: <m2iovwofz2.fsf@guru.guru-group.fi>
\r
39 Content-Type: text/plain
\r
40 Cc: notmuch@notmuchmail.org
\r
41 X-BeenThere: notmuch@notmuchmail.org
\r
42 X-Mailman-Version: 2.1.13
\r
44 List-Id: "Use and development of the notmuch mail system."
\r
45 <notmuch.notmuchmail.org>
\r
46 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,
\r
47 <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>
\r
48 List-Archive: <http://notmuchmail.org/pipermail/notmuch>
\r
49 List-Post: <mailto:notmuch@notmuchmail.org>
\r
50 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>
\r
51 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,
\r
52 <mailto:notmuch-request@notmuchmail.org?subject=subscribe>
\r
53 X-List-Received-Date: Wed, 13 Nov 2013 08:37:02 -0000
\r
55 On Wed, Nov 13 2013, Austin Clements <amdragon@MIT.EDU> wrote:
\r
57 > Quoth Tomi Ollila on Nov 12 at 10:41 pm:
\r
60 >> test_success=$(($test_success + 1))
\r
61 >> + if test -n "$NOTMUCH_TEST_QUIET"; then
\r
64 >> say_color pass "%-6s" "PASS"
\r
65 >> echo " $test_subtest_name"
\r
67 >> @@ -713,6 +719,9 @@ test_failure_ () {
\r
70 >> test_failure=$(($test_failure + 1))
\r
71 >> + if test -n "$NOTMUCH_TEST_QUIET"; then
\r
72 >> + print_test_description
\r
74 > This prints the test description for *every* failing test. Was that
\r
75 > intentional? I would think that, ideally, it would be only printed
\r
76 > before the first failing subtest in a test (maybe by setting a
\r
77 > variable in print_test_description on the first call and making it
\r
78 > return immediately if this variable is set? Then you wouldn't even
\r
79 > need the condition here, just the call to print_test_description.)
\r
81 Your observation is correct.. I thought about it but dropped -- but
\r
82 as it *increases* the output it should be addressed. My first solution
\r
85 print_test_description ()
\r
88 echo $this_test: "Testing ${test_description}"
\r
89 print_test_description () { : already printed ; }
\r
92 But I presume this receives some resistance from the audience ;/
\r
94 I think this a bit -- this is post 0.17 release stuff anyway...
\r
98 >> test_failure_message_ "FAIL" "$test_subtest_name" "$@"
\r
99 >> test "$immediate" = "" || { GIT_EXIT_OK=t; exit 1; }
\r
102 > Stylistic nit: The three if's above use two different styles ([ vs
\r
103 > test and hanging 'then'). OTOH, maybe this is consistent with
\r
104 > test-lib's inconsistent style.
\r
106 It is consistent with test-lib's inconsistent style: most often if []
\r
107 is used but those places where I used if test just a line before
\r
108 the diff context there were if test -format used.
\r