comparison tests/test-evolve-list.t @ 1634:9ae4e79a28f3

evolve--list: initial implementation This implementation does not work with '-T json' since it needs multiple levels of depth. There is various small issue with the current data, the test coverage is a bit low and the output is likely to change, but this is a good step forward. Sample output: 01a3e66ba030: e (amended) unstable: 1995fc658ad6 (unstable parent) divergent: 84e1c6ae319d d3b90e9c84ab (precursor 3efa43a7427b) divergent: add9a356b8cf (precursor 3efa43a7427b) add9a356b8cf: e (rebased) divergent: 84e1c6ae319d d3b90e9c84ab (precursor 3efa43a7427b) divergent: 01a3e66ba030 (precursor 3efa43a7427b) 84e1c6ae319d: e (e+f split) unstable: 1995fc658ad6 (unstable parent) divergent: 01a3e66ba030 (precursor 3efa43a7427b) divergent: add9a356b8cf (precursor 3efa43a7427b) d3b90e9c84ab: f (e+f split) unstable: 84e1c6ae319d (unstable parent) divergent: 01a3e66ba030 (precursor 3efa43a7427b) divergent: add9a356b8cf (precursor 3efa43a7427b) 8febfaee0dd1: c unstable: 43765473b851 (obsolete parent) bumped: b36d99df9f41 (immutable precursor) 1995fc658ad6: d: commit with a long happy message, ababagalamaga, ababagal... unstable: 8febfaee0dd1 (unstable parent) fa8498ad030f: aa unstable: d3b90e9c84ab (unstable parent)
author Kostia Balytskyi <ikostia@fb.com>
date Tue, 22 Mar 2016 14:08:16 -0700
parents
children 7e1b49cda66c
comparison
equal deleted inserted replaced
1633:9bcb24c3ba8d 1634:9ae4e79a28f3
1 Set up some configs
2 $ cat >> $HGRCPATH <<EOF
3 > [extensions]
4 > rebase=
5 > EOF
6 $ echo "evolve=$(echo $(dirname $TESTDIR))/hgext/evolve.py" >> $HGRCPATH
7
8 Test the instability listing
9 $ hg init r2
10 $ cd r2
11 $ echo a > a && hg ci -Am a
12 adding a
13 $ echo b > b && hg ci -Am b
14 adding b
15 $ echo c > c && hg ci -Am c
16 adding c
17 $ hg up 0
18 0 files updated, 0 files merged, 2 files removed, 0 files unresolved
19 $ echo a >> a && hg ci --amend -m a
20 2 new unstable changesets
21 $ hg evolve --list
22 d2ae7f538514: b
23 unstable: cb9a9f314b8b (obsolete parent)
24
25 177f92b77385: c
26 unstable: d2ae7f538514 (unstable parent)
27
28 $ cd ..
29
30 Test the bumpedness listing
31 $ hg init r3
32 $ cd r3
33 $ echo a > a && hg ci -Am a
34 adding a
35 $ echo b > b && hg ci --amend -m ab
36 $ hg phase --public --rev 0 --hidden
37 1 new bumped changesets
38 $ hg evolve --list
39 88cc282e27fc: ab
40 bumped: cb9a9f314b8b (immutable precursor)
41
42 $ cd ..
43
44 Test the divergence listing
45 $ hg init r1
46 $ cd r1
47 $ echo a > a && hg ci -Am a
48 adding a
49 $ hg up 0
50 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
51 $ echo b > b && hg ci -Am b
52 adding b
53 $ hg up 0
54 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
55 $ echo c > c && hg ci -Am c
56 adding c
57 created new head
58 $ hg up 0
59 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
60 $ echo d > d && hg ci -Am d
61 adding d
62 created new head
63 $ hg rebase -s 1 -d 2
64 rebasing 1:d2ae7f538514 "b"
65 $ hg rebase -s 1 -d 3 --hidden --config experimental.allowdivergence=True
66 rebasing 1:d2ae7f538514 "b"
67 2 new divergent changesets
68 $ hg evolve --list
69 c882616e9d84: b
70 divergent: a922b3733e98 (precursor d2ae7f538514)
71
72 a922b3733e98: b
73 divergent: c882616e9d84 (precursor d2ae7f538514)
74
75 $ cd ..