Mercurial > evolve
comparison tests/test-exchange-obsmarkers-case-C1.t @ 2268:f2ebe960998b stable
tests: update test to match upstreamable version
Name have been clarified, documentation has been updated and some test-case have
been updated to match the intended test.
author | Pierre-Yves David <pierre-yves.david@ens-lyon.org> |
---|---|
date | Sat, 08 Apr 2017 12:48:20 +0200 |
parents | tests/test-exchange-C1.t@a202f3af890c |
children | 5adb8bdb935e |
comparison
equal
deleted
inserted
replaced
2267:150fee60887a | 2268:f2ebe960998b |
---|---|
1 ============================================ | |
2 Testing obsolescence markers push: Cases C.1 | |
3 ============================================ | |
4 | |
5 Mercurial pushes obsolescences markers relevant to the "pushed-set", the set of | |
6 all changesets that requested to be "in sync" after the push (even if they are | |
7 already on both side). | |
8 | |
9 This test belongs to a series of tests checking such set is properly computed | |
10 and applied. This does not tests "obsmarkers" discovery capabilities. | |
11 | |
12 Category C: advanced case | |
13 TestCase 1: Multiple pruned changeset atop each other | |
14 Variants: | |
15 # a: explicite push | |
16 # b: bare push | |
17 | |
18 C.1 Multiple pruned changeset atop each other | |
19 ============================================= | |
20 | |
21 .. {{{ | |
22 .. ⊗ B | |
23 .. | | |
24 .. ⊗ A | |
25 .. | | |
26 .. ● O | |
27 .. }}} | |
28 .. | |
29 .. Marker exist from: | |
30 .. | |
31 .. * A (prune) | |
32 .. * B (prune) | |
33 .. | |
34 .. Commands run: | |
35 .. | |
36 .. * hg push -r O | |
37 .. * hg push | |
38 .. | |
39 .. Expected exchange: | |
40 .. | |
41 .. * A (prune) | |
42 .. * B (prune) | |
43 | |
44 Setup | |
45 ----- | |
46 | |
47 $ . $TESTDIR/testlib/exchange-obsmarker-util.sh | |
48 | |
49 Initial | |
50 | |
51 $ setuprepos C.1 | |
52 creating test repo for test case C.1 | |
53 - pulldest | |
54 - main | |
55 - pushdest | |
56 cd into `main` and proceed with env setup | |
57 $ cd main | |
58 $ mkcommit A | |
59 $ mkcommit B | |
60 $ hg prune -qd '0 0' '.~1' | |
61 1 new unstable changesets | |
62 $ hg prune -qd '0 0' . | |
63 $ hg log -G --hidden | |
64 x f6fbb35d8ac9 (draft): B | |
65 | | |
66 x f5bc6836db60 (draft): A | |
67 | | |
68 @ a9bdc8b26820 (public): O | |
69 | |
70 $ inspect_obsmarkers | |
71 obsstore content | |
72 ================ | |
73 f5bc6836db60e308a17ba08bf050154ba9c4fad7 0 {a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
74 f6fbb35d8ac958bbe70035e4c789c18471cdc0af 0 {f5bc6836db60e308a17ba08bf050154ba9c4fad7} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
75 obshashtree | |
76 =========== | |
77 a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04 1ce18e5a71f78d443a80c819f2f7197c4706af70 | |
78 f5bc6836db60e308a17ba08bf050154ba9c4fad7 92af733686ce7e0469d8b2b87b4612a4c2d33468 | |
79 f6fbb35d8ac958bbe70035e4c789c18471cdc0af 3800aeba3728457abb9c508c94f6abc59e698c55 | |
80 obshashrange | |
81 ============ | |
82 rev node index size depth obshash | |
83 0 a9bdc8b26820 0 1 1 1ce18e5a71f7 | |
84 $ cd .. | |
85 $ cd .. | |
86 | |
87 $ cp -R C.1 C.1.a | |
88 $ cp -R C.1 C.1.b | |
89 | |
90 Actual Test (explicit push) | |
91 --------------------------- | |
92 | |
93 $ dotest C.1.a O | |
94 ## Running testcase C.1.a | |
95 # testing echange of "O" (a9bdc8b26820) | |
96 ## initial state | |
97 # obstore: main | |
98 f5bc6836db60e308a17ba08bf050154ba9c4fad7 0 {a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
99 f6fbb35d8ac958bbe70035e4c789c18471cdc0af 0 {f5bc6836db60e308a17ba08bf050154ba9c4fad7} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
100 # obstore: pushdest | |
101 # obstore: pulldest | |
102 ## pushing "O" from main to pushdest | |
103 pushing to pushdest | |
104 searching for changes | |
105 no changes found | |
106 remote: 2 new obsolescence markers | |
107 ## post push state | |
108 # obstore: main | |
109 f5bc6836db60e308a17ba08bf050154ba9c4fad7 0 {a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
110 f6fbb35d8ac958bbe70035e4c789c18471cdc0af 0 {f5bc6836db60e308a17ba08bf050154ba9c4fad7} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
111 # obstore: pushdest | |
112 f5bc6836db60e308a17ba08bf050154ba9c4fad7 0 {a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
113 f6fbb35d8ac958bbe70035e4c789c18471cdc0af 0 {f5bc6836db60e308a17ba08bf050154ba9c4fad7} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
114 # obstore: pulldest | |
115 ## pulling "a9bdc8b26820" from main into pulldest | |
116 pulling from main | |
117 no changes found | |
118 2 new obsolescence markers | |
119 ## post pull state | |
120 # obstore: main | |
121 f5bc6836db60e308a17ba08bf050154ba9c4fad7 0 {a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
122 f6fbb35d8ac958bbe70035e4c789c18471cdc0af 0 {f5bc6836db60e308a17ba08bf050154ba9c4fad7} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
123 # obstore: pushdest | |
124 f5bc6836db60e308a17ba08bf050154ba9c4fad7 0 {a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
125 f6fbb35d8ac958bbe70035e4c789c18471cdc0af 0 {f5bc6836db60e308a17ba08bf050154ba9c4fad7} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
126 # obstore: pulldest | |
127 f5bc6836db60e308a17ba08bf050154ba9c4fad7 0 {a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
128 f6fbb35d8ac958bbe70035e4c789c18471cdc0af 0 {f5bc6836db60e308a17ba08bf050154ba9c4fad7} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
129 | |
130 Actual Test (bare push) | |
131 ------------------------------------- | |
132 | |
133 $ dotest C.1.b | |
134 ## Running testcase C.1.b | |
135 ## initial state | |
136 # obstore: main | |
137 f5bc6836db60e308a17ba08bf050154ba9c4fad7 0 {a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
138 f6fbb35d8ac958bbe70035e4c789c18471cdc0af 0 {f5bc6836db60e308a17ba08bf050154ba9c4fad7} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
139 # obstore: pushdest | |
140 # obstore: pulldest | |
141 ## pushing from main to pushdest | |
142 pushing to pushdest | |
143 searching for changes | |
144 no changes found | |
145 remote: 2 new obsolescence markers | |
146 ## post push state | |
147 # obstore: main | |
148 f5bc6836db60e308a17ba08bf050154ba9c4fad7 0 {a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
149 f6fbb35d8ac958bbe70035e4c789c18471cdc0af 0 {f5bc6836db60e308a17ba08bf050154ba9c4fad7} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
150 # obstore: pushdest | |
151 f5bc6836db60e308a17ba08bf050154ba9c4fad7 0 {a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
152 f6fbb35d8ac958bbe70035e4c789c18471cdc0af 0 {f5bc6836db60e308a17ba08bf050154ba9c4fad7} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
153 # obstore: pulldest | |
154 ## pulling from main into pulldest | |
155 pulling from main | |
156 searching for changes | |
157 no changes found | |
158 2 new obsolescence markers | |
159 ## post pull state | |
160 # obstore: main | |
161 f5bc6836db60e308a17ba08bf050154ba9c4fad7 0 {a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
162 f6fbb35d8ac958bbe70035e4c789c18471cdc0af 0 {f5bc6836db60e308a17ba08bf050154ba9c4fad7} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
163 # obstore: pushdest | |
164 f5bc6836db60e308a17ba08bf050154ba9c4fad7 0 {a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
165 f6fbb35d8ac958bbe70035e4c789c18471cdc0af 0 {f5bc6836db60e308a17ba08bf050154ba9c4fad7} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
166 # obstore: pulldest | |
167 f5bc6836db60e308a17ba08bf050154ba9c4fad7 0 {a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
168 f6fbb35d8ac958bbe70035e4c789c18471cdc0af 0 {f5bc6836db60e308a17ba08bf050154ba9c4fad7} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |