Mercurial > evolve
comparison tests/test-push-checkheads-superceed-A7.t @ 2277:61d885899466 stable
checkheads: update tests to match the one in core
These test now exists in core, so we update the evolve version.
author | Pierre-Yves David <pierre-yves.david@ens-lyon.org> |
---|---|
date | Thu, 20 Apr 2017 12:24:43 +0200 |
parents | tests/test-checkheads-superceed-A7.t@2f71f6234b06 |
children | e22de367fc74 |
comparison
equal
deleted
inserted
replaced
2276:2d55ae0d6ce7 | 2277:61d885899466 |
---|---|
1 ==================================== | |
2 Testing head checking code: Case A-7 | |
3 ==================================== | |
4 | |
5 Mercurial checks for the introduction of new heads on push. Evolution comes | |
6 into play to detect if existing branches on the server are being replaced by | |
7 some of the new one we push. | |
8 | |
9 This case is part of a series of tests checking this behavior. | |
10 | |
11 Category A: simple case involving a branch being superceeded by another. | |
12 TestCase 7: multi-changeset branch, split on multiple other, (head on its own branch), same number of head | |
13 | |
14 .. old-state: | |
15 .. | |
16 .. * 2 branch (1-changeset, and 2-changesets) | |
17 .. | |
18 .. new-state: | |
19 .. | |
20 .. * 1 new branch superceeding the head of the old-2-changesets-branch, | |
21 .. * 1 new changesets on the old-1-changeset-branch superceeding the base of the other | |
22 .. | |
23 .. expected-result: | |
24 .. | |
25 .. * push allowed | |
26 .. | |
27 .. graph-summary: | |
28 .. | |
29 .. B ø⇠◔ B' | |
30 .. | | | |
31 .. A'◔⇢ø | | |
32 .. | |/ | |
33 .. C ● | | |
34 .. \| | |
35 .. ● | |
36 | |
37 $ . $TESTDIR/testlib/push-checkheads-util.sh | |
38 | |
39 Test setup | |
40 ---------- | |
41 | |
42 $ mkdir A7 | |
43 $ cd A7 | |
44 $ setuprepos | |
45 creating basic server and client repo | |
46 updating to branch default | |
47 2 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
48 $ cd server | |
49 $ mkcommit B0 | |
50 $ hg up 0 | |
51 0 files updated, 0 files merged, 2 files removed, 0 files unresolved | |
52 $ mkcommit C0 | |
53 created new head | |
54 $ cd ../client | |
55 $ hg pull | |
56 pulling from $TESTTMP/A7/server (glob) | |
57 searching for changes | |
58 adding changesets | |
59 adding manifests | |
60 adding file changes | |
61 added 2 changesets with 2 changes to 2 files (+1 heads) | |
62 (run 'hg heads' to see heads, 'hg merge' to merge) | |
63 $ hg up 'desc(C0)' | |
64 1 files updated, 0 files merged, 1 files removed, 0 files unresolved | |
65 $ mkcommit A1 | |
66 $ hg up 0 | |
67 0 files updated, 0 files merged, 2 files removed, 0 files unresolved | |
68 $ mkcommit B1 | |
69 created new head | |
70 $ hg debugobsolete `getid "desc(A0)" ` `getid "desc(A1)"` | |
71 $ hg debugobsolete `getid "desc(B0)" ` `getid "desc(B1)"` | |
72 $ hg log -G --hidden | |
73 @ 25c56d33e4c4 (draft): B1 | |
74 | | |
75 | o a0802eb7fc1b (draft): A1 | |
76 | | | |
77 | o 0f88766e02d6 (draft): C0 | |
78 |/ | |
79 | x d73caddc5533 (draft): B0 | |
80 | | | |
81 | x 8aaa48160adc (draft): A0 | |
82 |/ | |
83 o 1e4be0697311 (public): root | |
84 | |
85 | |
86 Actual testing | |
87 -------------- | |
88 | |
89 $ hg push | |
90 pushing to $TESTTMP/A7/server (glob) | |
91 searching for changes | |
92 adding changesets | |
93 adding manifests | |
94 adding file changes | |
95 added 2 changesets with 2 changes to 2 files (+1 heads) | |
96 2 new obsolescence markers | |
97 | |
98 $ cd ../.. |