Mercurial > evolve
comparison tests/test-checkheads-pruned-B7.t @ 2254:446ed4c21bf6
check-heads: add tests about old heads indirectly pruned
author | Pierre-Yves David <pierre-yves.david@ens-lyon.org> |
---|---|
date | Fri, 31 Mar 2017 13:45:26 +0200 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
2253:75f73c031208 | 2254:446ed4c21bf6 |
---|---|
1 ==================================== | |
2 Testing head checking code: Case B-7 | |
3 ==================================== | |
4 | |
5 Mercurial checks for the introduction of multiple heads on push. Evolution | |
6 comes into play to detect if existing heads on the server are being replaced by | |
7 some of the new heads we push. | |
8 | |
9 This test file is part of a series of tests checking this behavior. | |
10 | |
11 Category B: checking simple case involving pruned changesets | |
12 TestCase 7: single changesets, pruned then superseeded (on an existing changeset) | |
13 | |
14 .. old-state: | |
15 .. | |
16 .. * 1 changeset branch | |
17 .. | |
18 .. new-state: | |
19 .. | |
20 .. * old branch is rewritten onto the common set, | |
21 .. * the new version is then pruned. | |
22 .. | |
23 .. expected-result: | |
24 .. | |
25 .. * push allowed | |
26 .. | |
27 .. graph-summary: | |
28 .. | |
29 .. A ø⇠⊗ A' | |
30 .. B ◔ | | | |
31 .. \|/ | |
32 .. ● | |
33 | |
34 $ . $TESTDIR/testlib/checkheads-util.sh | |
35 | |
36 Test setup | |
37 ---------- | |
38 | |
39 $ setuprepos | |
40 creating basic server and client repo | |
41 updating to branch default | |
42 2 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
43 $ cd client | |
44 $ hg up 0 | |
45 0 files updated, 0 files merged, 1 files removed, 0 files unresolved | |
46 $ mkcommit B0 | |
47 created new head | |
48 $ mkcommit A1 | |
49 $ hg up 'desc(B0)' | |
50 0 files updated, 0 files merged, 1 files removed, 0 files unresolved | |
51 $ hg debugobsolete `getid "desc(A0)"` `getid "desc(A1)"` | |
52 $ hg debugobsolete --record-parents `getid "desc(A1)"` | |
53 $ hg log -G --hidden | |
54 x ba93660aff8d (draft): A1 | |
55 | | |
56 @ 74ff5441d343 (draft): B0 | |
57 | | |
58 | x 8aaa48160adc (draft): A0 | |
59 |/ | |
60 o 1e4be0697311 (public): root | |
61 | |
62 | |
63 Actual testing | |
64 -------------- | |
65 | |
66 $ hg push | |
67 pushing to $TESTTMP/server | |
68 searching for changes | |
69 adding changesets | |
70 adding manifests | |
71 adding file changes | |
72 added 1 changesets with 1 changes to 1 files (+1 heads) | |
73 2 new obsolescence markers |