Mercurial > evolve
annotate tests/test-checkheads-unpushed-D4.t @ 2253:75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
We extend case A-6 and A-7 with partial counterpart. These case are interesting
because some of the partial pushing will (rightfully) works and some other won't.
author | Pierre-Yves David <pierre-yves.david@ens-lyon.org> |
---|---|
date | Wed, 29 Mar 2017 17:50:33 +0200 |
parents | |
children |
rev | line source |
---|---|
2253
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
1 ==================================== |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
2 Testing head checking code: Case D-4 |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
3 ==================================== |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
4 |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
5 Mercurial checks for the introduction of multiple heads on push. Evolution |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
6 comes into play to detect if existing heads on the server are being replaced by |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
7 some of the new heads we push. |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
8 |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
9 This test file is part of a series of tests checking this behavior. |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
10 |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
11 Category D: remote head is "obs-affected" locally, but result is not part of the push. |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
12 TestCase 4: multi-changeset branch, split on multiple other, (base on its own new branch) |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
13 |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
14 .. old-state: |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
15 .. |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
16 .. * 2 branch (1 changeset, and 2 changesets) |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
17 .. |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
18 .. new-state: |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
19 .. |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
20 .. * 1 new branch superceeding the base of the old-2-changesets-branch, |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
21 .. * 1 new changesets on the old-1-changeset-branch superceeding the head of the other |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
22 .. |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
23 .. expected-result: |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
24 .. |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
25 .. * push the new branch only -> push denied |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
26 .. * push the existing branch only -> push allowed |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
27 .. |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
28 .. graph-summary: |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
29 .. |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
30 .. B'◔⇢ø B |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
31 .. | | |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
32 .. A | ø⇠◔ A' |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
33 .. | |/ |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
34 .. C ● | |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
35 .. \| |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
36 .. ● |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
37 |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
38 $ . $TESTDIR/testlib/checkheads-util.sh |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
39 |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
40 Test setup |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
41 ---------- |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
42 |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
43 $ setuprepos |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
44 creating basic server and client repo |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
45 updating to branch default |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
46 2 files updated, 0 files merged, 0 files removed, 0 files unresolved |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
47 $ cd server |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
48 $ mkcommit B0 |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
49 $ hg up 0 |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
50 0 files updated, 0 files merged, 2 files removed, 0 files unresolved |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
51 $ mkcommit C0 |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
52 created new head |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
53 $ cd ../client |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
54 $ hg pull |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
55 pulling from $TESTTMP/server |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
56 searching for changes |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
57 adding changesets |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
58 adding manifests |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
59 adding file changes |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
60 added 2 changesets with 2 changes to 2 files (+1 heads) |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
61 (run 'hg heads' to see heads, 'hg merge' to merge) |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
62 $ hg up 0 |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
63 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
64 $ mkcommit A1 |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
65 created new head |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
66 $ hg up 'desc(C0)' |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
67 1 files updated, 0 files merged, 1 files removed, 0 files unresolved |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
68 $ mkcommit B1 |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
69 $ hg debugobsolete `getid "desc(A0)" ` `getid "desc(A1)"` |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
70 $ hg debugobsolete `getid "desc(B0)" ` `getid "desc(B1)"` |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
71 $ hg log -G --hidden |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
72 @ d70a1f75a020 (draft): B1 |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
73 | |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
74 | o f6082bc4ffef (draft): A1 |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
75 | | |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
76 o | 0f88766e02d6 (draft): C0 |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
77 |/ |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
78 | x d73caddc5533 (draft): B0 |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
79 | | |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
80 | x 8aaa48160adc (draft): A0 |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
81 |/ |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
82 o 1e4be0697311 (public): root |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
83 |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
84 |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
85 |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
86 Actual testing |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
87 -------------- |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
88 |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
89 $ hg push --rev 'desc(A1)' |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
90 pushing to $TESTTMP/server |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
91 searching for changes |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
92 abort: push creates new remote head f6082bc4ffef! |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
93 (merge or see 'hg help push' for details about pushing new heads) |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
94 [255] |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
95 $ hg push --rev 'desc(B1)' |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
96 pushing to $TESTTMP/server |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
97 searching for changes |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
98 adding changesets |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
99 adding manifests |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
100 adding file changes |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
101 added 1 changesets with 1 changes to 1 files |
75f73c031208
checkheads: add more complexe case where a branch is split on multiple ones
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
102 1 new obsolescence markers |