@matheusbsbs / matheus-bagliano / commits / 6f53c3b21e
Fork 0

t7111: fix bad HEAD in tests with unmerged entries

When testing what happens on unmerged entries, the HEAD is the commit we are starting from before the merge that fails and create the unmerged entries. It is not the commit before. Signed-off-by: Christian Couder <chriscool@tuxfamily.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Christian Couder committed Jan 16, 2010 at 10:20 UTC 6f53c3b21e3899716caccc2f88a1186ca7fa0f60
1 file changed +10 -10
t/t7111-reset-table.sh
+10 -10
@@ -73,13 +73,13 @@ test_expect_success 'setting up branches to test with unmerged entries' '
73 git checkout branch1 &&
74 test_commit B1 file1 &&
75 git checkout branch2 &&
76 - test_commit B2 file1
76 + test_commit B file1
77 '
78
79 while read W1 I1 H1 T opt W2 I2 H2
80 do
81 test_expect_success "check: $W1 $I1 $H1 $T --$opt $W2 $I2 $H2" '
82 - git reset --hard B2 &&
82 + git reset --hard B &&
83 test_must_fail git merge branch1 &&
84 cat file1 >X_file1 &&
85 if test "$W2" != "XXXXX"
@@ -100,14 +100,14 @@ do
100 fi
101 '
102 done <<\EOF
103 -X U C D soft XXXXX
104 -X U C D mixed X D D
105 -X U C D hard D D D
106 -X U C D merge D D D
107 -X U C C soft XXXXX
108 -X U C C mixed X C C
109 -X U C C hard C C C
110 -X U C C merge C C C
103 +X U B C soft XXXXX
104 +X U B C mixed X C C
105 +X U B C hard C C C
106 +X U B C merge C C C
107 +X U B B soft XXXXX
108 +X U B B mixed X B B
109 +X U B B hard B B B
110 +X U B B merge B B B
111 EOF
112
113 test_done