diff tests/test-rebase-templates.t @ 42977:43c84b816445

rebase: track new nodes when --keep is set When --keep is passed with rebase, the new nodes created are not accessible from templates. This change enables accessing the newly-created nodes from nodechanges, just as if --keep was not set. Differential Revision: https://phab.mercurial-scm.org/D6880
author Paul Gossman <pgossman@janestreet.com>
date Wed, 25 Sep 2019 10:59:29 -0400
parents f56a30b844aa
children 96fcc37a9c80
line wrap: on
line diff
--- a/tests/test-rebase-templates.t	Sat Sep 21 13:42:23 2019 -0400
+++ b/tests/test-rebase-templates.t	Wed Sep 25 10:59:29 2019 -0400
@@ -55,3 +55,30 @@
 
   $ hg rebase -s 6 -d 4 -q -T "{nodechanges % '{oldnode}:{newnodes % ' {node} '}'}"
   d9d6773efc831c274eace04bc13e8e6412517139: f48cd65c6dc3d2acb55da54402a5b029546e546f  (no-eol)
+
+  $ hg log -G -T "{rev}:{node|short} {desc}"
+  o  7:f48cd65c6dc3 Added b
+  |
+  | @  5:df21b32134ba Added d
+  |/
+  o  4:849767420fd5 Added c
+  |
+  o  0:18d04c59bb5d Added a
+  
+
+
+  $ hg rebase -s 7 -d 5 -q --keep -T "{nodechanges % '{oldnode}:{newnodes % ' {node} '}'}"
+  f48cd65c6dc3d2acb55da54402a5b029546e546f: 6f7dda91e55e728fb798f3e44dbecf0ebaa83267  (no-eol)
+
+  $ hg log -G -T "{rev}:{node|short} {desc}"
+  o  8:6f7dda91e55e Added b
+  |
+  | o  7:f48cd65c6dc3 Added b
+  | |
+  @ |  5:df21b32134ba Added d
+  |/
+  o  4:849767420fd5 Added c
+  |
+  o  0:18d04c59bb5d Added a
+  
+