Skip to content

Commit

Permalink
Added a test for fetching remote tags when there is not tags.
Browse files Browse the repository at this point in the history
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>
  • Loading branch information
Väinö Järvelä authored and Shawn O. Pearce committed Oct 16, 2007
1 parent 8f70a76 commit f539d0d
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions t/t5510-fetch.sh
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,18 @@ test_expect_success "fetch test for-merge" '
cut -f -2 .git/FETCH_HEAD >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' '
cd "$D" &&
Expand Down

0 comments on commit f539d0d

Please sign in to comment.