summaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
authorLibravatar Michael J Gruber <git@drmicha.warpmail.net>2009-04-01 23:42:49 +0200
committerLibravatar Junio C Hamano <gitster@pobox.com>2009-04-01 15:48:30 -0700
commit5e6e2b487e76066d03b4f5809dc6b44b1234519a (patch)
tree758dcd08a7eecbcc13aa4298b7e60329eefabc4a /t
parentTest for local branches being followed with --track (diff)
downloadtgif-5e6e2b487e76066d03b4f5809dc6b44b1234519a.tar.xz
Make local branches behave like remote branches when --tracked
This makes sure that local branches, when followed using --track, behave the same as remote ones (e.g. differences being reported by git status and git checkout). This fixes 1 known failure. The fix is done within branch_get(): The first natural candidate, namely remote_find_tracking(), does not have all the necessary info because in general there is no remote struct for '.', and we don't want one because it would show up in other places as well. branch_get(), on the other hand, has access to merge_names[] (in addition to merge[]) and therefore can set up the followed branch easily. Signed-off-by: Michael J Gruber <git@drmicha.warpmail.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't')
-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 2a2b6b63d5..3d6db4d386 100755
--- a/t/t6040-tracking-info.sh
+++ b/t/t6040-tracking-info.sh
@@ -58,7 +58,7 @@ test_expect_success 'checkout' '
grep "have 1 and 1 different" actual
'
-test_expect_failure 'checkout with local tracked branch' '
+test_expect_success 'checkout with local tracked branch' '
git checkout master &&
git checkout follower >actual
grep "is ahead of" actual