Mercurial > hg
comparison tests/test-annotate.t @ 11852:b2f91119bf8c
tests: unify test-annotate
author | Martin Geisler <mg@lazybytes.net> |
---|---|
date | Sat, 14 Aug 2010 02:18:17 +0200 |
parents | tests/test-annotate@98a0421b9e52 |
children | 4fee1fd3de9a |
comparison
equal
deleted
inserted
replaced
11851:db955418a6af | 11852:b2f91119bf8c |
---|---|
1 $ HGMERGE=true; export HGMERGE | |
2 | |
3 init | |
4 | |
5 $ hg init | |
6 | |
7 commit | |
8 | |
9 $ echo 'a' > a | |
10 $ hg ci -A -m test -u nobody -d '1 0' | |
11 adding a | |
12 | |
13 annotate -c | |
14 | |
15 $ hg annotate -c a | |
16 8435f90966e4: a | |
17 | |
18 annotate -cl | |
19 | |
20 $ hg annotate -cl a | |
21 8435f90966e4:1: a | |
22 | |
23 annotate -d | |
24 | |
25 $ hg annotate -d a | |
26 Thu Jan 01 00:00:01 1970 +0000: a | |
27 | |
28 annotate -n | |
29 | |
30 $ hg annotate -n a | |
31 0: a | |
32 | |
33 annotate -nl | |
34 | |
35 $ hg annotate -nl a | |
36 0:1: a | |
37 | |
38 annotate -u | |
39 | |
40 $ hg annotate -u a | |
41 nobody: a | |
42 | |
43 annotate -cdnu | |
44 | |
45 $ hg annotate -cdnu a | |
46 nobody 0 8435f90966e4 Thu Jan 01 00:00:01 1970 +0000: a | |
47 | |
48 annotate -cdnul | |
49 | |
50 $ hg annotate -cdnul a | |
51 nobody 0 8435f90966e4 Thu Jan 01 00:00:01 1970 +0000:1: a | |
52 | |
53 $ cat <<EOF >>a | |
54 > a | |
55 > a | |
56 > EOF | |
57 $ hg ci -ma1 -d '1 0' | |
58 $ hg cp a b | |
59 $ hg ci -mb -d '1 0' | |
60 $ cat <<EOF >> b | |
61 > b4 | |
62 > b5 | |
63 > b6 | |
64 > EOF | |
65 $ hg ci -mb2 -d '2 0' | |
66 | |
67 annotate -n b | |
68 | |
69 $ hg annotate -n b | |
70 0: a | |
71 1: a | |
72 1: a | |
73 3: b4 | |
74 3: b5 | |
75 3: b6 | |
76 | |
77 annotate --no-follow b | |
78 | |
79 $ hg annotate --no-follow b | |
80 2: a | |
81 2: a | |
82 2: a | |
83 3: b4 | |
84 3: b5 | |
85 3: b6 | |
86 | |
87 annotate -nl b | |
88 | |
89 $ hg annotate -nl b | |
90 0:1: a | |
91 1:2: a | |
92 1:3: a | |
93 3:4: b4 | |
94 3:5: b5 | |
95 3:6: b6 | |
96 | |
97 annotate -nf b | |
98 | |
99 $ hg annotate -nf b | |
100 0 a: a | |
101 1 a: a | |
102 1 a: a | |
103 3 b: b4 | |
104 3 b: b5 | |
105 3 b: b6 | |
106 | |
107 annotate -nlf b | |
108 | |
109 $ hg annotate -nlf b | |
110 0 a:1: a | |
111 1 a:2: a | |
112 1 a:3: a | |
113 3 b:4: b4 | |
114 3 b:5: b5 | |
115 3 b:6: b6 | |
116 | |
117 $ hg up -C 2 | |
118 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
119 $ cat <<EOF >> b | |
120 > b4 | |
121 > c | |
122 > b5 | |
123 > EOF | |
124 $ hg ci -mb2.1 -d '2 0' | |
125 created new head | |
126 $ hg merge | |
127 merging b | |
128 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |
129 (branch merge, don't forget to commit) | |
130 $ hg ci -mmergeb -d '3 0' | |
131 | |
132 annotate after merge | |
133 | |
134 $ hg annotate -nf b | |
135 0 a: a | |
136 1 a: a | |
137 1 a: a | |
138 3 b: b4 | |
139 4 b: c | |
140 3 b: b5 | |
141 | |
142 annotate after merge with -l | |
143 | |
144 $ hg annotate -nlf b | |
145 0 a:1: a | |
146 1 a:2: a | |
147 1 a:3: a | |
148 3 b:4: b4 | |
149 4 b:5: c | |
150 3 b:5: b5 | |
151 | |
152 $ hg up -C 1 | |
153 0 files updated, 0 files merged, 1 files removed, 0 files unresolved | |
154 $ hg cp a b | |
155 $ cat <<EOF > b | |
156 > a | |
157 > z | |
158 > a | |
159 > EOF | |
160 $ hg ci -mc -d '3 0' | |
161 created new head | |
162 $ hg merge | |
163 merging b | |
164 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |
165 (branch merge, don't forget to commit) | |
166 $ cat <<EOF >> b | |
167 > b4 | |
168 > c | |
169 > b5 | |
170 > EOF | |
171 $ echo d >> b | |
172 $ hg ci -mmerge2 -d '4 0' | |
173 | |
174 annotate after rename merge | |
175 | |
176 $ hg annotate -nf b | |
177 0 a: a | |
178 6 b: z | |
179 1 a: a | |
180 3 b: b4 | |
181 4 b: c | |
182 3 b: b5 | |
183 7 b: d | |
184 | |
185 annotate after rename merge with -l | |
186 | |
187 $ hg annotate -nlf b | |
188 0 a:1: a | |
189 6 b:2: z | |
190 1 a:3: a | |
191 3 b:4: b4 | |
192 4 b:5: c | |
193 3 b:5: b5 | |
194 7 b:7: d | |
195 | |
196 linkrev vs rev | |
197 | |
198 $ hg annotate -r tip -n a | |
199 0: a | |
200 1: a | |
201 1: a | |
202 | |
203 linkrev vs rev with -l | |
204 | |
205 $ hg annotate -r tip -nl a | |
206 0:1: a | |
207 1:2: a | |
208 1:3: a | |
209 | |
210 test issue 589 | |
211 | |
212 annotate was crashing when trying to --follow something | |
213 | |
214 like A -> B -> A | |
215 | |
216 generate ABA rename configuration | |
217 | |
218 $ echo foo > foo | |
219 $ hg add foo | |
220 $ hg ci -m addfoo | |
221 $ hg rename foo bar | |
222 $ hg ci -m renamefoo | |
223 $ hg rename bar foo | |
224 $ hg ci -m renamebar | |
225 | |
226 annotate after ABA with follow | |
227 | |
228 $ hg annotate --follow foo | |
229 foo: foo | |
230 |