Test for local branches being followed with --track
According to the documentation, it is perfectly okay to follow local branches using the --track option. Introduce a test which checks whether they behave the same. Currently one test fails. Signed-off-by: Michael J Gruber <git@drmicha.warpmail.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Michael J Gruber committed
Mar 26, 2009 at 21:53 UTC
57dac0bfe43a68d55e16def58b8ed305e0676d3f
1 file changed
+9
-1
t/t6040-tracking-info.sh
+9
-1
@@ -29,7 +29,9 @@ test_expect_success setup '
29
git checkout -b b4 origin &&
30
advance e &&
31
advance f
32
- )
32
+ ) &&
33
+ git checkout -b follower --track master &&
34
+ advance g
35
'
36
37
script='s/^..\(b.\)[ 0-9a-f]*\[\([^]]*\)\].*/\1 \2/p'
@@ -56,6 +58,12 @@ test_expect_success 'checkout' '
58
grep "have 1 and 1 different" actual
59
'
60
61
+test_expect_failure 'checkout with local tracked branch' '
62
+ git checkout master &&
63
+ git checkout follower >actual
64
+ grep "is ahead of" actual
65
+'
66
+
67
test_expect_success 'status' '
68
(
69
cd test &&