annotate tests/test-stabletailgraph.t @ 50911:1339158a8a40

cachedlocalrepo: use sysstr for attribute name of "file of interest" The first item is an attribute name, the second one is a filename. So the first one can (and should) be a `str`.
author Pierre-Yves David <pierre-yves.david@octobus.net>
date Wed, 30 Aug 2023 11:53:13 +0200
parents 027481f19944
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
1 ====================================
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
2 Test for the stabletailgraph package
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
3 ====================================
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
4
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
5 This test file contains a bunch of small test graphs with some minimal yet
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
6 non-trivial structure, on which the various stable-tail graph and stable-tail
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
7 sort functions are tested.
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
8
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
9 Each case consists of the creation of the interesting graph structure, followed
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
10 by a check, for each noteworthy node, of:
50528
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
11 - the stable-tail sort output (with the linear parts globbed),
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
12 - the leap set,
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
13 - the specific leap set.
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
14
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
15 In the ASCII art of the diagrams, the side of the exclusive part which is
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
16 followed in priority is denoted with "<" or ">" if it is on the left or right
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
17 respectively.
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
18
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
19 The intermediary linear parts in the example graph are there to force the
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
20 exclusive part choice (made on a min rank condition).
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
21
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
22
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
23 Setup
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
24 =====
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
25
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
26 Enable the rank computation to test sorting based on the rank.
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
27
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
28 $ cat << EOF >> $HGRCPATH
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
29 > [format]
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
30 > exp-use-changelog-v2=enable-unstable-format-and-corrupt-my-data
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
31 >
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
32 > [alias]
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
33 > test-sts = debug::stable-tail-sort -T '{tags},'
50528
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
34 > test-leaps = debug::stable-tail-sort-leaps -T '{tags}'
50461
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
35 > test-log = log --graph -T '{tags} rank={_fast_rank}' --rev 'tagged()'
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
36 > EOF
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
37
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
38
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
39 Example 1: single merge node
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
40 ============================
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
41
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
42 A base case with one branchpoint "b" and one merge node "e".
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
43
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
44 The exclusive part, starting with the lowest-ranking parent "c" of "e",
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
45 appears first in stable-tail sort of "e" and "f".
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
46
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
47 # f
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
48 # |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
49 # e
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
50 # |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
51 # --<--
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
52 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
53 # c d
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
54 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
55 # --+-- <- at this point, the sort of "e" is done consuming its
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
56 # | exclusive part [c] and jumps back to its other parent "d"
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
57 # b
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
58 # |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
59 # a
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
60
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
61 $ hg init example-1
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
62 $ cd example-1
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
63 $ hg debugbuilddag '.:a*a:b*b:c<b+2:d*c/d:e*e:f.'
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
64 $ hg test-log
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
65 o f rank=7
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
66 |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
67 o e rank=6
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
68 |\
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
69 | o d rank=4
50461
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
70 | :
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
71 o : c rank=3
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
72 :/
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
73 o b rank=2
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
74 |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
75 o a rank=1
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
76
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
77
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
78 Check the sort of the base linear case.
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
79
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
80 $ hg test-sts c
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
81 c,b,a, (no-eol)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
82
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
83 Check the stable-tail sort of "e": "c" should come before "d".
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
84
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
85 $ hg test-sts e
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
86 e,c,d,*,b,a, (no-eol) (glob)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
87
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
88 Check that the linear descendant of the merge inherits its sort properly.
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
89
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
90 $ hg test-sts f
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
91 f,e,c,d,*,b,a, (no-eol) (glob)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
92
50528
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
93 Check the leaps of "e": arriving at "c", the sort continues at "d", which
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
94 which breaks the child-parent chain and results in a leap.
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
95
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
96 $ hg test-leaps e
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
97 cd
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
98
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
99 Check that this leap is indeed specific to "e", i.e. that it appears in its
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
100 stable-tail sort, but not in any stable-tail sort of its ancestors.
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
101
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
102 $ hg test-leaps --specific e
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
103
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
104 Check that this leap is inherited by its direct ancestor "f".
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
105
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
106 $ hg test-leaps f
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
107 cd
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
108
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
109 Check that this leap is not classified as specific to "f", since it is specific
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
110 to "e".
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
111
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
112 $ hg test-leaps --specific f
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
113
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
114 $ cd ..
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
115
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
116
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
117 Example 2: nested exclusive parts, without specific leap
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
118 ========================================================
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
119
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
120 "g" is a merge node whose exclusive part contains a merge node "e".
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
121 We check that the stable-tail sort recurses properly by delegating.
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
122
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
123 Notice that parts of the sort of "e" is an infix of the sort of "g".
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
124 This is an expected property of the sort.
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
125
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
126 # g
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
127 # |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
128 # ---<---
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
129 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
130 # e | <- while processing the sort in the exclusive part of "g"
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
131 # | | we recursively process the exclusive part of "e"
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
132 # --<-- f
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
133 # | | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
134 # c d |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
135 # | | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
136 # --+-- |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
137 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
138 # b |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
139 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
140 # ---+--- <- done with excl(g), jump to "f"
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
141 # |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
142 # a
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
143
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
144 $ hg init example-2
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
145 $ cd example-2
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
146 $ hg debugbuilddag '.:a*a:b*b:c<b+2:d*c/d:e<a+6:f*e/f:g.'
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
147 $ hg test-log
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
148 o g rank=13
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
149 |\
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
150 | o f rank=7
50461
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
151 | :
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
152 o : e rank=6
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
153 |\ \
50461
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
154 | o : d rank=4
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
155 | : :
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
156 o : : c rank=3
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
157 :/ /
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
158 o / b rank=2
50461
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
159 :/
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
160 o a rank=1
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
161
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
162 Display the sort of "e" for reference
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
163
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
164 $ hg test-sts e
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
165 e,c,d,*,b,a, (no-eol) (glob)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
166
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
167 Check the correctness of the sort of "g",
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
168 and that a part of the sort of "e" appears as an infix.
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
169
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
170 $ hg test-sts g
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
171 g,e,c,d,*,b,f,*,a, (no-eol) (glob)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
172
50528
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
173 Check the leaps of "e".
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
174
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
175 $ hg test-leaps e
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
176 cd
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
177
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
178 $ hg test-leaps --specific e
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
179
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
180 Check that "g" inherits a leap from "e" in addition of its own.
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
181
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
182 $ hg test-leaps g
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
183 cd
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
184 bf
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
185
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
186 Check that only the additional leap of "g" is classified as specific.
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
187
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
188 $ hg test-leaps --specific g
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
189
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
190 $ cd ..
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
191
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
192
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
193 Example 3: shadowing of a final leap
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
194 ====================================
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
195
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
196 We have a merge "f" whose exclusive part contains a merge "d".
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
197
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
198 The inherited parent of "d" is not in the exclusive part of "f".
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
199 At the end of the exclusive part of "d",
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
200 the leap to "c" is shadowed by the leap to "e", i.e. the inherited part to "f".
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
201
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
202 Notice that emitting "c" before "e" would break the reverse topological
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
203 ordering.
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
204
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
205 # f
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
206 # |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
207 # ---<---
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
208 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
209 # d |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
210 # | e
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
211 # --<-- |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
212 # | | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
213 # | +----
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
214 # b |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
215 # | c
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
216 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
217 # --+-- <- at this point, jumping to "e", not the shadowed "c"
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
218 # |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
219 # a
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
220
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
221 $ hg init example-3
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
222 $ cd example-3
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
223 $ hg debugbuilddag '.:a*a:b<a+2:c*b/c:d<c+3:e*d/e:f.'
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
224 $ hg test-log
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
225 o f rank=9
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
226 |\
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
227 | o e rank=6
50461
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
228 | :
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
229 o : d rank=5
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
230 |\:
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
231 | o c rank=3
50461
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
232 | :
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
233 o : b rank=2
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
234 :/
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
235 o a rank=1
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
236
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
237
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
238 Display the sort of "d" for reference:
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
239
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
240 $ hg test-sts d
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
241 d,b,c,*,a, (no-eol) (glob)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
242
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
243 Check that we leap from "b" directly to "e" (shadowing the leap to "c"),
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
244 and that "c" is then emitted after "e" (its descendant).
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
245
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
246 $ hg test-sts f
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
247 f,d,b,e,*,c,*,a, (no-eol) (glob)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
248
50528
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
249 Check the leaps of "d".
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
250
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
251 $ hg test-leaps d
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
252 bc
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
253
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
254 $ hg test-leaps --specific d
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
255
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
256 Check thet leaps of "f", which, despite being a descendant of "f", has a
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
257 different stable-tail sort which does not reuse any leap of "d".
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
258
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
259 $ hg test-leaps f
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
260 be
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
261
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
262 $ hg test-leaps --specific f
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
263
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
264 $ cd ..
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
265
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
266
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
267 Example 4: skipping over nested exclusive part (entirely)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
268 =========================================================
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
269
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
270 We have a merge "f" whose exclusive part contains a merge "d".
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
271
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
272 The exclusive part of "d" is not in the exclusive part of "f".
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
273 However, some of the inherited part of "d" is part of the exclusive part of "f"
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
274 and needs to be iterated over before leaping to the inherited part of "f".
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
275
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
276 The sort of "d" is partially reused for the ordering of the exclusive part of
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
277 "f". However the reused part is not contiguous in the sort of "d".
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
278
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
279 # f
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
280 # |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
281 # ---<---
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
282 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
283 # d |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
284 # | e
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
285 # -->-- | <- in the sort of "f", we need to skip "c" and leap to the
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
286 # | | | inherited part of "d"
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
287 # | +----
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
288 # b |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
289 # | c
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
290 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
291 # --+--
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
292 # |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
293 # a
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
294
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
295 $ hg init example-4
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
296 $ cd example-4
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
297 $ hg debugbuilddag '.:a*a+1:b<a+1:c*b/c:d<c+4:e*d/e:f.'
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
298 $ hg test-log
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
299 o f rank=10
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
300 |\
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
301 | o e rank=6
50461
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
302 | :
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
303 o : d rank=5
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
304 |\:
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
305 | o c rank=2
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
306 | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
307 o | b rank=3
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
308 |/
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
309 o a rank=1
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
310
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
311
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
312 Display the sort of "d" for reference:
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
313
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
314 $ hg test-sts d
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
315 d,c,b,*,a, (no-eol) (glob)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
316
50460
1e31eda9c845 stabletailgraph: fix typo in test
pacien <pacien.trangirard@pacien.net>
parents: 50426
diff changeset
317 Check that sort "f" leaps from "d" to "b":
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
318
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
319 $ hg test-sts f
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
320 f,d,b,*,e,*,c,a, (no-eol) (glob)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
321
50528
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
322 Check the leaps of "d".
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
323
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
324 $ hg test-leaps d
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
325 cb
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
326
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
327 $ hg test-leaps --specific d
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
328
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
329 Check the leaps of "f".
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
330
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
331 $ hg test-leaps f
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
332 db
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
333 e* (glob)
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
334
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
335 $ hg test-leaps --specific f
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
336 db
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
337
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
338 $ cd ..
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
339
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
340
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
341 Example 5: skipping over nested exclusive part (partially)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
342 ==========================================================
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
343
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
344 We have a merge "f" whose exclusive part contains a merge "d".
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
345
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
346 Similar to example 4, but the exclusive part of "d" is only partially
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
347 contained in the inherited part of "f".
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
348 So, we need to leap in the middle of the exclusive part of "d".
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
349
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
350 # f
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
351 # |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
352 # ---<---
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
353 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
354 # d |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
355 # | e
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
356 # -->-- |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
357 # | | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
358 # | g |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
359 # | | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
360 # | +---- <- in the sort of "f", leaping from "g" to "b"
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
361 # b |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
362 # | c
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
363 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
364 # --+--
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
365 # |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
366 # a
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
367
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
368 $ hg init example-5
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
369 $ cd example-5
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
370 $ hg debugbuilddag '.:a*a+2:b<a+1:c+1:g*b/g:d<c+6:e*d/e:f.'
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
371 $ hg test-log
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
372 o f rank=14
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
373 |\
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
374 | o e rank=8
50461
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
375 | :
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
376 o : d rank=7
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
377 |\ \
50461
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
378 | o : g rank=3
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
379 | :/
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
380 | o c rank=2
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
381 | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
382 o | b rank=4
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
383 |/
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
384 o a rank=1
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
385
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
386
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
387 Display the sort of "d" for reference:
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
388
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
389 $ hg test-sts d
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
390 d,g,c,b,*,a, (no-eol) (glob)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
391
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
392 Check that sort "f" leaps from "g" to "b":
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
393
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
394 $ hg test-sts f
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
395 f,d,g,b,*,e,*,c,a, (no-eol) (glob)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
396
50528
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
397 Check the leaps of "d".
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
398
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
399 $ hg test-leaps d
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
400 cb
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
401 $ hg test-leaps --specific d
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
402
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
403 Check the leaps of "f".
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
404
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
405 $ hg test-leaps f
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
406 gb
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
407 e* (glob)
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
408
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
409 $ hg test-leaps --specific f
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
410 gb
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
411
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
412 $ cd ..
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
413
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
414
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
415 Example 6: merge in the inherited part
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
416 ======================================
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
417
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
418 Variant of example 2, but with a merge ("f") in the inherited part of "g".
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
419
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
420 "g" is a merge node whose inherited part contains a merge node "f".
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
421 We check that the stable-tail sort delegates properly after the exclusive part.
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
422
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
423 # g
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
424 # |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
425 # ---<---
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
426 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
427 # d f
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
428 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
429 # | ---<---
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
430 # | | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
431 # | e c
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
432 # | | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
433 # ---+ | <- at this point, we're done (for good) with the exclusive
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
434 # | | part of "g"
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
435 # b |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
436 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
437 # ---+---
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
438 # |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
439 # a
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
440
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
441 $ hg init example-6
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
442 $ cd example-6
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
443 $ hg debugbuilddag '.:a*a:b<a+3:c*b:d*b:e*e/c:f*d/f:g.'
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
444 $ hg test-log
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
445 o g rank=9
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
446 |\
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
447 | o f rank=7
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
448 | |\
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
449 | | o e rank=3
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
450 | | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
451 o---+ d rank=3
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
452 / /
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
453 o | c rank=4
50461
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
454 : |
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
455 : o b rank=2
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
456 :/
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
457 o a rank=1
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
458
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
459
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
460 Display the sort of "f" for reference:
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
461
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
462 $ hg test-sts f
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
463 f,e,b,c,*,a, (no-eol) (glob)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
464
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
465 Check that the sort of "g" delegates to the sort of "f" after processing its
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
466 exclusive part of "g":
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
467
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
468 $ hg test-sts g
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
469 g,d,f,e,b,c,*,a, (no-eol) (glob)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
470
50528
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
471 Check the leaps of "f".
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
472
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
473 $ hg test-leaps f
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
474 bc
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
475
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
476 $ hg test-leaps --specific f
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
477
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
478 Check the leaps of "g".
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
479
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
480 $ hg test-leaps g
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
481 df
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
482 bc
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
483
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
484 $ hg test-leaps --specific g
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
485
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
486 $ cd ..
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
487
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
488
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
489 Example 7: postponed iteration of common exclusive ancestors
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
490 ============================================================
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
491
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
492 Sibling merges "j" and "k", with partially shared exclusive parts.
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
493
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
494 When considering the sort of "l", the iteration over this shared part cannot
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
495 happen when iterating over excl(j) and has to be postponed to excl(k).
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
496
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
497 # l
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
498 # |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
499 # ----<----
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
500 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
501 # j k
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
502 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
503 # -->-- --<--
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
504 # | | | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
505 # g e h i
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
506 # | | | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
507 # | --+-- | <- at this point, for the sort of "l", the iteration on
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
508 # f | | the end of excl(j) is postponed to the iteration of
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
509 # | d | excl(k)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
510 # | | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
511 # | c |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
512 # | | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
513 # ---+--- |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
514 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
515 # b |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
516 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
517 # ----+-----
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
518 # |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
519 # a
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
520
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
521 $ hg init example-7
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
522 $ cd example-7
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
523 $ hg debugbuilddag \
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
524 > '.:a*a:b*b:c*c:d*d:e*b:f<f+3:g<d+2:h<a+6:i*e/g:j*h/i:k*j/k:l.'
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
525 $ hg test-log
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
526 o l rank=20
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
527 |\
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
528 | o k rank=13
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
529 | |\
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
530 o \ \ j rank=10
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
531 |\ \ \
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
532 | | | o i rank=7
50461
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
533 | | | :
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
534 | | o : h rank=6
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
535 | | : :
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
536 | o : : g rank=6
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
537 | : : :
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
538 | o : : f rank=3
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
539 | | : :
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
540 o---+ : e rank=5
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
541 / / /
50461
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
542 | o : d rank=4
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
543 | | :
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
544 | o : c rank=3
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
545 |/ /
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
546 o / b rank=2
50461
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
547 :/
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
548 o a rank=1
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
549
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
550
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
551 Display the sort of "j" for reference:
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
552
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
553 $ hg test-sts j
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
554 j,e,d,c,g,*,f,b,a, (no-eol) (glob)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
555
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
556 Display the sort of "k" for reference:
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
557
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
558 $ hg test-sts k
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
559 k,h,*,d,c,b,i,*,a, (no-eol) (glob)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
560
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
561 Check that the common part of excl(j) and excl(k) is iterated over after "k":
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
562
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
563 $ hg test-sts l
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
564 l,j,e,g,*,f,k,h,*,d,c,b,i,*,a, (no-eol) (glob)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
565
50528
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
566 Check the leaps of "j".
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
567
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
568 $ hg test-leaps j
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
569 cg
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
570
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
571 $ hg test-leaps --specific j
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
572
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
573 Check the leaps of "k".
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
574
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
575 $ hg test-leaps k
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
576 bi
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
577
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
578 $ hg test-leaps --specific k
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
579
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
580 Check the leaps of "l".
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
581
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
582 $ hg test-leaps l
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
583 eg
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
584 fk
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
585 bi
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
586
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
587 $ hg test-leaps --specific l
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
588 eg
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
589
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
590 $ cd ..
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
591
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
592
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
593 Example 8: postponed iteration of common ancestors between parts
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
594 ================================================================
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
595
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
596 Sibling merges "g" and "i", with some part shared between the inherited part
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
597 of "g" and the exclusive part of "i".
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
598
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
599 When considering the sort of "j", the iteration over this shared part cannot
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
600 happen when iterating over inherited(g) and has to be postponed to excl(i).
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
601
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
602 # j
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
603 # |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
604 # ----<----
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
605 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
606 # g i
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
607 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
608 # --<-- --<--
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
609 # | | | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
610 # c f | h
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
611 # | | | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
612 # | --+-- | <- at this point, for the sort of "j", the iteration
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
613 # | | | on the end of inherited(g) is postponed to the
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
614 # | e | iteration of excl(k)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
615 # | | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
616 # ---+--- |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
617 # b |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
618 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
619 # ----+-----
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
620 # |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
621 # a
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
622
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
623 $ hg init example-8
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
624 $ cd example-8
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
625 $ hg debugbuilddag '.:a*a:b*b:c*b:d*d:e*e:f*c/f:g<a+5:h*e/h:i*g/i:j.'
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
626 $ hg test-log
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
627 o j rank=14
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
628 |\
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
629 | o i rank=10
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
630 | |\
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
631 | | o h rank=6
50461
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
632 | | :
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
633 o | : g rank=7
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
634 |\ \ \
50461
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
635 | o | : f rank=5
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
636 | |/ /
50461
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
637 | o : e rank=4
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
638 | | :
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
639 | o : d rank=3
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
640 | | :
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
641 o | : c rank=3
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
642 |/ /
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
643 o / b rank=2
50461
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
644 :/
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
645 o a rank=1
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
646
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
647
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
648 Display the sort of "g" for reference:
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
649
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
650 $ hg test-sts g
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
651 g,c,f,e,d,b,a, (no-eol)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
652
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
653 Display the sort of "i" for reference:
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
654
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
655 $ hg test-sts i
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
656 i,e,d,b,h,*,a, (no-eol) (glob)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
657
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
658 Check that the common part of inherited(g) and excl(k) is iterated over after
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
659 "i":
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
660
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
661 $ hg test-sts j
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
662 j,g,c,f,i,e,d,b,h,*,a, (no-eol) (glob)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
663
50528
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
664 Check the leaps of "g".
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
665
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
666 $ hg test-leaps g
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
667 cf
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
668 $ hg test-leaps g
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
669 cf
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
670
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
671 Check the leaps of "i".
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
672
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
673 $ hg test-leaps i
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
674 bh
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
675
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
676 $ hg test-leaps --specific i
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
677
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
678 Check the leaps of "j".
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
679
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
680 $ hg test-leaps j
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
681 cf
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
682 fi
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
683 bh
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
684
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
685 $ hg test-leaps --specific j
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
686
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
687 $ cd ..
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
688
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
689
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
690 Example 9: postponed iteration of common ancestors between both parts
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
691 =====================================================================
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
692
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
693 This is a combination of example 7 and 8 at the same time.
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
694 Both excl(i) and excl(j) share a common part.
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
695 Same with inherited(i) and inherited(j).
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
696
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
697 We test that the walk on the common ancestors in both cases is properly
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
698 postponed when considering sort(k).
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
699
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
700 # k
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
701 # |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
702 # ----<----
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
703 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
704 # i j
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
705 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
706 # --<-- --<--
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
707 # | | | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
708 # c f g h
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
709 # | | | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
710 # | e | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
711 # | | | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
712 # +--]|[--- | <- rest of excl(i) postponed to excl(j)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
713 # | | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
714 # b ----+---- <- rest of inherited(i) postponed to inherited(j)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
715 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
716 # | d
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
717 # | |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
718 # ----+----
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
719 # |
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
720 # a
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
721
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
722 $ hg init example-9
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
723 $ cd example-9
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
724 $ hg debugbuilddag '.:a*a:b*b:c*a:d*d:e*e:f<b+2:g<d+3:h*c/f:i*g/h:j*i/j:k.'
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
725 $ hg test-log
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
726 o k rank=14
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
727 |\
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
728 | o j rank=9
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
729 | |\
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
730 o \ \ i rank=7
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
731 |\ \ \
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
732 | | | o h rank=5
50461
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
733 | | | :
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
734 | | o : g rank=4
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
735 | | : :
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
736 | o : : f rank=4
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
737 | | : :
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
738 | o---+ e rank=3
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
739 | / /
50461
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
740 | : o d rank=2
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
741 | : |
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
742 o : | c rank=3
a6522a7de594 stabletailgraph: omit uninteresting linear parts in test log
pacien <pacien.trangirard@pacien.net>
parents: 50460
diff changeset
743 :/ /
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
744 o / b rank=2
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
745 |/
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
746 o a rank=1
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
747
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
748
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
749 Display sort(i) for reference:
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
750
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
751 $ hg test-sts i
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
752 i,c,b,f,e,d,a, (no-eol)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
753
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
754 Display sort(j) for reference:
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
755
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
756 $ hg test-sts j
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
757 j,g,*,b,h,*,d,a, (no-eol) (glob)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
758
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
759 Check that the end of excl(i) is postponed to excl(j), the end of inherited(i)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
760 is postponed to inherited(j) in sort(k):
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
761
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
762 $ hg test-sts k
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
763 k,i,c,f,e,j,g,*,b,h,*,d,a, (no-eol) (glob)
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
764
50528
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
765 Check the leaps of "i".
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
766
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
767 $ hg test-leaps i
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
768 bf
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
769
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
770 $ hg test-leaps --specific i
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
771
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
772 Check the leaps of "j".
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
773
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
774 $ hg test-leaps j
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
775 bh
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
776
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
777 $ hg test-leaps --specific j
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
778
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
779 Check the leaps of "k".
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
780
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
781 $ hg test-leaps k
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
782 cf
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
783 ej
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
784 bh
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
785
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
786 $ hg test-leaps --specific k
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
787 cf
8fb3e942473a stabletailgraph: naive version of leap computation
pacien <pacien.trangirard@pacien.net>
parents: 50462
diff changeset
788
50426
f0d2b18f0274 stabletailgraph: implement stable-tail sort
pacien <pacien.trangirard@pacien.net>
parents:
diff changeset
789 $ cd ..
50529
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
790
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
791
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
792 Example 10: adjusting other leaps
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
793 =================================
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
794
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
795 This test checks the adjustment of leaps attached to other open merges in the
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
796 stack.
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
797
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
798 # o
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
799 # |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
800 # ------>------
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
801 # | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
802 # n l
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
803 # | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
804 # | ----<----
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
805 # | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
806 # | i k
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
807 # m | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
808 # | ---<--- |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
809 # | | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
810 # | d h |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
811 # | | | j
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
812 # | | g |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
813 # | c | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
814 # | | +-----
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
815 # -----+ |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
816 # | f
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
817 # b |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
818 # | e <- Done with excl(o) by element count, without
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
819 # | | having emitted "b". Implicitly unstack open
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
820 # ---+--- merges to leap e->n.
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
821 # |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
822 # a
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
823
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
824 $ hg init example-10
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
825 $ cd example-10
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
826 $ hg debugbuilddag '
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
827 > .:a
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
828 > *a:b.:c.:d
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
829 > *a:e.:f.:g.:h
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
830 > *d/h:i
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
831 > *f:j+6:k
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
832 > *i/k:l
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
833 > *b:m+15:n
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
834 > *n/l:o.
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
835 > '
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
836 $ hg test-log
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
837 o o rank=34
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
838 |\
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
839 | o n rank=18
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
840 | :
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
841 | o m rank=3
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
842 | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
843 o | l rank=17
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
844 |\ \
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
845 | o | k rank=10
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
846 | : |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
847 | o | j rank=4
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
848 | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
849 o | | i rank=9
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
850 |\ \ \
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
851 | o | | h rank=5
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
852 | | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
853 | o | | g rank=4
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
854 | |/ /
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
855 | o | f rank=3
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
856 | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
857 | o | e rank=2
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
858 | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
859 o | | d rank=4
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
860 | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
861 o---+ c rank=3
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
862 / /
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
863 | o b rank=2
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
864 |/
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
865 o a rank=1
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
866
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
867
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
868 Check the stable-tail sort of "o":
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
869
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
870 $ hg test-sts o
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
871 o,l,i,d,c,h,g,k,*,j,f,e,n,*,m,b,a, (no-eol) (glob)
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
872
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
873 Stale-tail sort of "l" for reference:
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
874
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
875 $ hg test-sts l
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
876 l,i,d,c,b,h,g,k,*,j,f,e,a, (no-eol) (glob)
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
877
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
878 Check the corresponding leaps:
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
879
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
880 $ hg test-leaps o
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
881 ch
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
882 gk
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
883 en
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
884
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
885 $ hg test-leaps --specific o
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
886 ch
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
887
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
888 $ hg test-leaps l
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
889 bh
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
890 gk
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
891
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
892 $ hg test-leaps --specific l
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
893
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
894 $ cd ..
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
895
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
896
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
897 Example 11: adjusting other leaps with the same destination
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
898 ===========================================================
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
899
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
900 This is a variant of the previous test, checking the adjustment of leaps having
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
901 the same destination in particular.
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
902
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
903 # r
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
904 # |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
905 # ------>------
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
906 # | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
907 # | o
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
908 # q |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
909 # | ------>------
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
910 # | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
911 # | n l
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
912 # | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
913 # | | ----<----
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
914 # p | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
915 # | | i k
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
916 # | m | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
917 # | | ---<--- |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
918 # | | | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
919 # | | d h |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
920 # | | | | j
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
921 # -----]|[---+ | | <- in sts(r): leap d->h
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
922 # | | g |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
923 # | c | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
924 # | | +-----
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
925 # -----+ | <- the leap c->h of sts(o)
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
926 # | f is shadowed in sts(r)
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
927 # b |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
928 # | e
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
929 # | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
930 # ---+---
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
931 # |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
932 # a
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
933
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
934 $ hg init example-11
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
935 $ cd example-11
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
936 $ hg debugbuilddag '
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
937 > .:a
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
938 > *a:b.:c.:d
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
939 > *a:e.:f.:g.:h
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
940 > *d/h:i
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
941 > *f:j+6:k
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
942 > *i/k:l
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
943 > *b:m+15:n
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
944 > *n/l:o
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
945 > *c:p+31:q
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
946 > *o/q:r.
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
947 > '
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
948 $ hg test-log
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
949 o r rank=67
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
950 |\
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
951 | o q rank=35
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
952 | :
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
953 | o p rank=4
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
954 | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
955 o | o rank=34
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
956 |\ \
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
957 | o | n rank=18
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
958 | : |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
959 | o | m rank=3
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
960 | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
961 o | | l rank=17
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
962 |\ \ \
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
963 | o | | k rank=10
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
964 | : | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
965 | o | | j rank=4
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
966 | | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
967 o | | | i rank=9
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
968 |\ \ \ \
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
969 | o | | | h rank=5
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
970 | | | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
971 | o | | | g rank=4
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
972 | |/ / /
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
973 | o | | f rank=3
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
974 | | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
975 | o | | e rank=2
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
976 | | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
977 o-----+ d rank=4
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
978 / / /
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
979 | | o c rank=3
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
980 | |/
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
981 | o b rank=2
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
982 |/
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
983 o a rank=1
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
984
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
985
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
986 Check the stable-tail sort of "r":
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
987
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
988 $ hg test-sts r
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
989 r,o,l,i,d,h,g,k,*,j,f,e,n,*,m,q,*,p,c,b,a, (no-eol) (glob)
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
990
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
991 Stable-tail sort of "o" for reference:
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
992
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
993 $ hg test-sts o
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
994 o,l,i,d,c,h,g,k,*,j,f,e,n,*,m,b,a, (no-eol) (glob)
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
995
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
996 Check the associated leaps:
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
997
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
998 $ hg test-leaps r
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
999 dh
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1000 gk
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1001 en
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1002 mq
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1003
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1004 $ hg test-leaps --specific r
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1005 dh
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1006
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1007 $ hg test-leaps o
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1008 ch
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1009 gk
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1010 en
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1011
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1012 $ hg test-leaps --specific o
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1013 ch
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1014
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1015 $ cd ..
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1016
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1017
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1018 Example 12
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1019 ==========
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1020
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1021 This is a variant of the previous test, checking the adjustments of leaps
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1022 in the open merge stack having a lower destination (which should appear only
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1023 later in the stable-tail sort of the head).
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1024
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1025 # t
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1026 # |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1027 # ------>------
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1028 # | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1029 # | o
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1030 # s |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1031 # | ------>------
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1032 # | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1033 # | n l
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1034 # r | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1035 # | | ----<----
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1036 # | | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1037 # --<-- | i k
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1038 # | | m | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1039 # p q | ---<--- |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1040 # | | | | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1041 # | ---]|[--]|[----+ |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1042 # | | | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1043 # | | d h |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1044 # | | | | j
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1045 # -------]|[---+ | | <- d->k is sts(t)
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1046 # | | g |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1047 # | c | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1048 # | | +-----
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1049 # -----+ | <- c->h in sts(o), not applying in sts(t)
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1050 # | f
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1051 # b |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1052 # | e
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1053 # | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1054 # ---+---
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1055 # |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1056 # a
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1057
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1058 $ hg init example-12
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1059 $ cd example-12
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1060 $ hg debugbuilddag '
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1061 > .:a
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1062 > *a:b.:c.:d
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1063 > *a:e.:f.:g.:h
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1064 > *d/h:i
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1065 > *f:j+6:k
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1066 > *i/k:l
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1067 > *b:m+15:n
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1068 > *n/l:o
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1069 > *c:p
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1070 > *h:q
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1071 > *p/q:r+25:s
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1072 > *o/s:t.
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1073 > '
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1074 $ hg test-log
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1075 o t rank=63
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1076 |\
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1077 | o s rank=35
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1078 | :
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1079 | o r rank=10
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1080 | |\
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1081 | | o q rank=6
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1082 | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1083 | o | p rank=4
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1084 | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1085 o | | o rank=34
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1086 |\ \ \
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1087 | o | | n rank=18
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1088 | : | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1089 | o | | m rank=3
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1090 | | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1091 o | | | l rank=17
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1092 |\ \ \ \
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1093 | o | | | k rank=10
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1094 | : | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1095 | o | | | j rank=4
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1096 | | | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1097 o-------+ i rank=9
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1098 | | | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1099 | | | | o h rank=5
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1100 | | | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1101 | +-----o g rank=4
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1102 | | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1103 | o | | f rank=3
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1104 | | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1105 | o | | e rank=2
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1106 | | | |
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1107 o-----+ d rank=4
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1108 / / /
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1109 | | o c rank=3
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1110 | |/
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1111 | o b rank=2
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1112 |/
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1113 o a rank=1
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1114
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1115
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1116 Check the stable-tail sort of "t":
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1117
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1118 $ hg test-sts t
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1119 t,o,l,i,d,k,*,j,n,*,m,s,*,r,p,c,b,q,h,g,f,e,a, (no-eol) (glob)
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1120
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1121 Stable-tail sort of "o" for reference:
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1122
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1123 $ hg test-sts o
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1124 o,l,i,d,c,h,g,k,*,j,f,e,n,*,m,b,a, (no-eol) (glob)
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1125
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1126 Check the associated leaps:
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1127
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1128 $ hg test-leaps t
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1129 dk
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1130 jn
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1131 ms
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1132 bq
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1133
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1134 $ hg test-leaps --specific t
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1135 dk
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1136 jn
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1137
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1138 $ hg test-leaps o
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1139 ch
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1140 gk
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1141 en
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1142
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1143 $ hg test-leaps --specific o
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1144 ch
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1145
027481f19944 stabletailgraph: add test cases challenging the open merge stack
pacien <pacien.trangirard@pacien.net>
parents: 50528
diff changeset
1146 $ cd ..