]> git.ipfire.org Git - thirdparty/git.git/blobdiff - t/t5542-push-http-shallow.sh
Merge branch 'js/range-diff-wo-dotdot'
[thirdparty/git.git] / t / t5542-push-http-shallow.sh
index ddc1db722d43ce3cfbf80b46deea0a69a4973247..c2cc83182f9a6b8ae3aa0b2cee1b5b28fd12c7f3 100755 (executable)
@@ -2,6 +2,9 @@
 
 test_description='push from/to a shallow clone over http'
 
+GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main
+export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
+
 . ./test-lib.sh
 . "$TEST_DIRECTORY"/lib-httpd.sh
 start_httpd
@@ -51,12 +54,12 @@ test_expect_success 'push to shallow repo via http' '
        (
        cd full &&
        commit 9 &&
-       git push $HTTPD_URL/smart/repo.git +master:refs/remotes/top/master
+       git push $HTTPD_URL/smart/repo.git +main:refs/remotes/top/main
        ) &&
        (
        cd "$HTTPD_DOCUMENT_ROOT_PATH/repo.git" &&
        git fsck &&
-       git log --format=%s top/master >actual &&
+       git log --format=%s top/main >actual &&
        cat <<EOF >expect &&
 9
 4
@@ -74,11 +77,11 @@ test_expect_success 'push from shallow repo via http' '
        git config http.receivepack true
        ) &&
        commit 10 &&
-       git push $HTTPD_URL/smart/repo.git +master:refs/remotes/top/master &&
+       git push $HTTPD_URL/smart/repo.git +main:refs/remotes/top/main &&
        (
        cd "$HTTPD_DOCUMENT_ROOT_PATH/repo.git" &&
        git fsck &&
-       git log --format=%s top/master >actual &&
+       git log --format=%s top/main >actual &&
        cat <<EOF >expect &&
 10
 4