From 268eb571764bb92d918ea5553790e14b397ee564 Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Fri, 23 Jan 2026 18:09:31 -0800 Subject: [PATCH] SQUASH??? fixup The test as posted breaks when run with $ make WITH_BREAKING_CHANGES=YesPlease test as the added part assumes that the default branch name is "master". This band-aid is sufficient for the purpose of the maintainer to get the CI passing, but the real solution should probably be done better in such a way that the latter step does not have to rely on the creation of "anchorpoint" in the previous step. I'll leave it to the contributor of the topic. --- t/t5572-pull-submodule.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/t/t5572-pull-submodule.sh b/t/t5572-pull-submodule.sh index faafe31409..dfc07d050b 100755 --- a/t/t5572-pull-submodule.sh +++ b/t/t5572-pull-submodule.sh @@ -246,7 +246,8 @@ test_expect_success 'fetch submodule remote of different name from superproject' git -C child submodule update --init && # Needs to create unreachable commit from current master branch. - git -C a-submodule checkout -b newmain HEAD^ && + git -C a-submodule tag anchorpoint HEAD && + git -C a-submodule checkout -b newmain anchorpoint^ && test_commit -C a-submodule echo && test_commit -C a-submodule moreecho && subc=$(git -C a-submodule rev-parse --short HEAD) && @@ -265,7 +266,7 @@ test_expect_success 'fetch submodule remote of different non-origin name from su git -C child/a-submodule remote rename origin o2 && # Create commit that is unreachable from current master branch - git -C a-submodule checkout -b newmain2 master^ && + git -C a-submodule checkout -b newmain2 anchorpoint^ && test_commit -C a-submodule echo_o2 && test_commit -C a-submodule moreecho_o2 && subc=$(git -C a-submodule rev-parse --short HEAD) &&