@matheusbsbs / matheus-bagliano / commits / 494202524f
Fork 0

t5510: test "git fetch" following tags minimally

When "git fetch" auto-follows tags, it should not download excess ones. This new test makes sure that condition. Signed-off-by: Junio C Hamano <gitster@pobox.com>

Junio C Hamano committed Sep 21, 2008 at 23:50 UTC 494202524f76ac0385ae483abf970c4c9c692a77
1 file changed +20
t/t5510-fetch.sh
+20
@@ -303,4 +303,24 @@ test_expect_success 'pushing nonexistent branch by mistake should not segv' '
303
304 '
305
306 +test_expect_success 'auto tag following fetches minimum' '
307 +
308 + cd "$D" &&
309 + git clone .git follow &&
310 + git checkout HEAD^0 &&
311 + (
312 + for i in 1 2 3 4 5 6 7
313 + do
314 + echo $i >>file &&
315 + git commit -m $i -a &&
316 + git tag -a -m $i excess-$i || exit 1
317 + done
318 + ) &&
319 + git checkout master &&
320 + (
321 + cd follow &&
322 + git fetch
323 + )
324 +'
325 +
326 test_done