summaryrefslogtreecommitdiff
path: root/t/t5516-fetch-push.sh
diff options
context:
space:
mode:
authorMatt McCutchen <matt@mattmccutchen.net>2017-02-22 16:05:57 (GMT)
committerJunio C Hamano <gitster@pobox.com>2017-03-02 19:12:53 (GMT)
commitd56583ded679f2eade3994d855c8d605e2964710 (patch)
tree0e0774cb387c973b2c97d8e9e2e06e34c3c2f382 /t/t5516-fetch-push.sh
parente70a65c5d89e4543491082d4b361398fd87433db (diff)
downloadgit-d56583ded679f2eade3994d855c8d605e2964710.zip
git-d56583ded679f2eade3994d855c8d605e2964710.tar.gz
git-d56583ded679f2eade3994d855c8d605e2964710.tar.bz2
fetch-pack: add specific error for fetching an unadvertised object
Enhance filter_refs (which decides whether a request for an unadvertised object should be sent to the server) to record a new match status on the "struct ref" when a request is not allowed, and have report_unmatched_refs check for this status and print a special error message, "Server does not allow request for unadvertised object". Signed-off-by: Matt McCutchen <matt@mattmccutchen.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t5516-fetch-push.sh')
-rwxr-xr-xt/t5516-fetch-push.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/t/t5516-fetch-push.sh b/t/t5516-fetch-push.sh
index 0d13a45..78f3b8e 100755
--- a/t/t5516-fetch-push.sh
+++ b/t/t5516-fetch-push.sh
@@ -1099,7 +1099,7 @@ test_expect_success 'fetch exact SHA1' '
# fetching the hidden object should fail by default
test_must_fail git fetch -v ../testrepo $the_commit:refs/heads/copy 2>err &&
- test_i18ngrep "no such remote ref" err &&
+ test_i18ngrep "Server does not allow request for unadvertised object" err &&
test_must_fail git rev-parse --verify refs/heads/copy &&
# the server side can allow it to succeed