From 2bb483e58b6f11ca8e9e8e5ac4190a333dd493a0 Mon Sep 17 00:00:00 2001 From: Tomi Ollila Date: Tue, 29 Dec 2015 00:29:19 +0200 Subject: [PATCH] Re: [PATCH] test: Unset ALTERNATE_EDITOR before running emacsclient --- 9e/5b49f013f1a3706e817226803fe696cf499a19 | 93 +++++++++++++++++++++++ 1 file changed, 93 insertions(+) create mode 100644 9e/5b49f013f1a3706e817226803fe696cf499a19 diff --git a/9e/5b49f013f1a3706e817226803fe696cf499a19 b/9e/5b49f013f1a3706e817226803fe696cf499a19 new file mode 100644 index 000000000..0e9b958ab --- /dev/null +++ b/9e/5b49f013f1a3706e817226803fe696cf499a19 @@ -0,0 +1,93 @@ +Return-Path: +X-Original-To: notmuch@notmuchmail.org +Delivered-To: notmuch@notmuchmail.org +Received: from localhost (localhost [127.0.0.1]) + by arlo.cworth.org (Postfix) with ESMTP id E48866DE1772 + for ; Mon, 28 Dec 2015 14:29:05 -0800 (PST) +X-Virus-Scanned: Debian amavisd-new at cworth.org +X-Spam-Flag: NO +X-Spam-Score: 0.686 +X-Spam-Level: +X-Spam-Status: No, score=0.686 tagged_above=-999 required=5 tests=[AWL=0.034, + SPF_NEUTRAL=0.652] 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 RrWdihuCe3qW for ; + Mon, 28 Dec 2015 14:29:03 -0800 (PST) +Received: from guru.guru-group.fi (guru.guru-group.fi [46.183.73.34]) + by arlo.cworth.org (Postfix) with ESMTP id 111B16DE176C + for ; Mon, 28 Dec 2015 14:29:02 -0800 (PST) +Received: from guru.guru-group.fi (localhost [IPv6:::1]) + by guru.guru-group.fi (Postfix) with ESMTP id 3E88E10008E; + Tue, 29 Dec 2015 00:29:20 +0200 (EET) +From: Tomi Ollila +To: Michal Sojka , notmuch@notmuchmail.org +Subject: Re: [PATCH] test: Unset ALTERNATE_EDITOR before running emacsclient +In-Reply-To: <1451337395-14196-1-git-send-email-sojkam1@fel.cvut.cz> +References: <1451337395-14196-1-git-send-email-sojkam1@fel.cvut.cz> +User-Agent: Notmuch/0.21+32~g73439f8 (http://notmuchmail.org) Emacs/24.3.1 + (x86_64-unknown-linux-gnu) +X-Face: HhBM'cA~ +MIME-Version: 1.0 +Content-Type: text/plain +X-BeenThere: notmuch@notmuchmail.org +X-Mailman-Version: 2.1.20 +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: Mon, 28 Dec 2015 22:29:06 -0000 + +On Mon, Dec 28 2015, Michal Sojka wrote: + +> ALTERNATE_EDITOR causes emacsclient to run an alternate editor if the +> emacs server is not ready. This can collide with intended +> functionality in test-lib.sh. +> +> If the ALTERNATE_EDITOR is set but empty, emacsclient runs emacs +> daemon and tries to connect to it. When this happens the emacs run by +> test-lib.sh fails to start the server and the subsequent attempts to +> use the server fail because the daemon started by emacsclient does not +> know about notmuch-test-progn. This leads to test suite failure due to +> time out on any emacs test. +> --- + +Looks good to me -- just that should the unsetting be done in the same +place as (most) other environment variables are handled... in the +region starting from line 64 of that same file. + +Tomi + + +> test/test-lib.sh | 1 + +> 1 file changed, 1 insertion(+) +> +> diff --git a/test/test-lib.sh b/test/test-lib.sh +> index 126911f..0f6a6cf 100644 +> --- a/test/test-lib.sh +> +++ b/test/test-lib.sh +> @@ -1152,6 +1152,7 @@ test_emacs () { +> rm -f OUTPUT +> touch OUTPUT +> +> + unset ALTERNATE_EDITOR +> ${TEST_EMACSCLIENT} --socket-name="$EMACS_SERVER" --eval "(notmuch-test-progn $@)" +> } +> +> -- +> 2.6.4 +> +> _______________________________________________ +> notmuch mailing list +> notmuch@notmuchmail.org +> https://notmuchmail.org/mailman/listinfo/notmuch -- 2.26.2