|
1 ============================================ |
|
2 Testing obsolescence markers push: Cases B.5 |
|
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 B: pruning case |
|
13 TestCase 5: Push of a children of changeset which successors is pruned |
|
14 |
|
15 B.5 Push of a children of changeset which successors is pruned |
|
16 ============================================================== |
|
17 |
|
18 .. This case Mirror A.4, with pruned changeset successors. |
|
19 .. |
|
20 .. {{{ |
|
21 .. C ◔ |
|
22 .. | |
|
23 .. B⇠ø⇠⊗ B' |
|
24 .. | | |
|
25 .. A ø⇠○ A' |
|
26 .. |/ |
|
27 .. ● |
|
28 .. }}} |
|
29 .. |
|
30 .. Marker exist from: |
|
31 .. |
|
32 .. * `A ø⇠○ A'` |
|
33 .. * `B ø⇠○ B'` |
|
34 .. * chain from B |
|
35 .. * `B' is pruned` |
|
36 .. |
|
37 .. Command run: |
|
38 .. |
|
39 .. * hg push -r C |
|
40 .. |
|
41 .. Expected exchange: |
|
42 .. |
|
43 .. * chain from B |
|
44 .. |
|
45 .. Expected exclude: |
|
46 .. |
|
47 .. * `A ø⇠○ A'` |
|
48 .. * `B ø⇠○ B'` |
|
49 .. * `B' prune` |
|
50 |
|
51 Setup |
|
52 ----- |
|
53 |
|
54 $ . $TESTDIR/testlib/exchange-obsmarker-util.sh |
|
55 |
|
56 initial |
|
57 |
|
58 $ setuprepos B.5 |
|
59 creating test repo for test case B.5 |
|
60 - pulldest |
|
61 - main |
|
62 - pushdest |
|
63 cd into `main` and proceed with env setup |
|
64 $ cd main |
|
65 $ mkcommit A0 |
|
66 $ mkcommit B0 |
|
67 $ mkcommit C |
|
68 $ hg up --quiet 0 |
|
69 $ mkcommit A1 |
|
70 created new head |
|
71 $ mkcommit B1 |
|
72 $ hg debugobsolete --hidden `getid 'desc(A0)'` `getid 'desc(A1)'` |
|
73 $ hg debugobsolete --hidden aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa `getid 'desc(B0)'` |
|
74 $ hg debugobsolete --hidden `getid 'desc(B0)'` `getid 'desc(B1)'` |
|
75 $ hg prune -qd '0 0' 'desc(B1)' |
|
76 $ hg log -G --hidden |
|
77 x 069b05c3876d (draft): B1 |
|
78 | |
|
79 @ e5ea8f9c7314 (draft): A1 |
|
80 | |
|
81 | o 1d0f3cd25300 (draft): C |
|
82 | | |
|
83 | x 6e72f0a95b5e (draft): B0 |
|
84 | | |
|
85 | x 28b51eb45704 (draft): A0 |
|
86 |/ |
|
87 o a9bdc8b26820 (public): O |
|
88 |
|
89 $ inspect_obsmarkers |
|
90 obsstore content |
|
91 ================ |
|
92 28b51eb45704506b5c603decd6bf7ac5e0f6a52f e5ea8f9c73143125d36658e90ef70c6d2027a5b7 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |
|
93 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 6e72f0a95b5e01a7504743aa941f69cb1fbef8b0 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |
|
94 6e72f0a95b5e01a7504743aa941f69cb1fbef8b0 069b05c3876d56f62895e853a501ea58ea85f68d 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |
|
95 069b05c3876d56f62895e853a501ea58ea85f68d 0 {e5ea8f9c73143125d36658e90ef70c6d2027a5b7} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |
|
96 obshashtree |
|
97 =========== |
|
98 a9bdc8b26820b1b87d585b82eb0ceb4a2ecdbc04 0000000000000000000000000000000000000000 |
|
99 28b51eb45704506b5c603decd6bf7ac5e0f6a52f 0000000000000000000000000000000000000000 |
|
100 6e72f0a95b5e01a7504743aa941f69cb1fbef8b0 13bd00d88332fcd3fe634ed42f9d35c9cfc06398 |
|
101 1d0f3cd253006f014c7687a78abbc9287db4101d 01d985a82467333a4de7a5b4e8a0de3286f8bda8 |
|
102 e5ea8f9c73143125d36658e90ef70c6d2027a5b7 d2b1159bcf3694aabc3674785b1859544c35357d |
|
103 069b05c3876d56f62895e853a501ea58ea85f68d d00e3201fcf83a1bf42e70757f07b45bdd77a220 |
|
104 obshashrange |
|
105 ============ |
|
106 rev node index size depth obshash |
|
107 3 1d0f3cd25300 0 4 4 000000000000 |
|
108 3 1d0f3cd25300 2 2 4 000000000000 |
|
109 1 28b51eb45704 0 2 2 000000000000 |
|
110 4 e5ea8f9c7314 0 2 2 d2b1159bcf36 |
|
111 3 1d0f3cd25300 3 1 4 000000000000 |
|
112 1 28b51eb45704 1 1 2 000000000000 |
|
113 2 6e72f0a95b5e 2 1 3 13bd00d88332 |
|
114 0 a9bdc8b26820 0 1 1 000000000000 |
|
115 4 e5ea8f9c7314 1 1 2 d2b1159bcf36 |
|
116 $ cd .. |
|
117 $ cd .. |
|
118 |
|
119 Actual Test (explicit push version) |
|
120 ----------------------------------- |
|
121 |
|
122 $ dotest B.5 C -f |
|
123 ## Running testcase B.5 |
|
124 # testing echange of "C" (1d0f3cd25300) |
|
125 ## initial state |
|
126 # obstore: main |
|
127 069b05c3876d56f62895e853a501ea58ea85f68d 0 {e5ea8f9c73143125d36658e90ef70c6d2027a5b7} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |
|
128 28b51eb45704506b5c603decd6bf7ac5e0f6a52f e5ea8f9c73143125d36658e90ef70c6d2027a5b7 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |
|
129 6e72f0a95b5e01a7504743aa941f69cb1fbef8b0 069b05c3876d56f62895e853a501ea58ea85f68d 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |
|
130 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 6e72f0a95b5e01a7504743aa941f69cb1fbef8b0 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |
|
131 # obstore: pushdest |
|
132 # obstore: pulldest |
|
133 ## pushing "C" from main to pushdest |
|
134 pushing to pushdest |
|
135 searching for changes |
|
136 remote: adding changesets |
|
137 remote: adding manifests |
|
138 remote: adding file changes |
|
139 remote: added 3 changesets with 3 changes to 3 files |
|
140 remote: 1 new obsolescence markers |
|
141 ## post push state |
|
142 # obstore: main |
|
143 069b05c3876d56f62895e853a501ea58ea85f68d 0 {e5ea8f9c73143125d36658e90ef70c6d2027a5b7} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |
|
144 28b51eb45704506b5c603decd6bf7ac5e0f6a52f e5ea8f9c73143125d36658e90ef70c6d2027a5b7 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |
|
145 6e72f0a95b5e01a7504743aa941f69cb1fbef8b0 069b05c3876d56f62895e853a501ea58ea85f68d 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |
|
146 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 6e72f0a95b5e01a7504743aa941f69cb1fbef8b0 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |
|
147 # obstore: pushdest |
|
148 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 6e72f0a95b5e01a7504743aa941f69cb1fbef8b0 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |
|
149 # obstore: pulldest |
|
150 ## pulling "1d0f3cd25300" from main into pulldest |
|
151 pulling from main |
|
152 searching for changes |
|
153 adding changesets |
|
154 adding manifests |
|
155 adding file changes |
|
156 added 3 changesets with 3 changes to 3 files |
|
157 1 new obsolescence markers |
|
158 (run 'hg update' to get a working copy) |
|
159 ## post pull state |
|
160 # obstore: main |
|
161 069b05c3876d56f62895e853a501ea58ea85f68d 0 {e5ea8f9c73143125d36658e90ef70c6d2027a5b7} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |
|
162 28b51eb45704506b5c603decd6bf7ac5e0f6a52f e5ea8f9c73143125d36658e90ef70c6d2027a5b7 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |
|
163 6e72f0a95b5e01a7504743aa941f69cb1fbef8b0 069b05c3876d56f62895e853a501ea58ea85f68d 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |
|
164 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 6e72f0a95b5e01a7504743aa941f69cb1fbef8b0 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |
|
165 # obstore: pushdest |
|
166 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 6e72f0a95b5e01a7504743aa941f69cb1fbef8b0 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |
|
167 # obstore: pulldest |
|
168 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 6e72f0a95b5e01a7504743aa941f69cb1fbef8b0 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |