[PATCH v3 04/22] t5601: read HEAD using rev-parse
From: Han-Wen Nienhuys via GitGitGadget <hidden>
Date: 2021-05-31 17:39:40
Subsystem:
the rest · Maintainer:
Linus Torvalds
From: Han-Wen Nienhuys via GitGitGadget <hidden>
Date: 2021-05-31 17:39:40
Subsystem:
the rest · Maintainer:
Linus Torvalds
From: Han-Wen Nienhuys <redacted> Signed-off-by: Han-Wen Nienhuys <redacted> Reviewed-by: Ævar Arnfjörð Bjarmason <redacted> --- t/t5601-clone.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/t/t5601-clone.sh b/t/t5601-clone.sh
index c0688467e7c0..83c24fc97a7b 100755
--- a/t/t5601-clone.sh
+++ b/t/t5601-clone.sh@@ -305,7 +305,8 @@ test_expect_success 'clone from original with relative alternate' ' test_expect_success 'clone checking out a tag' ' git clone --branch=some-tag src dst.tag && GIT_DIR=src/.git git rev-parse some-tag >expected && - test_cmp expected dst.tag/.git/HEAD && + GIT_DIR=dst.tag/.git git rev-parse HEAD >actual && + test_cmp expected actual && GIT_DIR=dst.tag/.git git config remote.origin.fetch >fetch.actual && echo "+refs/heads/*:refs/remotes/origin/*" >fetch.expected && test_cmp fetch.expected fetch.actual
--
gitgitgadget