annotate tests/test-exchange-obsmarkers-case-D2.t @ 3274:ddbb4d069203 mercurial-4.2

test-compat: merge mercurial-4.3 into mercurial-4.2
author Pierre-Yves David <pierre-yves.david@octobus.net>
date Mon, 11 Dec 2017 09:33:16 +0100
parents 2280461343e5
children 7a5c3175015e
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
2268
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
1 ============================================
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
2 Testing obsolescence markers push: Cases D.2
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
3 ============================================
849
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
4
2268
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
5 Mercurial pushes obsolescences markers relevant to the "pushed-set", the set of
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
6 all changesets that requested to be "in sync" after the push (even if they are
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
7 already on both side).
849
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
8
2268
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
9 This test belongs to a series of tests checking such set is properly computed
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
10 and applied. This does not tests "obsmarkers" discovery capabilities.
849
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
11
2268
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
12 Category D: Partial Information Case
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
13 TestCase 2: missing prune target (prune in "pushed set")
849
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
14
2268
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
15 D.2 missing prune target (prune in "pushed set")
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
16 ================================================
849
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
17
2268
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
18 .. {{{
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
19 .. A ø⇠✕ A'
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
20 .. |/
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
21 .. ● O
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
22 .. }}}
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
23 ..
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
24 .. Marker exist from:
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
25 ..
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
26 .. * A' succeed to A
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
27 .. * A' (prune)
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
28 ..
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
29 .. Command runs:
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
30 ..
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
31 .. * hg push
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
32 ..
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
33 .. Expected exchange:
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
34 ..
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
35 .. * `A ø⇠o A'`
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
36 .. * A' (prune)
849
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
37
2268
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
38 Setup
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
39 -----
849
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
40
2268
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
41 $ . $TESTDIR/testlib/exchange-obsmarker-util.sh
849
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
42
2268
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
43 Initial
849
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
44
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
45 $ setuprepos D.2
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
46 creating test repo for test case D.2
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
47 - pulldest
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
48 - main
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
49 - pushdest
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
50 cd into `main` and proceed with env setup
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
51 $ cd main
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
52 $ mkcommit A0
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
53 $ hg up -q 0
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
54 $ mkcommit A1
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
55 created new head
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
56 $ hg debugobsolete `getid 'desc(A0)'` `getid 'desc(A1)'`
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
57 $ hg prune --date '0 0' .
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
58 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
59 working directory now at a9bdc8b26820
1239
8a06b32061ce evolve: apply prune update before creating obsolescence markers
Laurent Charignon <lcharignon@fb.com>
parents: 1093
diff changeset
60 1 changesets pruned
2561
9c2b7b8f8f5d test-exchange-case-D2: avoid stripping obsolescence marker
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 2268
diff changeset
61 $ hg strip --hidden -q 'desc(A1)' --config devel.strip-obsmarkers=no
849
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
62 $ hg log -G --hidden
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
63 x 28b51eb45704 (draft): A0
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
64 |
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
65 @ a9bdc8b26820 (public): O
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
66
2268
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
67 $ inspect_obsmarkers
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
68 obsstore content
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
69 ================
2580
51a1dd295fe0 effectflag: activate effect flag for obsmarkers-case-*.t test files
Boris Feld <boris.feld@octobus.net>
parents: 2561
diff changeset
70 28b51eb45704506b5c603decd6bf7ac5e0f6a52f e5ea8f9c73143125d36658e90ef70c6d2027a5b7 0 (*) {'user': 'test'} (glob)
51a1dd295fe0 effectflag: activate effect flag for obsmarkers-case-*.t test files
Boris Feld <boris.feld@octobus.net>
parents: 2561
diff changeset
71 e5ea8f9c73143125d36658e90ef70c6d2027a5b7 0 {a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04} (*) {'ef1': '*', 'user': 'test'} (glob)
2268
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
72 obshashtree
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
73 ===========
2580
51a1dd295fe0 effectflag: activate effect flag for obsmarkers-case-*.t test files
Boris Feld <boris.feld@octobus.net>
parents: 2561
diff changeset
74 a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04 c14d90ad60c950e75009151899c742ce8cc9b2e6
51a1dd295fe0 effectflag: activate effect flag for obsmarkers-case-*.t test files
Boris Feld <boris.feld@octobus.net>
parents: 2561
diff changeset
75 28b51eb45704506b5c603decd6bf7ac5e0f6a52f e08003a7b0ea2ec7ec7e07708d34cf3819aa8009
2268
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
76 obshashrange
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
77 ============
2228
3b18440cca74 debugstablerange: improve output spacing
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2118
diff changeset
78 rev node index size depth obshash
2580
51a1dd295fe0 effectflag: activate effect flag for obsmarkers-case-*.t test files
Boris Feld <boris.feld@octobus.net>
parents: 2561
diff changeset
79 0 a9bdc8b26820 0 1 1 c14d90ad60c9
849
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
80 $ cd ..
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
81 $ cd ..
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
82
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
83 Actual Test
2268
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
84 -----------
849
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
85
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
86 $ dotest D.2
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
87 ## Running testcase D.2
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
88 ## initial state
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
89 # obstore: main
2580
51a1dd295fe0 effectflag: activate effect flag for obsmarkers-case-*.t test files
Boris Feld <boris.feld@octobus.net>
parents: 2561
diff changeset
90 28b51eb45704506b5c603decd6bf7ac5e0f6a52f e5ea8f9c73143125d36658e90ef70c6d2027a5b7 0 (*) {'user': 'test'} (glob)
51a1dd295fe0 effectflag: activate effect flag for obsmarkers-case-*.t test files
Boris Feld <boris.feld@octobus.net>
parents: 2561
diff changeset
91 e5ea8f9c73143125d36658e90ef70c6d2027a5b7 0 {a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04} (*) {'ef1': '*', 'user': 'test'} (glob)
849
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
92 # obstore: pushdest
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
93 # obstore: pulldest
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
94 ## pushing from main to pushdest
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
95 pushing to pushdest
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
96 searching for changes
1078
5717d023da63 obsexc: use the common discovery
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 1067
diff changeset
97 no changes found
1093
a49f2e7a2755 obsexch: respect todosteps when using the old push
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 1088
diff changeset
98 remote: 2 new obsolescence markers
849
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
99 ## post push state
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
100 # obstore: main
2580
51a1dd295fe0 effectflag: activate effect flag for obsmarkers-case-*.t test files
Boris Feld <boris.feld@octobus.net>
parents: 2561
diff changeset
101 28b51eb45704506b5c603decd6bf7ac5e0f6a52f e5ea8f9c73143125d36658e90ef70c6d2027a5b7 0 (*) {'user': 'test'} (glob)
51a1dd295fe0 effectflag: activate effect flag for obsmarkers-case-*.t test files
Boris Feld <boris.feld@octobus.net>
parents: 2561
diff changeset
102 e5ea8f9c73143125d36658e90ef70c6d2027a5b7 0 {a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04} (*) {'ef1': '*', 'user': 'test'} (glob)
849
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
103 # obstore: pushdest
2580
51a1dd295fe0 effectflag: activate effect flag for obsmarkers-case-*.t test files
Boris Feld <boris.feld@octobus.net>
parents: 2561
diff changeset
104 28b51eb45704506b5c603decd6bf7ac5e0f6a52f e5ea8f9c73143125d36658e90ef70c6d2027a5b7 0 (*) {'user': 'test'} (glob)
51a1dd295fe0 effectflag: activate effect flag for obsmarkers-case-*.t test files
Boris Feld <boris.feld@octobus.net>
parents: 2561
diff changeset
105 e5ea8f9c73143125d36658e90ef70c6d2027a5b7 0 {a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04} (*) {'ef1': '*', 'user': 'test'} (glob)
849
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
106 # obstore: pulldest
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
107 ## pulling from main into pulldest
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
108 pulling from main
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
109 searching for changes
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
110 no changes found
1093
a49f2e7a2755 obsexch: respect todosteps when using the old push
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 1088
diff changeset
111 2 new obsolescence markers
849
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
112 ## post pull state
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
113 # obstore: main
2580
51a1dd295fe0 effectflag: activate effect flag for obsmarkers-case-*.t test files
Boris Feld <boris.feld@octobus.net>
parents: 2561
diff changeset
114 28b51eb45704506b5c603decd6bf7ac5e0f6a52f e5ea8f9c73143125d36658e90ef70c6d2027a5b7 0 (*) {'user': 'test'} (glob)
51a1dd295fe0 effectflag: activate effect flag for obsmarkers-case-*.t test files
Boris Feld <boris.feld@octobus.net>
parents: 2561
diff changeset
115 e5ea8f9c73143125d36658e90ef70c6d2027a5b7 0 {a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04} (*) {'ef1': '*', 'user': 'test'} (glob)
849
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
116 # obstore: pushdest
2580
51a1dd295fe0 effectflag: activate effect flag for obsmarkers-case-*.t test files
Boris Feld <boris.feld@octobus.net>
parents: 2561
diff changeset
117 28b51eb45704506b5c603decd6bf7ac5e0f6a52f e5ea8f9c73143125d36658e90ef70c6d2027a5b7 0 (*) {'user': 'test'} (glob)
51a1dd295fe0 effectflag: activate effect flag for obsmarkers-case-*.t test files
Boris Feld <boris.feld@octobus.net>
parents: 2561
diff changeset
118 e5ea8f9c73143125d36658e90ef70c6d2027a5b7 0 {a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04} (*) {'ef1': '*', 'user': 'test'} (glob)
849
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
119 # obstore: pulldest
2580
51a1dd295fe0 effectflag: activate effect flag for obsmarkers-case-*.t test files
Boris Feld <boris.feld@octobus.net>
parents: 2561
diff changeset
120 28b51eb45704506b5c603decd6bf7ac5e0f6a52f e5ea8f9c73143125d36658e90ef70c6d2027a5b7 0 (*) {'user': 'test'} (glob)
51a1dd295fe0 effectflag: activate effect flag for obsmarkers-case-*.t test files
Boris Feld <boris.feld@octobus.net>
parents: 2561
diff changeset
121 e5ea8f9c73143125d36658e90ef70c6d2027a5b7 0 {a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04} (*) {'ef1': '*', 'user': 'test'} (glob)
849
cddac452fa40 exchange: add test case for D.2
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
122