Show More
@@ -0,0 +1,79 b'' | |||||
|
1 | ==================================== | |||
|
2 | Testing head checking code: Case A-8 | |||
|
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 8: single-changeset branch indirect rewrite | |||
|
13 | ||||
|
14 | .. old-state: | |||
|
15 | .. | |||
|
16 | .. * 1-changeset branch | |||
|
17 | .. | |||
|
18 | .. new-state: | |||
|
19 | .. | |||
|
20 | .. * 1-changeset branch succeeding to A, through another unpushed changesets | |||
|
21 | .. | |||
|
22 | .. expected-result: | |||
|
23 | .. | |||
|
24 | .. * push allowed | |||
|
25 | .. | |||
|
26 | .. graph-summary: | |||
|
27 | .. | |||
|
28 | .. A' | |||
|
29 | .. A ΓΈβ ΓΈβ β A'' | |||
|
30 | .. |/ / | |||
|
31 | .. | / | |||
|
32 | .. |/ | |||
|
33 | .. β | |||
|
34 | ||||
|
35 | $ . $TESTDIR/testlib/push-checkheads-util.sh | |||
|
36 | ||||
|
37 | Test setup | |||
|
38 | ---------- | |||
|
39 | ||||
|
40 | $ mkdir A8 | |||
|
41 | $ cd A8 | |||
|
42 | $ setuprepos | |||
|
43 | creating basic server and client repo | |||
|
44 | updating to branch default | |||
|
45 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved | |||
|
46 | $ cd client | |||
|
47 | $ hg up 0 | |||
|
48 | 0 files updated, 0 files merged, 1 files removed, 0 files unresolved | |||
|
49 | $ mkcommit A1 | |||
|
50 | created new head | |||
|
51 | $ hg up 0 | |||
|
52 | 0 files updated, 0 files merged, 1 files removed, 0 files unresolved | |||
|
53 | $ mkcommit A2 | |||
|
54 | created new head | |||
|
55 | $ hg debugobsolete `getid "desc(A0)" ` `getid "desc(A1)"` | |||
|
56 | $ hg debugobsolete `getid "desc(A1)" ` `getid "desc(A2)"` | |||
|
57 | $ hg log -G --hidden | |||
|
58 | @ c1f8d089020f (draft): A2 | |||
|
59 | | | |||
|
60 | | x f6082bc4ffef (draft): A1 | |||
|
61 | |/ | |||
|
62 | | x 8aaa48160adc (draft): A0 | |||
|
63 | |/ | |||
|
64 | o 1e4be0697311 (public): root | |||
|
65 | ||||
|
66 | ||||
|
67 | Actual testing | |||
|
68 | -------------- | |||
|
69 | ||||
|
70 | $ hg push | |||
|
71 | pushing to $TESTTMP/A8/server (glob) | |||
|
72 | searching for changes | |||
|
73 | adding changesets | |||
|
74 | adding manifests | |||
|
75 | adding file changes | |||
|
76 | added 1 changesets with 1 changes to 1 files (+1 heads) | |||
|
77 | 2 new obsolescence markers | |||
|
78 | ||||
|
79 | $ cd ../.. |
General Comments 0
You need to be logged in to leave comments.
Login now