Mercurial > hg
annotate tests/test-push-checkheads-pruned-B1.t @ 32311:a77a75a428f7
run-tests: rename test description dict to testdesc
Previously the word "test" was used for both a Test instance and a path or
test dict. This patch renames them so it's clear that "testdesc" is the
dict, and "test" is the instance.
author | Jun Wu <quark@fb.com> |
---|---|
date | Tue, 16 May 2017 21:17:40 -0700 |
parents | c6cb21ddf74a |
children | 53b3a1968aa6 |
rev | line source |
---|---|
32009
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
1 ==================================== |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
2 Testing head checking code: Case B-1 |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
3 ==================================== |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
4 |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
5 Mercurial checks for the introduction of new heads on push. Evolution comes |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
6 into play to detect if existing branches on the server are being replaced by |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
7 some of the new one we push. |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
8 |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
9 This case is part of a series of tests checking this behavior. |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
10 |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
11 Category B: simple case involving pruned changesets |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
12 TestCase 1: single pruned changeset |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
13 |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
14 .. old-state: |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
15 .. |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
16 .. * 1 changeset branch |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
17 .. |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
18 .. new-state: |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
19 .. |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
20 .. * old branch is pruned |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
21 .. * 1 new unrelated branch |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
22 .. |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
23 .. expected-result: |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
24 .. |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
25 .. * push allowed |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
26 .. |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
27 .. graph-summary: |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
28 .. |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
29 .. ◔ B |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
30 .. | |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
31 .. A ⊗ | |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
32 .. |/ |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
33 .. ● |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
34 |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
35 $ . $TESTDIR/testlib/push-checkheads-util.sh |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
36 |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
37 Test setup |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
38 ---------- |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
39 |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
40 $ mkdir B1 |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
41 $ cd B1 |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
42 $ setuprepos |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
43 creating basic server and client repo |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
44 updating to branch default |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
45 2 files updated, 0 files merged, 0 files removed, 0 files unresolved |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
46 $ cd client |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
47 $ hg up 0 |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
48 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
49 $ mkcommit B0 |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
50 created new head |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
51 $ hg debugobsolete --record-parents `getid "desc(A0)"` |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
52 $ hg log -G --hidden |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
53 @ 74ff5441d343 (draft): B0 |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
54 | |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
55 | x 8aaa48160adc (draft): A0 |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
56 |/ |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
57 o 1e4be0697311 (public): root |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
58 |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
59 |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
60 Actual testing |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
61 -------------- |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
62 |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
63 $ hg push |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
64 pushing to $TESTTMP/B1/server (glob) |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
65 searching for changes |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
66 adding changesets |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
67 adding manifests |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
68 adding file changes |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
69 added 1 changesets with 1 changes to 1 files (+1 heads) |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
70 1 new obsolescence markers |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
71 |
c6cb21ddf74a
checkheads: upgrade the obsolescence postprocessing logic (issue4354)
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
72 $ cd ../.. |