tests: set GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME only when needed

A couple of test scripts have actually been adapted to accommodate for a
configurable default branch name, but they still overrode it via the
`GIT_TEST_*` variable. Let's drop that override where possible.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Johannes Schindelin 2021-12-03 09:39:13 +00:00 committed by Junio C Hamano
parent abe6bb3905
commit 9f3547837e
17 changed files with 0 additions and 50 deletions

View File

@ -4,9 +4,6 @@ test_description='git read-tree in partial clones'
TEST_NO_CREATE_REPO=1 TEST_NO_CREATE_REPO=1
GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main
export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
. ./test-lib.sh . ./test-lib.sh
test_expect_success 'read-tree in partial clone prefetches in one batch' ' test_expect_success 'read-tree in partial clone prefetches in one batch' '

View File

@ -4,9 +4,6 @@
# #
test_description='Test git update-ref and basic ref logging' test_description='Test git update-ref and basic ref logging'
GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main
export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
. ./test-lib.sh . ./test-lib.sh
Z=$ZERO_OID Z=$ZERO_OID

View File

@ -2,9 +2,6 @@
test_description='branch --contains <commit>, --no-contains <commit> --merged, and --no-merged' test_description='branch --contains <commit>, --no-contains <commit> --merged, and --no-merged'
GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main
export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
. ./test-lib.sh . ./test-lib.sh
test_expect_success setup ' test_expect_success setup '

View File

@ -1,9 +1,6 @@
#!/bin/sh #!/bin/sh
test_description='git branch display tests' test_description='git branch display tests'
GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main
export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
. ./test-lib.sh . ./test-lib.sh
. "$TEST_DIRECTORY"/lib-terminal.sh . "$TEST_DIRECTORY"/lib-terminal.sh

View File

@ -1,9 +1,6 @@
#!/bin/sh #!/bin/sh
test_description='basic branch output coloring' test_description='basic branch output coloring'
GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main
export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
TEST_PASSES_SANITIZE_LEAK=true TEST_PASSES_SANITIZE_LEAK=true
. ./test-lib.sh . ./test-lib.sh

View File

@ -25,8 +25,6 @@ Initial setup:
where A, B, D and G all touch file1, and one, two, three, four all where A, B, D and G all touch file1, and one, two, three, four all
touch file "conflict". touch file "conflict".
' '
GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=master
export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
. ./test-lib.sh . ./test-lib.sh

View File

@ -1,8 +1,6 @@
#!/bin/sh #!/bin/sh
test_description='exercise basic bitmap functionality' test_description='exercise basic bitmap functionality'
GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=master
export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
. ./test-lib.sh . ./test-lib.sh
. "$TEST_DIRECTORY"/lib-bitmap.sh . "$TEST_DIRECTORY"/lib-bitmap.sh

View File

@ -2,9 +2,6 @@
test_description='git remote porcelain-ish' test_description='git remote porcelain-ish'
GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main
export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
. ./test-lib.sh . ./test-lib.sh
setup_repository () { setup_repository () {

View File

@ -5,9 +5,6 @@ test_description='Per branch config variables affects "git fetch".
' '
GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main
export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
. ./test-lib.sh . ./test-lib.sh
. "$TEST_DIRECTORY"/lib-bundle.sh . "$TEST_DIRECTORY"/lib-bundle.sh

View File

@ -3,9 +3,6 @@
test_description='Recursive "git fetch" for submodules' test_description='Recursive "git fetch" for submodules'
GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=master
export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
GIT_TEST_FATAL_REGISTER_SUBMODULE_ODB=1 GIT_TEST_FATAL_REGISTER_SUBMODULE_ODB=1
export GIT_TEST_FATAL_REGISTER_SUBMODULE_ODB export GIT_TEST_FATAL_REGISTER_SUBMODULE_ODB

View File

@ -2,9 +2,6 @@
test_description='upload-pack ref-in-want' test_description='upload-pack ref-in-want'
GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main
export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
. ./test-lib.sh . ./test-lib.sh
get_actual_refs () { get_actual_refs () {

View File

@ -5,9 +5,6 @@
test_description='for-each-ref test' test_description='for-each-ref test'
GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=master
export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
. ./test-lib.sh . ./test-lib.sh
. "$TEST_DIRECTORY"/lib-gpg.sh . "$TEST_DIRECTORY"/lib-gpg.sh
. "$TEST_DIRECTORY"/lib-terminal.sh . "$TEST_DIRECTORY"/lib-terminal.sh

View File

@ -2,9 +2,6 @@
test_description='test for-each-refs usage of ref-filter APIs' test_description='test for-each-refs usage of ref-filter APIs'
GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main
export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
. ./test-lib.sh . ./test-lib.sh
. "$TEST_DIRECTORY"/lib-gpg.sh . "$TEST_DIRECTORY"/lib-gpg.sh

View File

@ -4,10 +4,6 @@ test_description='git status --porcelain=v2
This test exercises porcelain V2 output for git status.' This test exercises porcelain V2 output for git status.'
GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=master
export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
. ./test-lib.sh . ./test-lib.sh

View File

@ -5,9 +5,6 @@
test_description='git-svn svn mergeinfo properties' test_description='git-svn svn mergeinfo properties'
GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main
export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
. ./lib-git-svn.sh . ./lib-git-svn.sh
test_expect_success 'load svn dump' " test_expect_success 'load svn dump' "

View File

@ -12,9 +12,6 @@
# bug. # bug.
test_description='git cvsimport testing for correct patchset estimation' test_description='git cvsimport testing for correct patchset estimation'
GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main
export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
. ./lib-cvs.sh . ./lib-cvs.sh
setup_cvs_test_repository t9603 setup_cvs_test_repository t9603

View File

@ -5,9 +5,6 @@
test_description='test bash completion' test_description='test bash completion'
GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=master
export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
. ./lib-bash.sh . ./lib-bash.sh
complete () complete ()