From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id wCQiMEw112DoGQAAgWs5BA (envelope-from ) for ; Sat, 26 Jun 2021 16:10:20 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id OAL+K0w112DEMgAA1q6Kng (envelope-from ) for ; Sat, 26 Jun 2021 14:10:20 +0000 Received: from mail.notmuchmail.org (nmbug.tethera.net [144.217.243.247]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 347111963A for ; Sat, 26 Jun 2021 16:10:20 +0200 (CEST) Received: from nmbug.tethera.net (localhost [127.0.0.1]) by mail.notmuchmail.org (Postfix) with ESMTP id C76DA29052; Sat, 26 Jun 2021 10:10:16 -0400 (EDT) Received: from fethera.tethera.net (fethera.tethera.net [IPv6:2607:5300:60:c5::1]) by mail.notmuchmail.org (Postfix) with ESMTP id 1436229033 for ; Sat, 26 Jun 2021 10:10:15 -0400 (EDT) Received: by fethera.tethera.net (Postfix, from userid 1001) id C0B8B5FD21; Sat, 26 Jun 2021 10:10:14 -0400 (EDT) Received: (nullmailer pid 175708 invoked by uid 1000); Sat, 26 Jun 2021 14:10:13 -0000 From: David Bremner To: Tomi Ollila , notmuch@notmuchmail.org Subject: Re: [PATCH 1/2] test-lib-emacs: re-define test_emacs() after initialization In-Reply-To: <20210522152008.27059-1-tomi.ollila@iki.fi> References: <20210522152008.27059-1-tomi.ollila@iki.fi> Date: Sat, 26 Jun 2021 11:10:13 -0300 Message-ID: <87a6nczph6.fsf@tethera.net> MIME-Version: 1.0 Message-ID-Hash: GCWNPEHBLSHXA54TCTGMLEPYZZIKGMFG X-Message-ID-Hash: GCWNPEHBLSHXA54TCTGMLEPYZZIKGMFG X-MailFrom: david@tethera.net X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-notmuch.notmuchmail.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; suspicious-header CC: tomi.ollila@iki.fi X-Mailman-Version: 3.2.1 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Help: List-Post: List-Subscribe: List-Unsubscribe: Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1624716620; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=cd6iKD3/sqD29tySMeuyHjIfPi/QUu0Gfj0a45aeoSg=; b=IGQ/nOvaf/UrUHvVJCiQTymcgc+bWifiBQe5tdhXMIPoJtF3TMMG8A9pxBVG1cGxPyUfpj MeJo36VOHPXrnRT79Blx0wzUdCAXAbySBL6PZaAhg7WbG6cycZ2En0bZLTYRdQU22AWgYz KjRJNUsXp/awu+JqL6WyZmfJsSIQ4qVU9+Kx9LzX0BD6aDhWaDEb8tbK1uTTLHLpk3pa8i +x8NJm3/pjkIokiy5d6BnztaPRMbvydXRLQ3K6SAF2JPOtILvJOl33KxenVghJIlEE3msD /CGMSTs5VUNimv4GvQsTD8tGS/iem4fDiItjXNzK/TOCgLN5d/pV81uluJXu7g== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1624716620; a=rsa-sha256; cv=none; b=Y7BLWpXnlGpKCdkzIQqC+8CaaI3tqz/N2zhgHFaoCfcV4ohh8gwDoju0PMaM6mYXrjzuUV 96XB6zEoJ5C+3pDt6BkaZDHKluoGcHSaNiEnBqqKVh5U4qZG/b/oOP4x7+hr7b8i+Mmgp8 A5Zqw+NNfGu58Nj3xrOJR9FTUrR91zvno30lNjvcS3A6H9o7CFcr697IxmCd7kQBBntzw0 8Rk7QwP9001I4JkBS7ODU2cwLooTaaetBdvFS+uqlqmLQTqdq/oPl1Q4f87nzLlbrUkZK3 +VNqmTiKYBoIvc4V4XulaAO8I4SK1SljAxKRQGJMtf0JKbziiZ9uAJerd2ZWcg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of notmuch-bounces@notmuchmail.org designates 144.217.243.247 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Migadu-Spam-Score: -2.06 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of notmuch-bounces@notmuchmail.org designates 144.217.243.247 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Migadu-Queue-Id: 347111963A X-Spam-Score: -2.06 X-Migadu-Scanner: scn0.migadu.com X-TUID: vYflhYPnQnxl Tomi Ollila writes: > After test_emacs() has started emacs, it re-defines > itself as just calling the started emacs. > > First call to test_emacs() will execute to the end of it; > next calls will just execute the 2 lines, first clearing OUTPUT, > second and last executing TEST_EMACSCLIENT... > > This simplifies away one if constructs and reduces xtrace > output when doing test debugging with set -x. I was thinking about this, and wouldn't factoring out the first run stuff into a separate function be almost as good for debugging with set -x? d