diff tests/test-evolve-content-divergent-interrupted.t @ 5730:a119432bafc1

divergence-resolution: deal with simple "just one moved case" earlier While deciding the resolution parent for content-divergence resolution, now we use 3-way merge logic to check, if only one of them was moved from its original position by comparing the parent of both divergent cset with parent of base.
author Sushil khanchi <sushilkhanchi97@gmail.com>
date Fri, 22 Jan 2021 05:37:43 +0100
parents 3a1e07c27e4a
children 8e4f6354b316 c0122b98356c
line wrap: on
line diff
--- a/tests/test-evolve-content-divergent-interrupted.t	Fri Jan 22 04:54:51 2021 +0100
+++ b/tests/test-evolve-content-divergent-interrupted.t	Fri Jan 22 05:37:43 2021 +0100
@@ -307,9 +307,11 @@
   merge:[6] added d
   with: [7] added d
   base: [4] added d
-  rebasing "divergent" content-divergent changeset 69bdd23a9b0d on ca1b80f7960a
-  merging c
-  warning: conflicts while merging c! (edit, then use 'hg resolve --mark')
+  rebasing "other" content-divergent changeset e49523854bc8 on c7586e2a9264
+  file 'c' was deleted in other but was modified in local.
+  You can use (c)hanged version, (d)elete, or leave (u)nresolved.
+  What do you want to do? u
+  1 files updated, 0 files merged, 0 files removed, 1 files unresolved
   unresolved merge conflicts
   (see 'hg help evolve.interrupted')
   [240]
@@ -360,7 +362,7 @@
   merge:[7] added d
   with: [8] added d
   base: [4] added d
-  rebasing "other" content-divergent changeset 33e4442acf98 on ca1b80f7960a
+  rebasing "divergent" content-divergent changeset e49523854bc8 on c7586e2a9264
   merging d
   warning: conflicts while merging d! (edit, then use 'hg resolve --mark')
   0 files updated, 0 files merged, 0 files removed, 1 files unresolved
@@ -505,7 +507,7 @@
   merge:[5] added d
   with: [7] added d
   base: [4] added d
-  rebasing "other" content-divergent changeset 517d4375cb72 on ca1b80f7960a
+  rebasing "divergent" content-divergent changeset e49523854bc8 on c7586e2a9264
   merging d
   warning: conflicts while merging d! (edit, then use 'hg resolve --mark')
   0 files updated, 0 files merged, 0 files removed, 1 files unresolved
@@ -515,12 +517,12 @@
 
   $ hg evolve --stop
   stopped the interrupted evolve
-  working directory is now at 517d4375cb72
+  working directory is now at e49523854bc8
 
   $ hg glog
-  @  7:517d4375cb72 added d
+  *  7:517d4375cb72 added d
   |   () draft
-  | *  5:e49523854bc8 added d
+  | @  5:e49523854bc8 added d
   | |   () draft
   | o  3:ca1b80f7960a added c
   | |   () draft
@@ -537,15 +539,16 @@
 
   $ echo babar > c
   $ hg add c
+  c already tracked!
   $ hg amend
   $ hg glog
-  @  8:8fd1c4bd144c added d
+  @  8:2d664a4ab749 added d
   |   () draft
-  | *  5:e49523854bc8 added d
+  | *  7:517d4375cb72 added d
   | |   () draft
-  | o  3:ca1b80f7960a added c
+  o |  3:ca1b80f7960a added c
   | |   () draft
-  | o  2:b1661037fa25 added b
+  o |  2:b1661037fa25 added b
   |/    () draft
   o  1:c7586e2a9264 added a
   |   () draft
@@ -553,45 +556,49 @@
       () draft
 
   $ hg evolve --content-divergent
-  merge:[5] added d
+  merge:[7] added d
   with: [8] added d
   base: [4] added d
-  rebasing "other" content-divergent changeset 8fd1c4bd144c on ca1b80f7960a
-  merging c
-  warning: conflicts while merging c! (edit, then use 'hg resolve --mark')
+  rebasing "other" content-divergent changeset 2d664a4ab749 on c7586e2a9264
+  file 'c' was deleted in local but was modified in other.
+  You can use (c)hanged version, leave (d)eleted, or leave (u)nresolved.
+  What do you want to do? u
+  merging d
+  warning: conflicts while merging d! (edit, then use 'hg resolve --mark')
+  0 files updated, 0 files merged, 0 files removed, 2 files unresolved
   unresolved merge conflicts
   (see 'hg help evolve.interrupted')
   [240]
 
   $ hg diff
-  diff -r ca1b80f7960a c
-  --- a/c	Thu Jan 01 00:00:00 1970 +0000
+  diff -r 517d4375cb72 c
+  --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
   +++ b/c	Thu Jan 01 00:00:00 1970 +0000
+  @@ -0,0 +1,1 @@
+  +babar
+  diff -r 517d4375cb72 d
+  --- a/d	Thu Jan 01 00:00:00 1970 +0000
+  +++ b/d	Thu Jan 01 00:00:00 1970 +0000
   @@ -1,1 +1,5 @@
-  +<<<<<<< destination: ca1b80f7960a - test: added c
-   foo
+  +<<<<<<< local: 517d4375cb72 - test: added d
+   foobar
   +=======
-  +babar
-  +>>>>>>> evolving:    8fd1c4bd144c - test: added d
-  diff -r ca1b80f7960a d
-  --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
-  +++ b/d	Thu Jan 01 00:00:00 1970 +0000
-  @@ -0,0 +1,1 @@
-  +foobar
+  +bar
+  +>>>>>>> other: e315463d94bd - test: added d
 
   $ hg evolve --stop
   stopped the interrupted evolve
-  working directory is now at ca1b80f7960a
+  working directory is now at 2d664a4ab749
 
 XXX: we should have preserved the wdir to be at rev 8
   $ hg glog
-  *  8:8fd1c4bd144c added d
+  @  8:2d664a4ab749 added d
   |   () draft
-  | *  5:e49523854bc8 added d
+  | *  7:517d4375cb72 added d
   | |   () draft
-  | @  3:ca1b80f7960a added c
+  o |  3:ca1b80f7960a added c
   | |   () draft
-  | o  2:b1661037fa25 added b
+  o |  2:b1661037fa25 added b
   |/    () draft
   o  1:c7586e2a9264 added a
   |   () draft