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 C59536DE20BE for ; Sun, 26 Feb 2017 05:43:23 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at cworth.org X-Amavis-Alert: BAD HEADER SECTION, Duplicate header field: "References" X-Spam-Flag: NO X-Spam-Score: -0.18 X-Spam-Level: X-Spam-Status: No, score=-0.18 tagged_above=-999 required=5 tests=[AWL=-0.160, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, 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 wVXmgulJJohC for ; Sun, 26 Feb 2017 05:43:22 -0800 (PST) Received: from mail-lf0-f52.google.com (mail-lf0-f52.google.com [209.85.215.52]) by arlo.cworth.org (Postfix) with ESMTPS id 38AE66DE20A2 for ; Sun, 26 Feb 2017 05:43:22 -0800 (PST) Received: by mail-lf0-f52.google.com with SMTP id a6so1232075lfa.0 for ; Sun, 26 Feb 2017 05:43:22 -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:date:message-id:in-reply-to:references :in-reply-to:references; bh=FxZHzykuOQ74ldvOw/CYySZBXho/ZM7QEJxcMF0PxRI=; b=CTLNdSlHnWgV5S+WJLYIP2wI+5nWvXoR/mL16SPsBgNWspBqTiBxkORJm6fAsSMk7n B4DwAVphZwEwdzboD9dN9c1a1TnakanLvRqv4BNHscKyTKQDyw/3U1+ImkHcAq8NTHze U4aWmCYZoiZLncXnImZw2RItTActVsYcFmq/Q3lwZOeoWT9eYLpU+iwuICxtXjeLidCP CBMtPjgjetlURZ3vo+A5YF5DaNOQmChywfV/EBfQpYK5Sg6gkwKOH0EBn5Ee2boX+DM4 g03IXY0d1R6hmBVVX6aYAH3NlruQDsSs8jejZEbdVwKQn6VYi3xkVPNItMwUygccZu55 /yZA== 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:date:message-id:in-reply-to :references:in-reply-to:references; bh=FxZHzykuOQ74ldvOw/CYySZBXho/ZM7QEJxcMF0PxRI=; b=GZTF1LJY1/aytTqNalhekEVWxOxWiEv7xu/Zl+9QdJiT5yIoxU05rxuqryiq6ccoek 7X6uIYpa0zSP6nGMq6h+JX2Bi4XbNKyLvaUL1IhTy0i2Y6o8Itt9A8+yzPUfuj5Hs22x OKlb1OPyvH28pZNcj+iIwpCnaMrs1BaTuqnwCrcslSuEXp9IZRJRSMpaGW+ayOxUttHO EbcMhFaHoroGPTyPQBT9OKKM0eE+yR/3c7RNAij4crgbtfHo0BAga5WjK6rq/QWgf0fp F89R4CkJzw+pF7z/s99r5jhbSNz5M0rHQ9WDzi5q6NFT1yV0RbyG1nNRvbhNNOwsX/xP o2SQ== X-Gm-Message-State: AMke39l3qjf0mtSY1oAmXtzQi+0F+ijP2jAPPqaHUZABMB1UYRdUDfq2YMnwBeWMVYMXAw== X-Received: by 10.46.71.69 with SMTP id u66mr1369917lja.99.1488116600391; Sun, 26 Feb 2017 05:43:20 -0800 (PST) Received: from localhost (mobile-access-bcee80-14.dhcp.inet.fi. [188.238.128.14]) by smtp.gmail.com with ESMTPSA id q186sm3585141ljb.18.2017.02.26.05.43.19 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Sun, 26 Feb 2017 05:43:19 -0800 (PST) From: Jani Nikula To: notmuch@notmuchmail.org Subject: [PATCH 3/9] test: remove unused test_external and test_external_without_stderr Date: Sun, 26 Feb 2017 15:42:55 +0200 Message-Id: <151d381216d7befdb973743ff3f62cc12fe82cc8.1488116461.git.jani@nikula.org> X-Mailer: git-send-email 2.11.0 In-Reply-To: References: In-Reply-To: References: 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: Sun, 26 Feb 2017 13:43:23 -0000 They've been unused since their introduction in commit 0083854b1204 ("Copy test framework from Git"), only causing maintenance burden. --- test/test-lib.sh | 59 -------------------------------------------------------- 1 file changed, 59 deletions(-) diff --git a/test/test-lib.sh b/test/test-lib.sh index 2ccb62eec122..218a06527f88 100644 --- a/test/test-lib.sh +++ b/test/test-lib.sh @@ -963,65 +963,6 @@ test_expect_code () { fi } -# test_external runs external test scripts that provide continuous -# test output about their progress, and succeeds/fails on -# zero/non-zero exit code. It outputs the test output on stdout even -# in non-verbose mode, and announces the external script with "* run -# : ..." before running it. When providing relative paths, keep in -# mind that all scripts run in "trash directory". -# Usage: test_external description command arguments... -# Example: test_external 'Perl API' perl ../path/to/test.pl -test_external () { - test "$#" = 4 && { prereq=$1; shift; } || prereq= - test "$#" = 3 || - error >&6 "bug in the test script: not 3 or 4 parameters to test_external" - test_subtest_name="$1" - shift - test_reset_state_ - if ! test_skip "$test_subtest_name" "$@" - then - # Announce the script to reduce confusion about the - # test output that follows. - say_color "" " run $test_count: $descr ($*)" - # Run command; redirect its stderr to &4 as in - # test_run_, but keep its stdout on our stdout even in - # non-verbose mode. - "$@" 2>&4 - if [ "$?" = 0 ] - then - test_ok_ - else - test_failure_ "$@" - fi - fi -} - -# Like test_external, but in addition tests that the command generated -# no output on stderr. -test_external_without_stderr () { - # The temporary file has no (and must have no) security - # implications. - tmp="$TMPDIR"; if [ -z "$tmp" ]; then tmp=/tmp; fi - stderr="$tmp/git-external-stderr.$$.tmp" - test_external "$@" 4> "$stderr" - [ -f "$stderr" ] || error "Internal error: $stderr disappeared." - test_subtest_name="no stderr: $1" - shift - if [ ! -s "$stderr" ]; then - rm "$stderr" - test_ok_ - else - if [ "$verbose" = t ]; then - output=`echo; echo Stderr is:; cat "$stderr"` - else - output= - fi - # rm first in case test_failure exits. - rm "$stderr" - test_failure_ "$@" "$output" - fi -} - # This is not among top-level (test_expect_success) # but is a prefix that can be used in the test script, like: # -- 2.11.0