From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: =?utf-8?Q?K=C3=A9vin_Le_Gouguec?= Newsgroups: gmane.emacs.devel Subject: Re: master 8d4a8b7dfd0: ; Re-apply accidentally reverted commit Date: Mon, 18 Mar 2024 20:02:06 +0100 Message-ID: <87plvrcqj5.fsf@gmail.com> References: <171071192781.29642.16850908468499185478@vcs2.savannah.gnu.org> <20240317214528.4FA50C1CB35@vcs2.savannah.gnu.org> <87zfuwpapo.fsf@pub.pink> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="15640"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: emacs-devel@gnu.org To: john muhl Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Mon Mar 18 20:03:07 2024 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1rmIGI-0003ok-Us for ged-emacs-devel@m.gmane-mx.org; Mon, 18 Mar 2024 20:03:06 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rmIFR-0004B9-03; Mon, 18 Mar 2024 15:02:13 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rmIFQ-0004An-2t for emacs-devel@gnu.org; Mon, 18 Mar 2024 15:02:12 -0400 Original-Received: from mail-wm1-x330.google.com ([2a00:1450:4864:20::330]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rmIFO-0003R3-HO for emacs-devel@gnu.org; Mon, 18 Mar 2024 15:02:11 -0400 Original-Received: by mail-wm1-x330.google.com with SMTP id 5b1f17b1804b1-4140a259a54so14136175e9.0 for ; Mon, 18 Mar 2024 12:02:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1710788528; x=1711393328; darn=gnu.org; h=mime-version:user-agent:message-id:date:references:in-reply-to :subject:cc:to:from:from:to:cc:subject:date:message-id:reply-to; bh=yvSvjUo9w2vOnq8fFWJVQCINKdYyVOKj02870O174uk=; b=IFNjaq3g6UM9f5zRMo2WlKHh8B5QhK2c2B0tB7v+HOTYum0nRFWFRGGXuqJlrLBIBK yxfuHKPI3gxe3H8vxzzBs2Em6wOP8a8yBpZHZhbfZaDKFBia4jpf/vewsz5mB0T06Y7x 1yKV+u1YIQc0z9eKheNjfe9Y/S9uSqotdMlq3Pvuy66G4G5fObM04YF+n+N62L5V4fOY g86LaZ1HCn6eJWghzWO/XK9AlybcawY2nzkuLzVPyUNV9tcu7a/KmfoyBGC05E+mHZS/ qH4gVasOe/G59S+pj+XqY4pcooons1yDRjIrTF/h7wxPX3Sz+mXZFj7Vl7V2zPzwYe1u OU9A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1710788528; x=1711393328; h=mime-version:user-agent:message-id:date:references:in-reply-to :subject:cc:to:from:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=yvSvjUo9w2vOnq8fFWJVQCINKdYyVOKj02870O174uk=; b=uxORahwZ62a6c+GGuqzUmdlsQ/zpuOT7FEvdBGSDrG6o8aI4m59phDIHCXXDt8ee2B 3sIbtBwsqkJ+tIAJgNbwllw3CFhAwXCHLPn4y741twbPoM2WOKTSe8qBwa5oT64C2ogr v0CTTNGC7oSzdtNrH00MjfTcWfHAZ/xL39jPDUVtfxYjLGSQOfoWJhE5LCYXGIhTxKKu yNk1FGKxcXpoNEnGGJwXxcAm+MIrghU25ZH69AT8Zb36K5Zi0YCXxup4W75dbN/lNjVL 1O+5PMcc0G4cQ2ShlFiXKlIFdUQbJxhQMaWodebWNFqi182Upbg3yhfGXYjFJY+2ZEzY Iu9A== X-Gm-Message-State: AOJu0YzyNjWHyCS4fq2x6Y9F/jTFvOQYxJFHl27HkEtikYa7viGsim6H iN18XzJ9Z72A25/I9AWfRnDhxtKuzQ0jQC1M6/qkCnWqHbRzo+W5GZSOmkd4 X-Google-Smtp-Source: AGHT+IEgo9DcYPo6Jrlakqe+eZRCU9qb5Np2k0lnLsu69v1m1bkyaVnuurfd5jEfAWIq9cC5wog24w== X-Received: by 2002:a05:600c:331e:b0:414:a99:7aa2 with SMTP id q30-20020a05600c331e00b004140a997aa2mr4234378wmp.4.1710788527860; Mon, 18 Mar 2024 12:02:07 -0700 (PDT) Original-Received: from amdahl30 ([2a01:e0a:253:fe0:2ef0:5dff:fed2:7b49]) by smtp.gmail.com with ESMTPSA id h2-20020a05600c350200b00413177c3f1dsm15443798wmq.18.2024.03.18.12.02.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 18 Mar 2024 12:02:07 -0700 (PDT) In-Reply-To: <87zfuwpapo.fsf@pub.pink> (john muhl's message of "Sun, 17 Mar 2024 19:50:20 -0500") Received-SPF: pass client-ip=2a00:1450:4864:20::330; envelope-from=kevin.legouguec@gmail.com; helo=mail-wm1-x330.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:317170 Archived-At: --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable john muhl writes: > The test you added here fails when run by a user that doesn=E2=80=99t have > Git configured. When run by such a user the =E2=80=98git commit -mFirst= =E2=80=99 > command errors which causes the test to fail: > > $ git commit -mFirst > Author identity unknown > > *** Please tell me who you are. I can reproduce the failure running 'EMAIL=3D make test' (since EMAIL is how I let Git know about my email, rather than ~/.gitconfig:user.email). The attached patch lets the test pass; let me know if it looks sensible? I'll install it then. --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=0001-Fix-vc-git-test-when-no-identities-are-configured.patch >From 5b4456728ef7957d5e858d41834adbb7eeab8b35 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?K=C3=A9vin=20Le=20Gouguec?= Date: Mon, 18 Mar 2024 19:47:59 +0100 Subject: [PATCH] Fix vc-git test when no identities are configured Reported by john muhl . * test/lisp/vc/vc-git-tests.el (vc-git-test--with-repo): Set some environment variables (lifted from vc-tests.el) to let 'git commit' compute dummy author and committer identities. --- test/lisp/vc/vc-git-tests.el | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/test/lisp/vc/vc-git-tests.el b/test/lisp/vc/vc-git-tests.el index fd3e8ccd602..bbf0c4277dd 100644 --- a/test/lisp/vc/vc-git-tests.el +++ b/test/lisp/vc/vc-git-tests.el @@ -88,10 +88,17 @@ vc-git-test--with-repo The current directory will be set to the top of that repository; NAME will be bound to that directory's file name. Once BODY exits, the -directory will be deleted." +directory will be deleted. + +Some dummy environment variables will be set for the duration of BODY to +allow 'git commit' to determine identities for authors and committers." (declare (indent 1)) `(ert-with-temp-directory ,name - (let ((default-directory ,name)) + (let ((default-directory ,name) + (process-environment (append '("EMAIL=john@doe.ee" + "GIT_AUTHOR_NAME=A" + "GIT_COMMITTER_NAME=C") + process-environment))) (vc-create-repo 'Git) ,@body))) -- 2.44.0 --=-=-=--