annotate tests/test-obsmarker-template.t @ 33040:2baef42a2881

bundle: make applybundle1() return a bundleoperation See previous commit for motivation. It already lets us share a little bit more code in commands.py.
author Martin von Zweigbergk <martinvonz@google.com>
date Wed, 21 Jun 2017 21:08:48 -0700
parents 7f1d07d2c8f8
children 53b3a1968aa6
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
1 This test file test the various templates related to obsmarkers.
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
2
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
3 Global setup
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
4 ============
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
5
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
6 $ . $TESTDIR/testlib/obsmarker-common.sh
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
7 $ cat >> $HGRCPATH <<EOF
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
8 > [ui]
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
9 > interactive = true
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
10 > [phases]
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
11 > publish=False
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
12 > [experimental]
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
13 > evolution=all
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
14 > [alias]
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
15 > tlog = log -G -T '{node|short}\
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
16 > {if(predecessors, "\n Predecessors: {predecessors}")}\
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
17 > {if(predecessors, "\n semi-colon: {join(predecessors, "; ")}")}\
32909
89610c586fa2 templatekw: reference predecessor node id as {node} in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32879
diff changeset
18 > {if(predecessors, "\n json: {predecessors|json}")}\
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
19 > {if(predecessors, "\n map: {join(predecessors % "{rev}:{node}", " ")}")}\n'
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
20 > EOF
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
21
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
22 Test templates on amended commit
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
23 ================================
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
24
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
25 Test setup
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
26 ----------
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
27
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
28 $ hg init $TESTTMP/templates-local-amend
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
29 $ cd $TESTTMP/templates-local-amend
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
30 $ mkcommit ROOT
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
31 $ mkcommit A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
32 $ echo 42 >> A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
33 $ hg commit --amend -m "A1"
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
34 $ hg commit --amend -m "A2"
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
35
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
36 $ hg log --hidden -G
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
37 @ changeset: 4:d004c8f274b9
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
38 | tag: tip
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
39 | parent: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
40 | user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
41 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
42 | summary: A2
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
43 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
44 | x changeset: 3:a468dc9b3633
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
45 |/ parent: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
46 | user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
47 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
48 | summary: A1
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
49 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
50 | x changeset: 2:f137d23bb3e1
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
51 | | user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
52 | | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
53 | | summary: temporary amend commit for 471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
54 | |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
55 | x changeset: 1:471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
56 |/ user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
57 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
58 | summary: A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
59 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
60 o changeset: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
61 user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
62 date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
63 summary: ROOT
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
64
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
65 Check templates
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
66 ---------------
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
67 $ hg up 'desc(A0)' --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
68 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
69
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
70 Predecessors template should show current revision as it is the working copy
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
71 $ hg tlog
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
72 o d004c8f274b9
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
73 | Predecessors: 1:471f378eab4c
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
74 | semi-colon: 1:471f378eab4c
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
75 | json: ["471f378eab4c5e25f6c77f785b27c936efb22874"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
76 | map: 1:471f378eab4c5e25f6c77f785b27c936efb22874
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
77 | @ 471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
78 |/
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
79 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
80
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
81 $ hg up 'desc(A1)' --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
82 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
83
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
84 Predecessors template should show current revision as it is the working copy
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
85 $ hg tlog
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
86 o d004c8f274b9
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
87 | Predecessors: 3:a468dc9b3633
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
88 | semi-colon: 3:a468dc9b3633
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
89 | json: ["a468dc9b36338b14fdb7825f55ce3df4e71517ad"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
90 | map: 3:a468dc9b36338b14fdb7825f55ce3df4e71517ad
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
91 | @ a468dc9b3633
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
92 |/
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
93 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
94
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
95 Predecessors template should show all the predecessors as we force their display
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
96 with --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
97 $ hg tlog --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
98 o d004c8f274b9
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
99 | Predecessors: 3:a468dc9b3633
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
100 | semi-colon: 3:a468dc9b3633
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
101 | json: ["a468dc9b36338b14fdb7825f55ce3df4e71517ad"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
102 | map: 3:a468dc9b36338b14fdb7825f55ce3df4e71517ad
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
103 | @ a468dc9b3633
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
104 |/ Predecessors: 1:471f378eab4c
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
105 | semi-colon: 1:471f378eab4c
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
106 | json: ["471f378eab4c5e25f6c77f785b27c936efb22874"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
107 | map: 1:471f378eab4c5e25f6c77f785b27c936efb22874
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
108 | x f137d23bb3e1
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
109 | |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
110 | x 471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
111 |/
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
112 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
113
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
114
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
115 Predecessors template shouldn't show anything as all obsolete commit are not
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
116 visible.
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
117 $ hg up 'desc(A2)'
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
118 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
119 $ hg tlog
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
120 @ d004c8f274b9
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
121 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
122 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
123
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
124 $ hg tlog --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
125 @ d004c8f274b9
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
126 | Predecessors: 3:a468dc9b3633
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
127 | semi-colon: 3:a468dc9b3633
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
128 | json: ["a468dc9b36338b14fdb7825f55ce3df4e71517ad"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
129 | map: 3:a468dc9b36338b14fdb7825f55ce3df4e71517ad
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
130 | x a468dc9b3633
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
131 |/ Predecessors: 1:471f378eab4c
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
132 | semi-colon: 1:471f378eab4c
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
133 | json: ["471f378eab4c5e25f6c77f785b27c936efb22874"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
134 | map: 1:471f378eab4c5e25f6c77f785b27c936efb22874
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
135 | x f137d23bb3e1
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
136 | |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
137 | x 471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
138 |/
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
139 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
140
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
141
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
142 Test templates with splitted commit
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
143 ===================================
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
144
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
145 $ hg init $TESTTMP/templates-local-split
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
146 $ cd $TESTTMP/templates-local-split
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
147 $ mkcommit ROOT
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
148 $ echo 42 >> a
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
149 $ echo 43 >> b
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
150 $ hg commit -A -m "A0"
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
151 adding a
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
152 adding b
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
153 $ hg log --hidden -G
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
154 @ changeset: 1:471597cad322
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
155 | tag: tip
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
156 | user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
157 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
158 | summary: A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
159 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
160 o changeset: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
161 user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
162 date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
163 summary: ROOT
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
164
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
165 # Simulate split
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
166 $ hg up -r "desc(ROOT)"
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
167 0 files updated, 0 files merged, 2 files removed, 0 files unresolved
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
168 $ echo 42 >> a
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
169 $ hg commit -A -m "A0"
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
170 adding a
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
171 created new head
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
172 $ echo 43 >> b
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
173 $ hg commit -A -m "A0"
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
174 adding b
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
175 $ hg debugobsolete `getid "1"` `getid "2"` `getid "3"`
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
176
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
177 $ hg log --hidden -G
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
178 @ changeset: 3:f257fde29c7a
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
179 | tag: tip
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
180 | user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
181 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
182 | summary: A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
183 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
184 o changeset: 2:337fec4d2edc
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
185 | parent: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
186 | user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
187 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
188 | summary: A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
189 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
190 | x changeset: 1:471597cad322
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
191 |/ user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
192 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
193 | summary: A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
194 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
195 o changeset: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
196 user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
197 date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
198 summary: ROOT
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
199
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
200 Check templates
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
201 ---------------
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
202
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
203 $ hg up 'obsolete()' --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
204 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
205
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
206 Predecessors template should show current revision as it is the working copy
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
207 $ hg tlog
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
208 o f257fde29c7a
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
209 | Predecessors: 1:471597cad322
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
210 | semi-colon: 1:471597cad322
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
211 | json: ["471597cad322d1f659bb169751be9133dad92ef3"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
212 | map: 1:471597cad322d1f659bb169751be9133dad92ef3
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
213 o 337fec4d2edc
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
214 | Predecessors: 1:471597cad322
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
215 | semi-colon: 1:471597cad322
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
216 | json: ["471597cad322d1f659bb169751be9133dad92ef3"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
217 | map: 1:471597cad322d1f659bb169751be9133dad92ef3
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
218 | @ 471597cad322
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
219 |/
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
220 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
221
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
222 $ hg up f257fde29c7a
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
223 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
224
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
225 Predecessors template should not show a predecessor as it's not displayed in
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
226 the log
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
227 $ hg tlog
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
228 @ f257fde29c7a
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
229 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
230 o 337fec4d2edc
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
231 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
232 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
233
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
234 Predecessors template should show both predecessors as we force their display
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
235 with --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
236 $ hg tlog --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
237 @ f257fde29c7a
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
238 | Predecessors: 1:471597cad322
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
239 | semi-colon: 1:471597cad322
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
240 | json: ["471597cad322d1f659bb169751be9133dad92ef3"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
241 | map: 1:471597cad322d1f659bb169751be9133dad92ef3
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
242 o 337fec4d2edc
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
243 | Predecessors: 1:471597cad322
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
244 | semi-colon: 1:471597cad322
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
245 | json: ["471597cad322d1f659bb169751be9133dad92ef3"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
246 | map: 1:471597cad322d1f659bb169751be9133dad92ef3
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
247 | x 471597cad322
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
248 |/
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
249 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
250
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
251 Test templates with folded commit
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
252 =================================
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
253
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
254 Test setup
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
255 ----------
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
256
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
257 $ hg init $TESTTMP/templates-local-fold
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
258 $ cd $TESTTMP/templates-local-fold
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
259 $ mkcommit ROOT
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
260 $ mkcommit A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
261 $ mkcommit B0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
262 $ hg log --hidden -G
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
263 @ changeset: 2:0dec01379d3b
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
264 | tag: tip
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
265 | user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
266 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
267 | summary: B0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
268 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
269 o changeset: 1:471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
270 | user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
271 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
272 | summary: A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
273 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
274 o changeset: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
275 user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
276 date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
277 summary: ROOT
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
278
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
279 Simulate a fold
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
280 $ hg up -r "desc(ROOT)"
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
281 0 files updated, 0 files merged, 2 files removed, 0 files unresolved
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
282 $ echo "A0" > A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
283 $ echo "B0" > B0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
284 $ hg commit -A -m "C0"
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
285 adding A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
286 adding B0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
287 created new head
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
288 $ hg debugobsolete `getid "desc(A0)"` `getid "desc(C0)"`
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
289 $ hg debugobsolete `getid "desc(B0)"` `getid "desc(C0)"`
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
290
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
291 $ hg log --hidden -G
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
292 @ changeset: 3:eb5a0daa2192
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
293 | tag: tip
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
294 | parent: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
295 | user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
296 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
297 | summary: C0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
298 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
299 | x changeset: 2:0dec01379d3b
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
300 | | user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
301 | | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
302 | | summary: B0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
303 | |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
304 | x changeset: 1:471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
305 |/ user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
306 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
307 | summary: A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
308 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
309 o changeset: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
310 user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
311 date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
312 summary: ROOT
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
313
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
314 Check templates
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
315 ---------------
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
316
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
317 $ hg up 'desc(A0)' --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
318 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
319
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
320 Predecessors template should show current revision as it is the working copy
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
321 $ hg tlog
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
322 o eb5a0daa2192
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
323 | Predecessors: 1:471f378eab4c
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
324 | semi-colon: 1:471f378eab4c
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
325 | json: ["471f378eab4c5e25f6c77f785b27c936efb22874"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
326 | map: 1:471f378eab4c5e25f6c77f785b27c936efb22874
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
327 | @ 471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
328 |/
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
329 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
330
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
331 $ hg up 'desc(B0)' --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
332 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
333
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
334 Predecessors template should show both predecessors as they should be both
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
335 displayed
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
336 $ hg tlog
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
337 o eb5a0daa2192
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
338 | Predecessors: 2:0dec01379d3b 1:471f378eab4c
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
339 | semi-colon: 2:0dec01379d3b; 1:471f378eab4c
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
340 | json: ["0dec01379d3be6318c470ead31b1fe7ae7cb53d5", "471f378eab4c5e25f6c77f785b27c936efb22874"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
341 | map: 2:0dec01379d3be6318c470ead31b1fe7ae7cb53d5 1:471f378eab4c5e25f6c77f785b27c936efb22874
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
342 | @ 0dec01379d3b
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
343 | |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
344 | x 471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
345 |/
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
346 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
347
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
348 $ hg up 'desc(C0)'
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
349 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
350
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
351 Predecessors template should not show predecessors as they are not displayed in
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
352 the log
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
353 $ hg tlog
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
354 @ eb5a0daa2192
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
355 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
356 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
357
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
358 Predecessors template should show both predecessors as we force their display
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
359 with --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
360 $ hg tlog --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
361 @ eb5a0daa2192
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
362 | Predecessors: 2:0dec01379d3b 1:471f378eab4c
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
363 | semi-colon: 2:0dec01379d3b; 1:471f378eab4c
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
364 | json: ["0dec01379d3be6318c470ead31b1fe7ae7cb53d5", "471f378eab4c5e25f6c77f785b27c936efb22874"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
365 | map: 2:0dec01379d3be6318c470ead31b1fe7ae7cb53d5 1:471f378eab4c5e25f6c77f785b27c936efb22874
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
366 | x 0dec01379d3b
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
367 | |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
368 | x 471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
369 |/
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
370 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
371
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
372
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
373 Test templates with divergence
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
374 ==============================
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
375
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
376 Test setup
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
377 ----------
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
378
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
379 $ hg init $TESTTMP/templates-local-divergence
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
380 $ cd $TESTTMP/templates-local-divergence
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
381 $ mkcommit ROOT
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
382 $ mkcommit A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
383 $ hg commit --amend -m "A1"
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
384 $ hg log --hidden -G
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
385 @ changeset: 2:fdf9bde5129a
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
386 | tag: tip
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
387 | parent: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
388 | user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
389 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
390 | summary: A1
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
391 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
392 | x changeset: 1:471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
393 |/ user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
394 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
395 | summary: A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
396 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
397 o changeset: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
398 user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
399 date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
400 summary: ROOT
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
401
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
402 $ hg update --hidden 'desc(A0)'
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
403 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
404 $ hg commit --amend -m "A2"
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
405 $ hg log --hidden -G
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
406 @ changeset: 3:65b757b745b9
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
407 | tag: tip
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
408 | parent: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
409 | user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
410 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
411 | trouble: divergent
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
412 | summary: A2
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
413 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
414 | o changeset: 2:fdf9bde5129a
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
415 |/ parent: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
416 | user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
417 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
418 | trouble: divergent
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
419 | summary: A1
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
420 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
421 | x changeset: 1:471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
422 |/ user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
423 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
424 | summary: A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
425 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
426 o changeset: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
427 user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
428 date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
429 summary: ROOT
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
430
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
431 $ hg commit --amend -m 'A3'
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
432 $ hg log --hidden -G
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
433 @ changeset: 4:019fadeab383
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
434 | tag: tip
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
435 | parent: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
436 | user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
437 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
438 | trouble: divergent
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
439 | summary: A3
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
440 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
441 | x changeset: 3:65b757b745b9
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
442 |/ parent: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
443 | user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
444 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
445 | summary: A2
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
446 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
447 | o changeset: 2:fdf9bde5129a
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
448 |/ parent: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
449 | user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
450 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
451 | trouble: divergent
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
452 | summary: A1
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
453 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
454 | x changeset: 1:471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
455 |/ user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
456 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
457 | summary: A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
458 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
459 o changeset: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
460 user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
461 date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
462 summary: ROOT
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
463
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
464
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
465 Check templates
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
466 ---------------
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
467
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
468 $ hg up 'desc(A0)' --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
469 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
470
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
471 Predecessors template should show current revision as it is the working copy
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
472 $ hg tlog
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
473 o 019fadeab383
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
474 | Predecessors: 1:471f378eab4c
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
475 | semi-colon: 1:471f378eab4c
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
476 | json: ["471f378eab4c5e25f6c77f785b27c936efb22874"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
477 | map: 1:471f378eab4c5e25f6c77f785b27c936efb22874
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
478 | o fdf9bde5129a
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
479 |/ Predecessors: 1:471f378eab4c
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
480 | semi-colon: 1:471f378eab4c
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
481 | json: ["471f378eab4c5e25f6c77f785b27c936efb22874"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
482 | map: 1:471f378eab4c5e25f6c77f785b27c936efb22874
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
483 | @ 471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
484 |/
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
485 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
486
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
487 $ hg up 'desc(A1)'
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
488 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
489
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
490 Predecessors template should not show predecessors as they are not displayed in
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
491 the log
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
492 $ hg tlog
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
493 o 019fadeab383
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
494 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
495 | @ fdf9bde5129a
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
496 |/
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
497 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
498
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
499 Predecessors template should the predecessors as we force their display with
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
500 --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
501 $ hg tlog --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
502 o 019fadeab383
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
503 | Predecessors: 3:65b757b745b9
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
504 | semi-colon: 3:65b757b745b9
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
505 | json: ["65b757b745b935093c87a2bccd877521cccffcbd"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
506 | map: 3:65b757b745b935093c87a2bccd877521cccffcbd
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
507 | x 65b757b745b9
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
508 |/ Predecessors: 1:471f378eab4c
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
509 | semi-colon: 1:471f378eab4c
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
510 | json: ["471f378eab4c5e25f6c77f785b27c936efb22874"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
511 | map: 1:471f378eab4c5e25f6c77f785b27c936efb22874
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
512 | @ fdf9bde5129a
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
513 |/ Predecessors: 1:471f378eab4c
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
514 | semi-colon: 1:471f378eab4c
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
515 | json: ["471f378eab4c5e25f6c77f785b27c936efb22874"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
516 | map: 1:471f378eab4c5e25f6c77f785b27c936efb22874
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
517 | x 471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
518 |/
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
519 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
520
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
521
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
522 Test templates with amended + folded commit
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
523 ===========================================
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
524
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
525 Test setup
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
526 ----------
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
527
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
528 $ hg init $TESTTMP/templates-local-amend-fold
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
529 $ cd $TESTTMP/templates-local-amend-fold
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
530 $ mkcommit ROOT
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
531 $ mkcommit A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
532 $ mkcommit B0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
533 $ hg commit --amend -m "B1"
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
534 $ hg log --hidden -G
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
535 @ changeset: 3:b7ea6d14e664
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
536 | tag: tip
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
537 | parent: 1:471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
538 | user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
539 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
540 | summary: B1
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
541 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
542 | x changeset: 2:0dec01379d3b
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
543 |/ user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
544 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
545 | summary: B0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
546 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
547 o changeset: 1:471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
548 | user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
549 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
550 | summary: A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
551 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
552 o changeset: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
553 user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
554 date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
555 summary: ROOT
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
556
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
557 # Simulate a fold
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
558 $ hg up -r "desc(ROOT)"
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
559 0 files updated, 0 files merged, 2 files removed, 0 files unresolved
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
560 $ echo "A0" > A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
561 $ echo "B0" > B0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
562 $ hg commit -A -m "C0"
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
563 adding A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
564 adding B0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
565 created new head
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
566 $ hg debugobsolete `getid "desc(A0)"` `getid "desc(C0)"`
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
567 $ hg debugobsolete `getid "desc(B1)"` `getid "desc(C0)"`
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
568
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
569 $ hg log --hidden -G
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
570 @ changeset: 4:eb5a0daa2192
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
571 | tag: tip
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
572 | parent: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
573 | user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
574 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
575 | summary: C0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
576 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
577 | x changeset: 3:b7ea6d14e664
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
578 | | parent: 1:471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
579 | | user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
580 | | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
581 | | summary: B1
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
582 | |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
583 | | x changeset: 2:0dec01379d3b
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
584 | |/ user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
585 | | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
586 | | summary: B0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
587 | |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
588 | x changeset: 1:471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
589 |/ user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
590 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
591 | summary: A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
592 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
593 o changeset: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
594 user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
595 date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
596 summary: ROOT
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
597
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
598 Check templates
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
599 ---------------
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
600
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
601 $ hg up 'desc(A0)' --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
602 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
603
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
604 Predecessors template should show current revision as it is the working copy
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
605 $ hg tlog
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
606 o eb5a0daa2192
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
607 | Predecessors: 1:471f378eab4c
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
608 | semi-colon: 1:471f378eab4c
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
609 | json: ["471f378eab4c5e25f6c77f785b27c936efb22874"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
610 | map: 1:471f378eab4c5e25f6c77f785b27c936efb22874
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
611 | @ 471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
612 |/
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
613 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
614
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
615 $ hg up 'desc(B0)' --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
616 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
617
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
618 Predecessors template should both predecessors as they are visible
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
619 $ hg tlog
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
620 o eb5a0daa2192
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
621 | Predecessors: 2:0dec01379d3b 1:471f378eab4c
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
622 | semi-colon: 2:0dec01379d3b; 1:471f378eab4c
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
623 | json: ["0dec01379d3be6318c470ead31b1fe7ae7cb53d5", "471f378eab4c5e25f6c77f785b27c936efb22874"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
624 | map: 2:0dec01379d3be6318c470ead31b1fe7ae7cb53d5 1:471f378eab4c5e25f6c77f785b27c936efb22874
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
625 | @ 0dec01379d3b
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
626 | |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
627 | x 471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
628 |/
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
629 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
630
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
631 $ hg up 'desc(B1)' --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
632 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
633
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
634 Predecessors template should both predecessors as they are visible
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
635 $ hg tlog
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
636 o eb5a0daa2192
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
637 | Predecessors: 1:471f378eab4c 3:b7ea6d14e664
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
638 | semi-colon: 1:471f378eab4c; 3:b7ea6d14e664
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
639 | json: ["471f378eab4c5e25f6c77f785b27c936efb22874", "b7ea6d14e664bdc8922221f7992631b50da3fb07"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
640 | map: 1:471f378eab4c5e25f6c77f785b27c936efb22874 3:b7ea6d14e664bdc8922221f7992631b50da3fb07
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
641 | @ b7ea6d14e664
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
642 | |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
643 | x 471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
644 |/
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
645 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
646
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
647 $ hg up 'desc(C0)'
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
648 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
649
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
650 Predecessors template should show no predecessors as they are both non visible
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
651 $ hg tlog
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
652 @ eb5a0daa2192
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
653 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
654 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
655
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
656 Predecessors template should show all predecessors as we force their display
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
657 with --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
658 $ hg tlog --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
659 @ eb5a0daa2192
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
660 | Predecessors: 1:471f378eab4c 3:b7ea6d14e664
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
661 | semi-colon: 1:471f378eab4c; 3:b7ea6d14e664
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
662 | json: ["471f378eab4c5e25f6c77f785b27c936efb22874", "b7ea6d14e664bdc8922221f7992631b50da3fb07"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
663 | map: 1:471f378eab4c5e25f6c77f785b27c936efb22874 3:b7ea6d14e664bdc8922221f7992631b50da3fb07
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
664 | x b7ea6d14e664
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
665 | | Predecessors: 2:0dec01379d3b
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
666 | | semi-colon: 2:0dec01379d3b
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
667 | | json: ["0dec01379d3be6318c470ead31b1fe7ae7cb53d5"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
668 | | map: 2:0dec01379d3be6318c470ead31b1fe7ae7cb53d5
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
669 | | x 0dec01379d3b
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
670 | |/
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
671 | x 471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
672 |/
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
673 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
674
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
675
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
676 Test template with pushed and pulled obs markers
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
677 ================================================
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
678
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
679 Test setup
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
680 ----------
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
681
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
682 $ hg init $TESTTMP/templates-local-remote-markers-1
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
683 $ cd $TESTTMP/templates-local-remote-markers-1
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
684 $ mkcommit ROOT
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
685 $ mkcommit A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
686 $ hg clone $TESTTMP/templates-local-remote-markers-1 $TESTTMP/templates-local-remote-markers-2
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
687 updating to branch default
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
688 2 files updated, 0 files merged, 0 files removed, 0 files unresolved
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
689 $ cd $TESTTMP/templates-local-remote-markers-2
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
690 $ hg log --hidden -G
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
691 @ changeset: 1:471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
692 | tag: tip
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
693 | user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
694 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
695 | summary: A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
696 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
697 o changeset: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
698 user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
699 date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
700 summary: ROOT
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
701
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
702 $ cd $TESTTMP/templates-local-remote-markers-1
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
703 $ hg commit --amend -m "A1"
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
704 $ hg commit --amend -m "A2"
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
705 $ hg log --hidden -G
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
706 @ changeset: 3:7a230b46bf61
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
707 | tag: tip
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
708 | parent: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
709 | user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
710 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
711 | summary: A2
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
712 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
713 | x changeset: 2:fdf9bde5129a
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
714 |/ parent: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
715 | user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
716 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
717 | summary: A1
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
718 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
719 | x changeset: 1:471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
720 |/ user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
721 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
722 | summary: A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
723 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
724 o changeset: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
725 user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
726 date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
727 summary: ROOT
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
728
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
729 $ cd $TESTTMP/templates-local-remote-markers-2
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
730 $ hg pull
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
731 pulling from $TESTTMP/templates-local-remote-markers-1 (glob)
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
732 searching for changes
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
733 adding changesets
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
734 adding manifests
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
735 adding file changes
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
736 added 1 changesets with 0 changes to 1 files (+1 heads)
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
737 2 new obsolescence markers
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
738 (run 'hg heads' to see heads, 'hg merge' to merge)
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
739 $ hg log --hidden -G
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
740 o changeset: 2:7a230b46bf61
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
741 | tag: tip
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
742 | parent: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
743 | user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
744 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
745 | summary: A2
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
746 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
747 | @ changeset: 1:471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
748 |/ user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
749 | date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
750 | summary: A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
751 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
752 o changeset: 0:ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
753 user: test
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
754 date: Thu Jan 01 00:00:00 1970 +0000
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
755 summary: ROOT
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
756
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
757
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
758 $ hg debugobsolete
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
759 471f378eab4c5e25f6c77f785b27c936efb22874 fdf9bde5129a28d4548fadd3f62b265cdd3b7a2e 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
760 fdf9bde5129a28d4548fadd3f62b265cdd3b7a2e 7a230b46bf61e50b30308c6cfd7bd1269ef54702 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
761
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
762 Check templates
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
763 ---------------
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
764
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
765 Predecessors template should show current revision as it is the working copy
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
766 $ hg tlog
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
767 o 7a230b46bf61
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
768 | Predecessors: 1:471f378eab4c
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
769 | semi-colon: 1:471f378eab4c
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
770 | json: ["471f378eab4c5e25f6c77f785b27c936efb22874"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
771 | map: 1:471f378eab4c5e25f6c77f785b27c936efb22874
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
772 | @ 471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
773 |/
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
774 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
775
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
776 $ hg up 'desc(A2)'
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
777 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
778
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
779 Predecessors template should show no predecessors as they are non visible
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
780 $ hg tlog
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
781 @ 7a230b46bf61
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
782 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
783 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
784
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
785 Predecessors template should show all predecessors as we force their display
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
786 with --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
787 $ hg tlog --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
788 @ 7a230b46bf61
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
789 | Predecessors: 1:471f378eab4c
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
790 | semi-colon: 1:471f378eab4c
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
791 | json: ["471f378eab4c5e25f6c77f785b27c936efb22874"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
792 | map: 1:471f378eab4c5e25f6c77f785b27c936efb22874
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
793 | x 471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
794 |/
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
795 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
796
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
797
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
798 Test template with obsmarkers cycle
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
799 ===================================
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
800
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
801 Test setup
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
802 ----------
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
803
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
804 $ hg init $TESTTMP/templates-local-cycle
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
805 $ cd $TESTTMP/templates-local-cycle
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
806 $ mkcommit ROOT
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
807 $ mkcommit A0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
808 $ mkcommit B0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
809 $ hg up -r 0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
810 0 files updated, 0 files merged, 2 files removed, 0 files unresolved
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
811 $ mkcommit C0
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
812 created new head
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
813
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
814 Create the cycle
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
815
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
816 $ hg debugobsolete `getid "desc(A0)"` `getid "desc(B0)"`
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
817 $ hg debugobsolete `getid "desc(B0)"` `getid "desc(C0)"`
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
818 $ hg debugobsolete `getid "desc(B0)"` `getid "desc(A0)"`
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
819
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
820 Check templates
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
821 ---------------
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
822
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
823 $ hg tlog
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
824 @ f897c6137566
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
825 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
826 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
827
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
828
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
829 $ hg up -r "desc(B0)" --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
830 2 files updated, 0 files merged, 1 files removed, 0 files unresolved
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
831 $ hg tlog
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
832 o f897c6137566
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
833 | Predecessors: 2:0dec01379d3b
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
834 | semi-colon: 2:0dec01379d3b
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
835 | json: ["0dec01379d3be6318c470ead31b1fe7ae7cb53d5"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
836 | map: 2:0dec01379d3be6318c470ead31b1fe7ae7cb53d5
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
837 | @ 0dec01379d3b
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
838 | | Predecessors: 1:471f378eab4c
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
839 | | semi-colon: 1:471f378eab4c
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
840 | | json: ["471f378eab4c5e25f6c77f785b27c936efb22874"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
841 | | map: 1:471f378eab4c5e25f6c77f785b27c936efb22874
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
842 | x 471f378eab4c
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
843 |/ Predecessors: 2:0dec01379d3b
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
844 | semi-colon: 2:0dec01379d3b
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
845 | json: ["0dec01379d3be6318c470ead31b1fe7ae7cb53d5"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
846 | map: 2:0dec01379d3be6318c470ead31b1fe7ae7cb53d5
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
847 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
848
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
849
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
850 $ hg up -r "desc(A0)" --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
851 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
852 $ hg tlog
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
853 o f897c6137566
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
854 | Predecessors: 1:471f378eab4c
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
855 | semi-colon: 1:471f378eab4c
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
856 | json: ["471f378eab4c5e25f6c77f785b27c936efb22874"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
857 | map: 1:471f378eab4c5e25f6c77f785b27c936efb22874
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
858 | @ 471f378eab4c
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
859 |/
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
860 o ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
861
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
862
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
863 $ hg up -r "desc(ROOT)" --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
864 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
865 $ hg tlog
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
866 o f897c6137566
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
867 |
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
868 @ ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
869
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
870
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
871 $ hg tlog --hidden
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
872 o f897c6137566
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
873 | Predecessors: 2:0dec01379d3b
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
874 | semi-colon: 2:0dec01379d3b
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
875 | json: ["0dec01379d3be6318c470ead31b1fe7ae7cb53d5"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
876 | map: 2:0dec01379d3be6318c470ead31b1fe7ae7cb53d5
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
877 | x 0dec01379d3b
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
878 | | Predecessors: 1:471f378eab4c
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
879 | | semi-colon: 1:471f378eab4c
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
880 | | json: ["471f378eab4c5e25f6c77f785b27c936efb22874"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
881 | | map: 1:471f378eab4c5e25f6c77f785b27c936efb22874
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
882 | x 471f378eab4c
32911
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
883 |/ Predecessors: 2:0dec01379d3b
7f1d07d2c8f8 templatekw: use common "rev:node" format as the default of predecessors
Yuya Nishihara <yuya@tcha.org>
parents: 32910
diff changeset
884 | semi-colon: 2:0dec01379d3b
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
885 | json: ["0dec01379d3be6318c470ead31b1fe7ae7cb53d5"]
32910
498e9dcc5fa9 templatekw: populate all keywords depending on predecessor in map operation
Yuya Nishihara <yuya@tcha.org>
parents: 32909
diff changeset
886 | map: 2:0dec01379d3be6318c470ead31b1fe7ae7cb53d5
32879
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
887 @ ea207398892e
1858fc2327ef template: add predecessors template
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
888