list mirror (unofficial, one of many)
 help / color / mirror / code / Atom feed
From: "Johannes Schindelin via GitGitGadget" <>
Cc: Johannes Schindelin <>,
	Johannes Schindelin <>
Subject: [PATCH 3/3] t2106: ensure that the checkout fails for the expected reason
Date: Wed, 18 Nov 2020 14:49:07 +0000	[thread overview]
Message-ID: <> (raw)
In-Reply-To: <>

From: Johannes Schindelin <>

During the transition of the test suite to a new default branch name, it
was noticed that this test case succeeded for the wrong reason when the
default branch name was overridden.

While we fixed that in the previous commit, let's make sure that we look
for a tell-tale in the error message that the `git checkout` failed for
the reason we wanted it to fail.

Signed-off-by: Johannes Schindelin <>
 t/ | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/t/ b/t/
index 3396f23363..2d450daf5c 100755
--- a/t/
+++ b/t/
@@ -20,7 +20,8 @@ test_expect_success 'do not switch branches with dirty file' '
 	git checkout other &&
 	echo dirt >file &&
 	git update-index --assume-unchanged file &&
-	test_must_fail git checkout -
+	test_must_fail git checkout - 2>err &&
+	test_i18ngrep overwritten err

  parent reply	other threads:[~2020-11-18 14:50 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-18 14:49 [PATCH 0/3] t2106 vs. the default branch name Johannes Schindelin via GitGitGadget
2020-11-18 14:49 ` [PATCH 1/3] t2106: adjust style to the current conventions Johannes Schindelin via GitGitGadget
2020-11-18 14:49 ` [PATCH 2/3] t2106: make test independent of the current main branch name Johannes Schindelin via GitGitGadget
2020-11-18 18:26   ` Junio C Hamano
2020-11-18 14:49 ` Johannes Schindelin via GitGitGadget [this message]
2020-11-18 20:46 ` [PATCH 0/3] t2106 vs. the default " Junio C Hamano
2020-11-18 20:56   ` Johannes Schindelin
2020-11-18 21:53     ` Junio C Hamano
2020-11-18 22:25       ` Johannes Schindelin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:

  List information:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \ \ \ \ \
    --subject='Re: [PATCH 3/3] t2106: ensure that the checkout fails for the expected reason' \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

Code repositories for project(s) associated with this inbox:

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).