about summary refs log tree commit diff
path: root/third_party/git/t/t5537-fetch-shallow.sh
diff options
context:
space:
mode:
authorVincent Ambo <tazjin@google.com>2020-05-25T23·06+0100
committerVincent Ambo <tazjin@google.com>2020-05-25T23·06+0100
commit93ba78d6f4632ef1c5228965e3edc8c0faf88c1e (patch)
tree85730c182a9f5f492ade8e8ccdb1c2356f9900bd /third_party/git/t/t5537-fetch-shallow.sh
parent6f8fbf4aa4b1654ab27d4829e114538761817de0 (diff)
revert(3p/git): Revert merge of git upstream at v2.26.2 r/852
This causes cgit to serve error pages, which is undesirable.

This reverts commit 5229c9b232de5bfa959ad6ebbb4c8192ac513352, reversing
changes made to f2b211131f2347342dde63975b09cf603149f1a3.
Diffstat (limited to 'third_party/git/t/t5537-fetch-shallow.sh')
-rwxr-xr-xthird_party/git/t/t5537-fetch-shallow.sh21
1 files changed, 7 insertions, 14 deletions
diff --git a/third_party/git/t/t5537-fetch-shallow.sh b/third_party/git/t/t5537-fetch-shallow.sh
index 4f681dbbe11c..66f0b64d3927 100755
--- a/third_party/git/t/t5537-fetch-shallow.sh
+++ b/third_party/git/t/t5537-fetch-shallow.sh
@@ -15,11 +15,7 @@ test_expect_success 'setup' '
 	commit 2 &&
 	commit 3 &&
 	commit 4 &&
-	git config --global transfer.fsckObjects true &&
-	test_oid_cache <<-EOF
-	perl sha1:s/0034shallow %s/0036unshallow %s/
-	perl sha256:s/004cshallow %s/004eunshallow %s/
-	EOF
+	git config --global transfer.fsckObjects true
 '
 
 test_expect_success 'setup shallow clone' '
@@ -237,29 +233,26 @@ test_expect_success 'shallow fetches check connectivity before writing shallow f
 	git -C "$REPO" config protocol.version 2 &&
 	git -C client config protocol.version 2 &&
 
-	git -C client fetch --depth=2 "$HTTPD_URL/one_time_perl/repo" master:a_branch &&
+	git -C client fetch --depth=2 "$HTTPD_URL/one_time_sed/repo" master:a_branch &&
 
 	# Craft a situation in which the server sends back an unshallow request
 	# with an empty packfile. This is done by refetching with a shorter
 	# depth (to ensure that the packfile is empty), and overwriting the
 	# shallow line in the response with the unshallow line we want.
-	printf "$(test_oid perl)" \
+	printf "s/0034shallow %s/0036unshallow %s/" \
 	       "$(git -C "$REPO" rev-parse HEAD)" \
 	       "$(git -C "$REPO" rev-parse HEAD^)" \
-	       >"$HTTPD_ROOT_PATH/one-time-perl" &&
+	       >"$HTTPD_ROOT_PATH/one-time-sed" &&
 	test_must_fail env GIT_TEST_SIDEBAND_ALL=0 git -C client \
-		fetch --depth=1 "$HTTPD_URL/one_time_perl/repo" \
+		fetch --depth=1 "$HTTPD_URL/one_time_sed/repo" \
 		master:a_branch &&
 
-	# Ensure that the one-time-perl script was used.
-	! test -e "$HTTPD_ROOT_PATH/one-time-perl" &&
+	# Ensure that the one-time-sed script was used.
+	! test -e "$HTTPD_ROOT_PATH/one-time-sed" &&
 
 	# Ensure that the resulting repo is consistent, despite our failure to
 	# fetch.
 	git -C client fsck
 '
 
-# DO NOT add non-httpd-specific tests here, because the last part of this
-# test script is only executed when httpd is available and enabled.
-
 test_done