aboutsummaryrefslogtreecommitdiff
path: root/t/t6040-tracking-info.sh
diff options
context:
space:
mode:
authorMichael J Gruber <git@drmicha.warpmail.net>2009-05-11 16:42:54 +0200
committerJunio C Hamano <gitster@pobox.com>2009-05-14 09:43:54 -0700
commit57ffc5f85a17416a718d4e7baf71d8356c9c7808 (patch)
tree304ab7b66df7c784d81670e53603bcae372f14d3 /t/t6040-tracking-info.sh
parent1be570f4ebb5f3c4e0a56341db166a760829782a (diff)
downloadgit-57ffc5f85a17416a718d4e7baf71d8356c9c7808.tar.gz
git-57ffc5f85a17416a718d4e7baf71d8356c9c7808.tar.xz
Fix behavior with non-commit upstream references
stat_tracking_info() assumes that upstream references (as specified by --track or set up automatically) are commits. By calling lookup_commit() on them, create_objects() creates objects for them with type commit no matter what their real type is; this disturbs lookup_tag() later on in the call sequence, leading to git status, git branch -v and git checkout erroring out. Fix this by using lookup_commit_reference() instead so that (annotated) tags can be used as upstream references. Signed-off-by: Michael J Gruber <git@drmicha.warpmail.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t6040-tracking-info.sh')
-rwxr-xr-xt/t6040-tracking-info.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/t/t6040-tracking-info.sh b/t/t6040-tracking-info.sh
index 4b89ac71f..5211e244b 100755
--- a/t/t6040-tracking-info.sh
+++ b/t/t6040-tracking-info.sh
@@ -74,7 +74,7 @@ test_expect_success 'status when tracking lightweight tags' '
git checkout lighttrack
'
-test_expect_failure 'status when tracking annotated tags' '
+test_expect_success 'status when tracking annotated tags' '
git checkout master &&
git tag -m heavy heavy &&
git branch --track heavytrack heavy >actual &&