Patchwork [2,of,2,evolve-ext] test-evolve-bumped: add new test case for merge

login
register
mail settings
Submitter Laurent Charignon
Date June 20, 2015, 1:38 a.m.
Message ID <459da3718f91405cf5a7.1434764304@schmidt-mbp.dhcp.thefacebook.com>
Download mbox | patch
Permalink /patch/9724/
State Accepted
Delegated to: Pierre-Yves David
Headers show

Comments

Laurent Charignon - June 20, 2015, 1:38 a.m.
# HG changeset patch
# User Laurent Charignon <lcharignon@fb.com>
# Date 1434763077 25200
#      Fri Jun 19 18:17:57 2015 -0700
# Node ID 459da3718f91405cf5a72b03ab58623a50b11d2b
# Parent  bd83396dd93f1c13efdba3140c2a92c6aed2be9f
test-evolve-bumped: add new test case for merge

Before this patch we were not testing our warning message for bumped changesets
that are the product of a merge. This patch adds a test case for that.
Pierre-Yves David - June 22, 2015, 10:14 p.m.
On 06/19/2015 06:38 PM, Laurent Charignon wrote:
> # HG changeset patch
> # User Laurent Charignon <lcharignon@fb.com>
> # Date 1434763077 25200
> #      Fri Jun 19 18:17:57 2015 -0700
> # Node ID 459da3718f91405cf5a72b03ab58623a50b11d2b
> # Parent  bd83396dd93f1c13efdba3140c2a92c6aed2be9f
> test-evolve-bumped: add new test case for merge
>
> Before this patch we were not testing our warning message for bumped changesets
> that are the product of a merge. This patch adds a test case for that.

I've pushed these ones with an update to the test comment and moving the 
rogue hunk from patch 1 to patch 2.

Patch

diff --git a/tests/test-evolve-bumped.t b/tests/test-evolve-bumped.t
--- a/tests/test-evolve-bumped.t
+++ b/tests/test-evolve-bumped.t
@@ -75,3 +75,46 @@ 
   computing new diff
   committed as 4d1169d82e47
   working directory is now at 4d1169d82e47
+
+Cannot automatically solve bumped changeset that is the product of a merge
+  $ mkcommit _a
+  $ hg up .^
+  0 files updated, 0 files merged, 1 files removed, 0 files unresolved
+  $ mkcommit _b
+  created new head
+  $ mkcommit _c
+  $ hg log -G
+  @  5:eeaf70969381@default(draft) add _c
+  |
+  o  4:6612fc0ddeb6@default(draft) add _b
+  |
+  | o  3:154ad198ff4a@default(draft) add _a
+  |/
+  o  1:4d1169d82e47@default(public) modify a
+  |
+  o  0:d3873e73d99e@default(public) init
+  
+  $ hg merge 3
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  (branch merge, don't forget to commit)
+  $ hg commit -m "merge"
+  $ hg commit --amend -m "New message"
+  $ hg phase --public 551127da2a8a --hidden
+  1 new bumped changesets
+  $ hg log -G
+  @    7:b28e84916d8c@default(draft) New message
+  |\
+  +---o  6:551127da2a8a@default(public) merge
+  | |/
+  | o  5:eeaf70969381@default(public) add _c
+  | |
+  | o  4:6612fc0ddeb6@default(public) add _b
+  | |
+  o |  3:154ad198ff4a@default(public) add _a
+  |/
+  o  1:4d1169d82e47@default(public) modify a
+  |
+  o  0:d3873e73d99e@default(public) init
+  
+  $ hg evolve --all --bumped
+  skipping b28e84916d8c : we do not handle merge yet