From 1e2ae142c06f7648a646278947bbcb61173f37eb Mon Sep 17 00:00:00 2001 From: Johannes Schindelin Date: Wed, 18 Nov 2020 23:44:40 +0000 Subject: t7[5-9]*: adjust the references to the default branch name "main" Excluding t7817, which is added in an unrelated patch series at the time of writing, this adjusts t7[5-9]*. This trick was performed via $ (cd t && sed -i -e 's/master/main/g' -e 's/MASTER/MAIN/g' \ -e 's/Master/Main/g' -- t7[5-9]*.sh) This allows us to define `GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main` for those tests. Signed-off-by: Johannes Schindelin Signed-off-by: Junio C Hamano --- t/t7502-commit-porcelain.sh | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 't/t7502-commit-porcelain.sh') diff --git a/t/t7502-commit-porcelain.sh b/t/t7502-commit-porcelain.sh index c8c16bf1c9..e5332adc9a 100755 --- a/t/t7502-commit-porcelain.sh +++ b/t/t7502-commit-porcelain.sh @@ -2,7 +2,7 @@ test_description='git commit porcelain-ish' -GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=master +GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME . ./test-lib.sh @@ -79,7 +79,7 @@ test_expect_success 'output summary format for merges' ' output_tests_cleanup() { # this is needed for "do not fire editor in the presence of conflicts" - git checkout master && + git checkout main && # this is needed for the "partial removal" test to pass git rm file1 && @@ -443,7 +443,7 @@ test_expect_success 'do not fire editor in the presence of conflicts' ' git add g && git commit -m "add g" && git branch second && - echo master >g && + echo main >g && echo g >h && git add g h && git commit -m "modify g and add h" && @@ -452,7 +452,7 @@ test_expect_success 'do not fire editor in the presence of conflicts' ' git add g && git commit -m second && # Must fail due to conflict - test_must_fail git cherry-pick -n master && + test_must_fail git cherry-pick -n main && echo "editor not started" >.git/result && ( GIT_EDITOR="\"$(pwd)/.git/FAKE_EDITOR\"" && @@ -481,9 +481,9 @@ git reset -q --hard test_expect_success 'Hand committing of a redundant merge removes dups' ' - git rev-parse second master >expect && - test_must_fail git merge second master && - git checkout master g && + git rev-parse second main >expect && + test_must_fail git merge second main && + git checkout main g && EDITOR=: git commit -a && git cat-file commit HEAD >raw && sed -n -e "s/^parent //p" -e "/^$/q" raw >actual && -- cgit v1.2.3