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 5DD0C6DE0AE5 for ; Wed, 18 Jan 2017 10:00:33 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at cworth.org X-Spam-Flag: NO X-Spam-Score: 0.183 X-Spam-Level: X-Spam-Status: No, score=0.183 tagged_above=-999 required=5 tests=[AWL=0.203, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-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 UnoTKaSF11Nf for ; Wed, 18 Jan 2017 10:00:32 -0800 (PST) Received: from mail-lf0-f68.google.com (mail-lf0-f68.google.com [209.85.215.68]) by arlo.cworth.org (Postfix) with ESMTPS id 5F2806DE00BD for ; Wed, 18 Jan 2017 10:00:32 -0800 (PST) Received: by mail-lf0-f68.google.com with SMTP id x1so2845385lff.0 for ; Wed, 18 Jan 2017 10:00:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nikula-org.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:in-reply-to:references:date:message-id :mime-version; bh=s+UofvdvrEuHTs/FuxKGO5vBL7Vz8hRcF+a6DYiFTic=; b=qvBVpGuHRaLm/WDvn2QjIm1Vg1KvJxotXegPZM+fa+6k0nPgg8IUIyWpM/Wr9H4wKs jrx8hpvNvERPgJj5uqzcAzMqhTCYiwqZBLt8ztWqVbeIL8Po0Vy9nlQFzF6wK0PKs3fL APAG7j1SE5N6CoKeyo88nR5fPBnHUamduiCS93yHPFRWr4TJLddB6G5Rd9CV/S497CV5 dGIEDXut0fxmNhvgY7/7JXL7q87YCtBWGzRlNd5/ksroaCQml8XbTPGmUmtRL3QxQ4X+ D2rU0jUSdrvsH1sYOtKE7UBC+JlkWCvg+O35fE9++SAyEcrJPugzEXHoOOGO2WS6GdBb d/Cg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:in-reply-to:references:date :message-id:mime-version; bh=s+UofvdvrEuHTs/FuxKGO5vBL7Vz8hRcF+a6DYiFTic=; b=cfBiG0J2w9o6HaThWVzg9CQdb8MlqvU7efGZO708qCe5cdQFEpLUroPW4gPZLHLTHn ZXNIQgCrPmgG2UFLLpZk4Rhq6fV/tzjGS16+ohdaDbMMUWn4lnytv8lYyb/rzTFfmGlo 8EaJ9jon/1FD27p7UDTpjvgBC1IjimR18HaaBSCvRZjK4KS946EG/1E/QxcvgZfQpgJw n+qkpod8TTJAeJnUgdO+x551lFLnb/j/+x1ZNNOUcB3PwUCM384qftEcaWHf4LoaSiBo Ut+eaoTGZT9mAKJEB6/mR4e4pKaT3K45qnliCjuXtuI9SrZYQ7QHdT6L3x9EVfQVH60X JYFg== X-Gm-Message-State: AIkVDXJ2RMc55qXUzp6oqICcd2OofxZV5yuwEYwAfJA1r66kRtRpvWwTx5sF5YYGvcpgeA== X-Received: by 10.25.205.77 with SMTP id d74mr1757052lfg.122.1484762430248; Wed, 18 Jan 2017 10:00:30 -0800 (PST) Received: from localhost (mobile-access-5d6a3e-39.dhcp.inet.fi. [93.106.62.39]) by smtp.gmail.com with ESMTPSA id h3sm654572lfj.0.2017.01.18.10.00.28 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 18 Jan 2017 10:00:29 -0800 (PST) From: Jani Nikula To: Tomi Ollila , notmuch@notmuchmail.org Cc: tomi.ollila@iki.fi Subject: Re: [PATCH] test: wrap 'wc -l' results in arithmetic evaluation to strip whitespace In-Reply-To: <1483569323-956-1-git-send-email-tomi.ollila@iki.fi> References: <1483569323-956-1-git-send-email-tomi.ollila@iki.fi> Date: Wed, 18 Jan 2017 20:00:25 +0200 Message-ID: <87a8aockp2.fsf@nikula.org> MIME-Version: 1.0 Content-Type: text/plain 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: Wed, 18 Jan 2017 18:00:33 -0000 On Thu, 05 Jan 2017, Tomi Ollila wrote: > Some new unwrapped 'wc -l's have been added since Jani's 60e79e3a9f1c8 LGTM > --- > > test/T070-insert.sh | 2 +- > test/T580-thread-search.sh | 2 +- > 2 files changed, 2 insertions(+), 2 deletions(-) > > diff --git a/test/T070-insert.sh b/test/T070-insert.sh > index 57472b913964..7fb3b87e4584 100755 > --- a/test/T070-insert.sh > +++ b/test/T070-insert.sh > @@ -60,7 +60,7 @@ test_expect_equal_json "$output" "$expected" > > test_begin_subtest "Insert duplicate message" > notmuch insert +duptag -unread < "$gen_msg_filename" > -output=$(notmuch search --output=files "subject:insert-subject" | wc -l) > +output=$((`notmuch search --output=files "subject:insert-subject" | wc -l`)) > test_expect_equal "$output" 2 > > test_begin_subtest "Duplicate message does not change tags" > diff --git a/test/T580-thread-search.sh b/test/T580-thread-search.sh > index 6f7106db475a..512559a3aff9 100755 > --- a/test/T580-thread-search.sh > +++ b/test/T580-thread-search.sh > @@ -15,7 +15,7 @@ count=0 > success=0 > for id in $(notmuch search --output=messages '*'); do > count=$((count +1)) > - matches=$(notmuch search --output=threads "$id" | wc -l) > + matches=$((`notmuch search --output=threads "$id" | wc -l`)) > if [ "$matches" = 1 ]; then > success=$((success + 1)) > fi > -- > 2.8.2 > > _______________________________________________ > notmuch mailing list > notmuch@notmuchmail.org > https://notmuchmail.org/mailman/listinfo/notmuch