Mercurial > evolve
diff tests/test-evolve-content-divergence.t @ 3805:2410e7063692
evolve: implement resolution of content-divergence when on differet parents
This patch implements the basic version of resolution of content-divergence
changesets when they are on different parents but one of the parent is gca of
both the different parents.
The functionality first relocates the divergent changeset which was left behind
and then resolves the content-divergence like it resolves in normal cases.
This is a very basic implementation because it still does not work on
interrupted evolution. Test changes in this patch shows the basic functionality
working. The output of dry-run is also required to be tweaked in such cased.
Upcoming patches will add more tests and will improve the implementation to work
during conflicts too.
author | Pulkit Goyal <7895pulkit@gmail.com> |
---|---|
date | Fri, 01 Jun 2018 19:52:06 +0530 |
parents | 509b1e66f0b9 |
children | 99469bb3854e |
line wrap: on
line diff
--- a/tests/test-evolve-content-divergence.t Fri Jun 01 19:57:19 2018 +0530 +++ b/tests/test-evolve-content-divergence.t Fri Jun 01 19:52:06 2018 +0530 @@ -332,27 +332,40 @@ () [default] draft $ hg evolve --content-divergent - skipping 7ed0642d644b: have a different parent than da4b96f4a8d6 (not handled yet) - | 7ed0642d644b, da4b96f4a8d6 are not based on the same changeset. - | With the current state of its implementation, - | evolve does not work in that case. - | rebase one of them next to the other and run - | this command again. - | - either: hg rebase --dest 'p1(7ed0642d644b)' -r da4b96f4a8d6 - | - or: hg rebase --dest 'p1(da4b96f4a8d6)' -r 7ed0642d644b + merge:[5] added b + with: [6] added b + base: [2] added b + rebasing "other" content-divergent changeset da4b96f4a8d6 on c7586e2a9264 + updating to "local" side of the conflict: 7ed0642d644b + merging "other" content-divergent changeset '11f849d7159f' + 0 files updated, 0 files merged, 0 files removed, 0 files unresolved + nothing changed $ hg glog - * 6:da4b96f4a8d6 added b + @ 5:7ed0642d644b added b | () [default] draft - | @ 5:7ed0642d644b added b + | * 4:c41c793e0ef1 added d | | () [default] draft - | | * 4:c41c793e0ef1 added d - | | | () [default] draft - | | * 3:ca1b80f7960a added c - | | | () [default] draft - | | x 2:b1661037fa25 added b - | |/ () [default] draft - | o 1:c7586e2a9264 added a + | * 3:ca1b80f7960a added c + | | () [default] draft + | x 2:b1661037fa25 added b |/ () [default] draft + o 1:c7586e2a9264 added a + | () [default] draft o 0:8fa14d15e168 added hgignore () [default] draft + + $ hg exp + # HG changeset patch + # User test + # Date 0 0 + # Thu Jan 01 00:00:00 1970 +0000 + # Node ID 7ed0642d644bb9ad93d252dd9ffe7b4729febe48 + # Parent c7586e2a92645e473645847a7b69a6dc52be4276 + added b + + diff -r c7586e2a9264 -r 7ed0642d644b b + --- /dev/null Thu Jan 01 00:00:00 1970 +0000 + +++ b/b Thu Jan 01 00:00:00 1970 +0000 + @@ -0,0 +1,1 @@ + +bar