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 13B646DE1512 for ; Tue, 14 Feb 2017 14:14:25 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at cworth.org X-Spam-Flag: NO X-Spam-Score: 0.001 X-Spam-Level: X-Spam-Status: No, score=0.001 tagged_above=-999 required=5 tests=[AWL=0.000, HEADER_FROM_DIFFERENT_DOMAINS=0.001] 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 P7zUHdSmvzxy for ; Tue, 14 Feb 2017 14:14:24 -0800 (PST) Received: from fethera.tethera.net (fethera.tethera.net [198.245.60.197]) by arlo.cworth.org (Postfix) with ESMTPS id 744CE6DE1579 for ; Tue, 14 Feb 2017 14:14:24 -0800 (PST) Received: from remotemail by fethera.tethera.net with local (Exim 4.84_2) (envelope-from ) id 1cdkrr-0006ur-IM; Tue, 14 Feb 2017 16:42:35 -0500 Received: (nullmailer pid 9793 invoked by uid 1000); Tue, 14 Feb 2017 21:43:05 -0000 From: David Bremner To: notmuch@notmuchmail.org Cc: aidecode@aidecode.name, David Bremner Subject: [PATCH 2/2] test: use gpgconf --create-socketdir if available Date: Tue, 14 Feb 2017 16:42:39 -0500 Message-Id: <20170214214239.9330-3-david@tethera.net> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170214214239.9330-1-david@tethera.net> References: <20170214214239.9330-1-david@tethera.net> 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: Tue, 14 Feb 2017 22:14:25 -0000 This enables the shortened socket pathes in /run or equivalent. The explicit call to gpgconf is needed for nonstandard GNUPGHOME settings. --- test/test-lib.sh | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/test/test-lib.sh b/test/test-lib.sh index 86e792a8..9aa6163b 100644 --- a/test/test-lib.sh +++ b/test/test-lib.sh @@ -229,9 +229,18 @@ test_fixed=0 test_broken=0 test_success=0 + +_shutdown_gpg_agent () { + if [ ${NOTMUCH_HAVE_GPGCONF_SOCKETDIR} == 1 ]; then + gpgconf --kill gpg-agent + gpgconf --remove-socketdir + fi +} + _exit_common () { code=$? trap - EXIT + _shutdown_gpg_agent set +ex rm -rf "$TEST_TMPDIR" } @@ -1276,6 +1285,11 @@ test_init_ () { . ./test-lib-common.sh || exit 1 +# we need the setting of GNUPGHOME in test-lib-common.sh +if [ ${NOTMUCH_HAVE_GPGCONF_SOCKETDIR} == 1 ]; then + gpgconf --create-socketdir +fi + emacs_generate_script -- 2.11.0