t5500: add test for fetching with an unknown 'shallow'

When the client sends a 'shallow' line for an object that the server does not have, the server should just ignore it and let the client keep that unknown shallow boundary. Signed-off-by: Michael Heemskerk <mheemskerk@atlassian.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Michael Heemskerk committed May 3, 2013 at 00:56 UTC 71d5f938910120275484aac0b2e1c27cdf8b5cf3
1 file changed +14
t/t5500-fetch-pack.sh
+14
@@ -373,6 +373,20 @@ test_expect_success 'clone shallow with packed refs' '
373 test_cmp count8.expected count8.actual
374 '
375
376 +test_expect_success 'fetch in shallow repo unreachable shallow objects' '
377 + (
378 + git clone --bare --branch B --single-branch "file://$(pwd)/." no-reflog &&
379 + git clone --depth 1 "file://$(pwd)/no-reflog" shallow9 &&
380 + cd no-reflog &&
381 + git tag -d TAGB1 TAGB2 &&
382 + git update-ref refs/heads/B B~~ &&
383 + git gc --prune=now &&
384 + cd ../shallow9 &&
385 + git fetch origin &&
386 + git fsck --no-dangling
387 + )
388 +'
389 +
390 test_expect_success 'setup tests for the --stdin parameter' '
391 for head in C D E F
392 do