3 test_description
='Merge-recursive merging renames'
6 test_expect_success
'setup' '
8 a aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
9 b bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb
10 c cccccccccccccccccccccccccccccccccccccccccccccccc
11 d dddddddddddddddddddddddddddddddddddddddddddddddd
12 e eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee
13 f ffffffffffffffffffffffffffffffffffffffffffffffff
14 g gggggggggggggggggggggggggggggggggggggggggggggggg
15 h hhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh
16 i iiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii
17 j jjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjj
18 k kkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
19 l llllllllllllllllllllllllllllllllllllllllllllllll
20 m mmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmm
21 n nnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
22 o oooooooooooooooooooooooooooooooooooooooooooooooo
26 A AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
27 B BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB
28 C CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC
29 D DDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDD
30 E EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE
31 F FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF
32 G GGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGG
33 H HHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHH
34 I IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII
35 J JJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJ
36 K KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK
37 L LLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLL
38 M MMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMM
39 N NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN
40 O OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO
44 git commit -m "initial has A and M" &&
50 sed -e "/^g /s/.*/g : white changes a line/" <A >B &&
51 sed -e "/^G /s/.*/G : colored branch changes a line/" <M >N &&
53 git update-index --add --remove A B M N &&
54 git commit -m "white renames A->B, M->N" &&
57 echo created by red >R &&
58 git update-index --add R &&
59 git commit -m "red creates R" &&
62 sed -e "/^o /s/.*/g : blue changes a line/" <A >B &&
66 git commit -m "blue modify A" &&
71 # This test broke in 65ac6e9c3f47807cb603af07a6a9e1a43bc119ae
72 test_expect_success
'merge white into red (A->B,M->N)' '
73 git checkout -b red-white red &&
76 test_path_is_file B &&
77 test_path_is_file N &&
78 test_path_is_file R &&
79 test_path_is_missing A &&
80 test_path_is_missing M
83 # This test broke in 8371234ecaaf6e14fe3f2082a855eff1bbd79ae9
84 test_expect_success
'merge blue into white (A->B, mod A, A untracked)' '
85 git checkout -b white-blue white &&
89 test_path_is_file A &&
92 test_path_is_file B &&
93 test_path_is_file N &&
94 test_path_is_missing M