annotate tests/test-exchange-obsmarkers-case-D3.t @ 6575:1ecb25d771df

changelog: document tns precheck limitations on hg 5.2 and older
author Anton Shestakov <av6@dwimlabs.net>
date Wed, 18 Oct 2023 15:55:06 -0300
parents a8ff17479fb8
children f3e39a354378
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: 2266
diff changeset
1 ============================================
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
2 Testing obsolescence markers push: Cases D.3
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
3 ============================================
850
3618454a4da0 exchange: add test case for D.3
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: 2266
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: 2266
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: 2266
diff changeset
7 already on both side).
850
3618454a4da0 exchange: add test case for D.3
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: 2266
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: 2266
diff changeset
10 and applied. This does not tests "obsmarkers" discovery capabilities.
850
3618454a4da0 exchange: add test case for D.3
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: 2266
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: 2266
diff changeset
13 TestCase 3: missing prune target (prune not in "pushed set")
850
3618454a4da0 exchange: add test case for D.3
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: 2266
diff changeset
15 D.3 missing prune target (prune not in "pushed set")
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
16 ====================================================
850
3618454a4da0 exchange: add test case for D.3
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: 2266
diff changeset
18 .. {{{
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
19 .. A ø⇠✕ A'
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
20 .. | |
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
21 .. | ○ B
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
22 .. |/
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
23 .. ● O
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
24 .. }}}
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
25 ..
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
26 .. Marker exist from:
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
27 ..
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
28 .. * `A ø⇠o A'`
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
29 .. * A' (prune)
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
30 ..
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
31 .. Command runs:
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
32 ..
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
33 .. * hg push
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
34 ..
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
35 .. Expected exclude:
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
36 ..
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
37 .. * `A ø⇠o A'`
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
38 .. * A' (prune)
850
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
39
2268
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
40 Setup
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
41 -----
850
3618454a4da0 exchange: add test case for D.3
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: 2266
diff changeset
43 $ . $TESTDIR/testlib/exchange-obsmarker-util.sh
850
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
44
2268
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
45 initial
850
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
46
2266
fe4ca27ed700 tests: fix directory names in exchange-D3 test
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
47 $ setuprepos D.3
fe4ca27ed700 tests: fix directory names in exchange-D3 test
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
48 creating test repo for test case D.3
850
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
49 - pulldest
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
50 - main
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
51 - pushdest
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
52 cd into `main` and proceed with env setup
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
53 $ cd main
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
54 $ mkcommit A0
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
55 $ hg up -q 0
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
56 $ mkcommit B
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
57 created new head
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
58 $ mkcommit A1
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
59 $ hg debugobsolete `getid 'desc(A0)'` `getid 'desc(A1)'`
4871
a8ff17479fb8 branching: preserve test change on stable
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 4860
diff changeset
60 1 new obsolescence markers
2754
21f06d932231 test: update test output to match b11e8c67fb0f
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 2580
diff changeset
61 obsoleted 1 changesets
850
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
62 $ hg prune -d '0 0' .
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
63 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
4613
30a544904238 messages: standardize on "working copy is now at" including "is"
Martin von Zweigbergk <martinvonz@google.com>
parents: 3566
diff changeset
64 working directory is now at 35b183996678
1239
8a06b32061ce evolve: apply prune update before creating obsolescence markers
Laurent Charignon <lcharignon@fb.com>
parents: 1093
diff changeset
65 1 changesets pruned
2562
279ec10273b8 test-exchange-case-D3: avoid stripping obsolescence marker
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 2268
diff changeset
66 $ hg strip --hidden -q 'desc(A1)' --config devel.strip-obsmarkers=no
850
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
67 $ hg log -G --hidden
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
68 @ 35b183996678 (draft): B
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
69 |
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
70 | x 28b51eb45704 (draft): A0
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
71 |/
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
72 o a9bdc8b26820 (public): O
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
73
2268
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
74 $ inspect_obsmarkers
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
75 obsstore content
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
76 ================
3559
d166b3dc5e8a tests: do not glob out fixed dates
Martin von Zweigbergk <martinvonz@google.com>
parents: 2754
diff changeset
77 28b51eb45704506b5c603decd6bf7ac5e0f6a52f 6aa67a7b4baa6fb41b06aed38d5b1201436546e2 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
3566
e6bea259c227 prune: include "operation" metadata in obsmarkers
Martin von Zweigbergk <martinvonz@google.com>
parents: 3559
diff changeset
78 6aa67a7b4baa6fb41b06aed38d5b1201436546e2 0 {35b1839966785d5703a01607229eea932db42f87} (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '0', 'operation': 'prune', 'user': 'test'}
2268
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
79 obshashtree
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
80 ===========
2083
778afb036245 discovery: introduce a official 'obshash associated to a range
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 1239
diff changeset
81 a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04 0000000000000000000000000000000000000000
778afb036245 discovery: introduce a official 'obshash associated to a range
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 1239
diff changeset
82 28b51eb45704506b5c603decd6bf7ac5e0f6a52f 0000000000000000000000000000000000000000
3566
e6bea259c227 prune: include "operation" metadata in obsmarkers
Martin von Zweigbergk <martinvonz@google.com>
parents: 3559
diff changeset
83 35b1839966785d5703a01607229eea932db42f87 d864ed12a58243aaedc35c1d065dba31aa787d4c
2268
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
84 obshashrange
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
85 ============
2228
3b18440cca74 debugstablerange: improve output spacing
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2118
diff changeset
86 rev node index size depth obshash
3566
e6bea259c227 prune: include "operation" metadata in obsmarkers
Martin von Zweigbergk <martinvonz@google.com>
parents: 3559
diff changeset
87 2 35b183996678 0 2 2 d864ed12a582
e6bea259c227 prune: include "operation" metadata in obsmarkers
Martin von Zweigbergk <martinvonz@google.com>
parents: 3559
diff changeset
88 2 35b183996678 1 1 2 d864ed12a582
2228
3b18440cca74 debugstablerange: improve output spacing
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2118
diff changeset
89 0 a9bdc8b26820 0 1 1 000000000000
850
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
90 $ cd ..
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
91 $ cd ..
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
92
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
93 Actual Test
2268
f2ebe960998b tests: update test to match upstreamable version
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2266
diff changeset
94 -----------
850
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
95
2266
fe4ca27ed700 tests: fix directory names in exchange-D3 test
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
96 $ dotest D.3 O
fe4ca27ed700 tests: fix directory names in exchange-D3 test
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 2230
diff changeset
97 ## Running testcase D.3
850
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
98 # testing echange of "O" (a9bdc8b26820)
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
99 ## initial state
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
100 # obstore: main
3559
d166b3dc5e8a tests: do not glob out fixed dates
Martin von Zweigbergk <martinvonz@google.com>
parents: 2754
diff changeset
101 28b51eb45704506b5c603decd6bf7ac5e0f6a52f 6aa67a7b4baa6fb41b06aed38d5b1201436546e2 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
3566
e6bea259c227 prune: include "operation" metadata in obsmarkers
Martin von Zweigbergk <martinvonz@google.com>
parents: 3559
diff changeset
102 6aa67a7b4baa6fb41b06aed38d5b1201436546e2 0 {35b1839966785d5703a01607229eea932db42f87} (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '0', 'operation': 'prune', 'user': 'test'}
850
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
103 # obstore: pushdest
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
104 # obstore: pulldest
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
105 ## pushing "O" from main to pushdest
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
106 pushing to pushdest
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
107 searching for changes
1078
5717d023da63 obsexc: use the common discovery
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 1067
diff changeset
108 no changes found
850
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
109 ## post push state
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
110 # obstore: main
3559
d166b3dc5e8a tests: do not glob out fixed dates
Martin von Zweigbergk <martinvonz@google.com>
parents: 2754
diff changeset
111 28b51eb45704506b5c603decd6bf7ac5e0f6a52f 6aa67a7b4baa6fb41b06aed38d5b1201436546e2 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
3566
e6bea259c227 prune: include "operation" metadata in obsmarkers
Martin von Zweigbergk <martinvonz@google.com>
parents: 3559
diff changeset
112 6aa67a7b4baa6fb41b06aed38d5b1201436546e2 0 {35b1839966785d5703a01607229eea932db42f87} (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '0', 'operation': 'prune', 'user': 'test'}
850
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
113 # obstore: pushdest
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
114 # obstore: pulldest
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
115 ## pulling "a9bdc8b26820" from main into pulldest
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
116 pulling from main
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
117 no changes found
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
118 ## post pull state
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
119 # obstore: main
3559
d166b3dc5e8a tests: do not glob out fixed dates
Martin von Zweigbergk <martinvonz@google.com>
parents: 2754
diff changeset
120 28b51eb45704506b5c603decd6bf7ac5e0f6a52f 6aa67a7b4baa6fb41b06aed38d5b1201436546e2 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'}
3566
e6bea259c227 prune: include "operation" metadata in obsmarkers
Martin von Zweigbergk <martinvonz@google.com>
parents: 3559
diff changeset
121 6aa67a7b4baa6fb41b06aed38d5b1201436546e2 0 {35b1839966785d5703a01607229eea932db42f87} (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '0', 'operation': 'prune', 'user': 'test'}
850
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
122 # obstore: pushdest
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
123 # obstore: pulldest
3618454a4da0 exchange: add test case for D.3
Pierre-Yves David <pierre-yves.david@fb.com>
parents:
diff changeset
124