Mercurial > hg
comparison tests/test-merge7.t @ 11980:c443e95d295b
tests: unify test-merge7
author | Pradeepkumar Gayam <in3xes@gmail.com> |
---|---|
date | Wed, 18 Aug 2010 05:54:00 +0530 |
parents | tests/test-merge7@7c36a4fb05a3 |
children | 4c94b6d0fb1c |
comparison
equal
deleted
inserted
replaced
11979:39fb1e4c079f | 11980:c443e95d295b |
---|---|
1 initial | |
2 $ hg init test-a | |
3 $ cd test-a | |
4 $ cat >test.txt <<"EOF" | |
5 > 1 | |
6 > 2 | |
7 > 3 | |
8 > EOF | |
9 $ hg add test.txt | |
10 $ hg commit -m "Initial" -d "1000000 0" | |
11 | |
12 clone | |
13 $ cd .. | |
14 $ hg clone test-a test-b | |
15 updating to branch default | |
16 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
17 | |
18 change test-a | |
19 $ cd test-a | |
20 $ cat >test.txt <<"EOF" | |
21 > one | |
22 > two | |
23 > three | |
24 > EOF | |
25 $ hg commit -m "Numbers as words" -d "1000000 0" | |
26 | |
27 change test-b | |
28 $ cd ../test-b | |
29 $ cat >test.txt <<"EOF" | |
30 > 1 | |
31 > 2.5 | |
32 > 3 | |
33 > EOF | |
34 $ hg commit -m "2 -> 2.5" -d "1000000 0" | |
35 | |
36 now pull and merge from test-a | |
37 $ hg pull ../test-a | |
38 pulling from ../test-a | |
39 searching for changes | |
40 adding changesets | |
41 adding manifests | |
42 adding file changes | |
43 added 1 changesets with 1 changes to 1 files (+1 heads) | |
44 (run 'hg heads' to see heads, 'hg merge' to merge) | |
45 $ hg merge | |
46 merging test.txt | |
47 warning: conflicts during merge. | |
48 merging test.txt failed! | |
49 0 files updated, 0 files merged, 0 files removed, 1 files unresolved | |
50 use 'hg resolve' to retry unresolved file merges or 'hg update -C' to abandon | |
51 resolve conflict | |
52 $ cat >test.txt <<"EOF" | |
53 > one | |
54 > two-point-five | |
55 > three | |
56 > EOF | |
57 $ rm -f *.orig | |
58 $ hg resolve -m test.txt | |
59 $ hg commit -m "Merge 1" -d "1000000 0" | |
60 | |
61 change test-a again | |
62 $ cd ../test-a | |
63 $ cat >test.txt <<"EOF" | |
64 > one | |
65 > two-point-one | |
66 > three | |
67 > EOF | |
68 $ hg commit -m "two -> two-point-one" -d "1000000 0" | |
69 | |
70 pull and merge from test-a again | |
71 $ cd ../test-b | |
72 $ hg pull ../test-a | |
73 pulling from ../test-a | |
74 searching for changes | |
75 adding changesets | |
76 adding manifests | |
77 adding file changes | |
78 added 1 changesets with 1 changes to 1 files (+1 heads) | |
79 (run 'hg heads' to see heads, 'hg merge' to merge) | |
80 $ hg merge --debug | |
81 searching for copies back to rev 1 | |
82 resolving manifests | |
83 overwrite None partial False | |
84 ancestor faaea63e63a9 local 451c744aabcc+ remote a070d41e8360 | |
85 test.txt: versions differ -> m | |
86 preserving test.txt for resolve of test.txt | |
87 updating: test.txt 1/1 files (100.00%) | |
88 picked tool 'internal:merge' for test.txt (binary False symlink False) | |
89 merging test.txt | |
90 my test.txt@451c744aabcc+ other test.txt@a070d41e8360 ancestor test.txt@faaea63e63a9 | |
91 warning: conflicts during merge. | |
92 merging test.txt failed! | |
93 0 files updated, 0 files merged, 0 files removed, 1 files unresolved | |
94 use 'hg resolve' to retry unresolved file merges or 'hg update -C' to abandon | |
95 | |
96 $ cat test.txt | |
97 one | |
98 <<<<<<< local | |
99 two-point-five | |
100 ======= | |
101 two-point-one | |
102 >>>>>>> other | |
103 three | |
104 | |
105 $ hg debugindex .hg/store/data/test.txt.i | |
106 rev offset length base linkrev nodeid p1 p2 | |
107 0 0 7 0 0 01365c4cca56 000000000000 000000000000 | |
108 1 7 9 1 1 7b013192566a 01365c4cca56 000000000000 | |
109 2 16 15 2 2 8fe46a3eb557 01365c4cca56 000000000000 | |
110 3 31 27 2 3 fc3148072371 7b013192566a 8fe46a3eb557 | |
111 4 58 25 4 4 d40249267ae3 8fe46a3eb557 000000000000 | |
112 | |
113 $ hg log | |
114 changeset: 4:a070d41e8360 | |
115 tag: tip | |
116 parent: 2:faaea63e63a9 | |
117 user: test | |
118 date: Mon Jan 12 13:46:40 1970 +0000 | |
119 summary: two -> two-point-one | |
120 | |
121 changeset: 3:451c744aabcc | |
122 parent: 1:e409be6afcc0 | |
123 parent: 2:faaea63e63a9 | |
124 user: test | |
125 date: Mon Jan 12 13:46:40 1970 +0000 | |
126 summary: Merge 1 | |
127 | |
128 changeset: 2:faaea63e63a9 | |
129 parent: 0:095c92b91f1a | |
130 user: test | |
131 date: Mon Jan 12 13:46:40 1970 +0000 | |
132 summary: Numbers as words | |
133 | |
134 changeset: 1:e409be6afcc0 | |
135 user: test | |
136 date: Mon Jan 12 13:46:40 1970 +0000 | |
137 summary: 2 -> 2.5 | |
138 | |
139 changeset: 0:095c92b91f1a | |
140 user: test | |
141 date: Mon Jan 12 13:46:40 1970 +0000 | |
142 summary: Initial | |
143 |