comparison tests/test-stabilize-result.t @ 3623:71fbb679e311

evolve: use the new rebased changeset to resolve phase-divergence When there is a parent change in phase-divergence, `hg evolve` first rebases the diveregent changeset on parent of public changeset and then continue the resolution of phase-divergence *but* we used to continue with the old divergent changeset rather than the new rebased one. This patch makes sure we use the new rebased changeset to proceed with the resolution. Tests changes shows that it fixes things which were broken earlier.
author Pulkit Goyal <7895pulkit@gmail.com>
date Fri, 23 Mar 2018 17:46:46 +0530
parents db3ec5f79ab9
children 92a2d3217de9
comparison
equal deleted inserted replaced
3622:534af64b0107 3623:71fbb679e311
171 recreate:[9] newer a 171 recreate:[9] newer a
172 atop:[6] newer a 172 atop:[6] newer a
173 perform evolve? [Ny] y 173 perform evolve? [Ny] y
174 rebasing to destination parent: 66719795a494 174 rebasing to destination parent: 66719795a494
175 computing new diff 175 computing new diff
176 committed as 3d968e0b3097 176 committed as 8fc63fe1f297
177 working directory is now at 3d968e0b3097 177 working directory is now at 8fc63fe1f297
178 $ glog 178 $ glog
179 @ 11:3d968e0b3097@default(draft) bk:[] phase-divergent update to 1cf0aacfd363: 179 @ 11:8fc63fe1f297@default(draft) bk:[] phase-divergent update to 1cf0aacfd363:
180 | 180 |
181 | o 7:7bc2f5967f5e@default(draft) bk:[] add c 181 | o 7:7bc2f5967f5e@default(draft) bk:[] add c
182 | | 182 | |
183 o | 6:1cf0aacfd363@default(public) bk:[] newer a 183 o | 6:1cf0aacfd363@default(public) bk:[] newer a
184 |/ 184 |/
185 o 5:66719795a494@default(public) bk:[changea] changea 185 o 5:66719795a494@default(public) bk:[changea] changea
186 | 186 |
187 o 0:07f494440405@default(public) bk:[] adda 187 o 0:07f494440405@default(public) bk:[] adda
188 188
189 XXX: c addition should not be part of this patch
190 $ hg exp 189 $ hg exp
191 # HG changeset patch 190 # HG changeset patch
192 # User test 191 # User test
193 # Date 0 0 192 # Date 0 0
194 # Thu Jan 01 00:00:00 1970 +0000 193 # Thu Jan 01 00:00:00 1970 +0000
195 # Node ID 3d968e0b3097ef69b104ff2e1af43fce665feb0a 194 # Node ID 8fc63fe1f297f356d1156bbbbe865b9911efad74
196 # Parent 1cf0aacfd36310b18e403e1594871187e0364a82 195 # Parent 1cf0aacfd36310b18e403e1594871187e0364a82
197 phase-divergent update to 1cf0aacfd363: 196 phase-divergent update to 1cf0aacfd363:
198 197
199 newer a 198 newer a
200 199
201 diff -r 1cf0aacfd363 -r 3d968e0b3097 a 200 diff -r 1cf0aacfd363 -r 8fc63fe1f297 a
202 --- a/a Thu Jan 01 00:00:00 1970 +0000 201 --- a/a Thu Jan 01 00:00:00 1970 +0000
203 +++ b/a Thu Jan 01 00:00:00 1970 +0000 202 +++ b/a Thu Jan 01 00:00:00 1970 +0000
204 @@ -1,3 +1,4 @@ 203 @@ -1,3 +1,4 @@
205 a 204 a
206 a 205 a
207 newer a 206 newer a
208 +babar 207 +babar
209 diff -r 1cf0aacfd363 -r 3d968e0b3097 c
210 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
211 +++ b/c Thu Jan 01 00:00:00 1970 +0000
212 @@ -0,0 +1,1 @@
213 +c
214 208
215 Stabilize divergent changesets with same parent 209 Stabilize divergent changesets with same parent
216 =============================================== 210 ===============================================
217 211
218 $ rm a.orig 212 $ rm a.orig
219 $ hg up 7bc2f5967f5e 213 $ hg up 7bc2f5967f5e
220 1 files updated, 0 files merged, 0 files removed, 0 files unresolved 214 2 files updated, 0 files merged, 0 files removed, 0 files unresolved
221 $ cat << EOF >> a 215 $ cat << EOF >> a
222 > flore 216 > flore
223 > arthur 217 > arthur
224 > zephir 218 > zephir
225 > some 219 > some
228 > EOF 222 > EOF
229 $ hg ci -m 'More addition' 223 $ hg ci -m 'More addition'
230 $ glog 224 $ glog
231 @ 12:3932c176bbaa@default(draft) bk:[] More addition 225 @ 12:3932c176bbaa@default(draft) bk:[] More addition
232 | 226 |
233 | o 11:3d968e0b3097@default(draft) bk:[] phase-divergent update to 1cf0aacfd363: 227 | o 11:8fc63fe1f297@default(draft) bk:[] phase-divergent update to 1cf0aacfd363:
234 | | 228 | |
235 o | 7:7bc2f5967f5e@default(draft) bk:[] add c 229 o | 7:7bc2f5967f5e@default(draft) bk:[] add c
236 | | 230 | |
237 | o 6:1cf0aacfd363@default(public) bk:[] newer a 231 | o 6:1cf0aacfd363@default(public) bk:[] newer a
238 |/ 232 |/
257 $ glog 251 $ glog
258 @ 14:eacc9c8240fe@default(draft) bk:[] More addition 252 @ 14:eacc9c8240fe@default(draft) bk:[] More addition
259 | 253 |
260 | * 13:d2f173e25686@default(draft) bk:[] More addition 254 | * 13:d2f173e25686@default(draft) bk:[] More addition
261 |/ 255 |/
262 | o 11:3d968e0b3097@default(draft) bk:[] phase-divergent update to 1cf0aacfd363: 256 | o 11:8fc63fe1f297@default(draft) bk:[] phase-divergent update to 1cf0aacfd363:
263 | | 257 | |
264 o | 7:7bc2f5967f5e@default(draft) bk:[] add c 258 o | 7:7bc2f5967f5e@default(draft) bk:[] add c
265 | | 259 | |
266 | o 6:1cf0aacfd363@default(public) bk:[] newer a 260 | o 6:1cf0aacfd363@default(public) bk:[] newer a
267 |/ 261 |/
307 working directory is now at f344982e63c4 301 working directory is now at f344982e63c4
308 $ hg st 302 $ hg st
309 $ glog 303 $ glog
310 @ 15:f344982e63c4@default(draft) bk:[] More addition 304 @ 15:f344982e63c4@default(draft) bk:[] More addition
311 | 305 |
312 | o 11:3d968e0b3097@default(draft) bk:[] phase-divergent update to 1cf0aacfd363: 306 | o 11:8fc63fe1f297@default(draft) bk:[] phase-divergent update to 1cf0aacfd363:
313 | | 307 | |
314 o | 7:7bc2f5967f5e@default(draft) bk:[] add c 308 o | 7:7bc2f5967f5e@default(draft) bk:[] add c
315 | | 309 | |
316 | o 6:1cf0aacfd363@default(public) bk:[] newer a 310 | o 6:1cf0aacfd363@default(public) bk:[] newer a
317 |/ 311 |/