Added a test for fetching remote tags when there is not tags.

When a user runs "git fetch -t", git crashes when it doesn't find any
tags on the remote repository.

Signed-off-by: Väinö Järvelä <v@pp.inet.fi>
Signed-off-by: Lars Hjemli <hjemli@gmail.com>
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
This commit is contained in:
Väinö Järvelä 2007-10-09 11:51:07 +03:00 коммит произвёл Shawn O. Pearce
Родитель 8f70a7657a
Коммит f539d0d6c1
1 изменённых файлов: 12 добавлений и 0 удалений

Просмотреть файл

@ -67,6 +67,18 @@ test_expect_success "fetch test for-merge" '
cut -f -2 .git/FETCH_HEAD >actual && cut -f -2 .git/FETCH_HEAD >actual &&
diff expected actual' diff expected actual'
test_expect_success 'fetch tags when there is no tags' '
cd "$D" &&
mkdir notags &&
cd notags &&
git init &&
git fetch -t ..
'
test_expect_success 'fetch following tags' ' test_expect_success 'fetch following tags' '
cd "$D" && cd "$D" &&