summaryrefslogtreecommitdiff
path: root/t/t5551-http-fetch-smart.sh
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2018-08-15 22:08:28 (GMT)
committerJunio C Hamano <gitster@pobox.com>2018-08-15 22:08:28 (GMT)
commitb160b6e69d5e8231cf71b3bcacef63443849d1f9 (patch)
treea9d7d4cd00f10d1b4545b3fa3596bcd24f7c907c /t/t5551-http-fetch-smart.sh
parent6be44b59fc5e957b9d6e25b32b0fc38c45d50f3f (diff)
parente2842b39f4168e3cd39a53961c1e50bb940eedf1 (diff)
downloadgit-b160b6e69d5e8231cf71b3bcacef63443849d1f9.zip
git-b160b6e69d5e8231cf71b3bcacef63443849d1f9.tar.gz
git-b160b6e69d5e8231cf71b3bcacef63443849d1f9.tar.bz2
Merge branch 'jt/connectivity-check-after-unshallow'
"git fetch" sometimes failed to update the remote-tracking refs, which has been corrected. * jt/connectivity-check-after-unshallow: fetch-pack: unify ref in and out param
Diffstat (limited to 't/t5551-http-fetch-smart.sh')
-rwxr-xr-xt/t5551-http-fetch-smart.sh18
1 files changed, 18 insertions, 0 deletions
diff --git a/t/t5551-http-fetch-smart.sh b/t/t5551-http-fetch-smart.sh
index 3aab44b..771f36f 100755
--- a/t/t5551-http-fetch-smart.sh
+++ b/t/t5551-http-fetch-smart.sh
@@ -363,6 +363,24 @@ test_expect_success 'custom http headers' '
submodule update sub
'
+test_expect_success 'using fetch command in remote-curl updates refs' '
+ SERVER="$HTTPD_DOCUMENT_ROOT_PATH/twobranch" &&
+ rm -rf "$SERVER" client &&
+
+ git init "$SERVER" &&
+ test_commit -C "$SERVER" foo &&
+ git -C "$SERVER" update-ref refs/heads/anotherbranch foo &&
+
+ git clone $HTTPD_URL/smart/twobranch client &&
+
+ test_commit -C "$SERVER" bar &&
+ git -C client -c protocol.version=0 fetch &&
+
+ git -C "$SERVER" rev-parse master >expect &&
+ git -C client rev-parse origin/master >actual &&
+ test_cmp expect actual
+'
+
test_expect_success 'GIT_REDACT_COOKIES redacts cookies' '
rm -rf clone &&
echo "Set-Cookie: Foo=1" >cookies &&