Patchwork [3,of,4] tests: split long templates that use {whyunstable} and put them in hgrc

login
register
mail settings
Submitter Anton Shestakov
Date April 15, 2018, 12:37 p.m.
Message ID <b79993a8e173820205b2.1523795861@neuro>
Download mbox | patch
Permalink /patch/31079/
State Accepted
Headers show

Comments

Anton Shestakov - April 15, 2018, 12:37 p.m.
# HG changeset patch
# User Anton Shestakov <av6@dwimlabs.net>
# Date 1523791681 -28800
#      Sun Apr 15 19:28:01 2018 +0800
# Node ID b79993a8e173820205b21cb5c0821183bf68ed39
# Parent  bf715ddd88d1e4b0d3bd72d0f7ab6398662096ed
tests: split long templates that use {whyunstable} and put them in hgrc

Patch

diff --git a/tests/test-obsolete-divergent.t b/tests/test-obsolete-divergent.t
--- a/tests/test-obsolete-divergent.t
+++ b/tests/test-obsolete-divergent.t
@@ -16,6 +16,11 @@  Enable obsolete
   > debugobsolete = debugobsolete -d '0 0'
   > [phases]
   > publish=False
+  > [templates]
+  > wuentryshort = '{instability}:{divergentnodes} {reason} {node|shortest}\n'
+  > whyunstableshort = '{whyunstable % wuentryshort}'
+  > wuentryshorter = '{instability}:{divergentnodes % " {node|shortest} ({phase})"} {reason} {node|shortest}\n'
+  > whyunstableshorter = '{whyunstable % wuentryshorter}'
   > EOF
 
 
@@ -723,9 +728,9 @@  Use scmutil.cleanupnodes API to create d
 
   $ hg log -r 1a2a9b5b0030 -T '{whyunstable}\n'
   content-divergent: 4:70d5a63ca112 (draft) predecessor a178212c3433
-  $ hg log -r 1a2a9b5b0030 -T '{whyunstable % "{instability}:{divergentnodes} {reason} {node|shortest}\n"}'
+  $ hg log -r 1a2a9b5b0030 -T whyunstableshort
   content-divergent: 4:70d5a63ca112 (draft) predecessor a178
-  $ hg log -r 1a2a9b5b0030 -T '{whyunstable % "{instability}:{divergentnodes % " {node|shortest} ({phase})"} {reason} {node|shortest}\n"}'
+  $ hg log -r 1a2a9b5b0030 -T whyunstableshorter
   content-divergent: 70d5 (draft) predecessor a178
 
 #if serve