##// END OF EJS Templates
tests: disable infinitepush tests for simple store...
Gregory Szorc -
r37397:24c74289 default
parent child Browse files
Show More
@@ -1,363 +1,364
1 #require no-reposimplestore
1
2
2 Create an ondisk bundlestore in .hg/scratchbranches
3 Create an ondisk bundlestore in .hg/scratchbranches
3 $ . "$TESTDIR/library-infinitepush.sh"
4 $ . "$TESTDIR/library-infinitepush.sh"
4 $ cp $HGRCPATH $TESTTMP/defaulthgrc
5 $ cp $HGRCPATH $TESTTMP/defaulthgrc
5 $ setupcommon
6 $ setupcommon
6 $ mkcommit() {
7 $ mkcommit() {
7 > echo "$1" > "$1"
8 > echo "$1" > "$1"
8 > hg add "$1"
9 > hg add "$1"
9 > hg ci -m "$1"
10 > hg ci -m "$1"
10 > }
11 > }
11 $ hg init repo
12 $ hg init repo
12 $ cd repo
13 $ cd repo
13
14
14 Check that we can send a scratch on the server and it does not show there in
15 Check that we can send a scratch on the server and it does not show there in
15 the history but is stored on disk
16 the history but is stored on disk
16 $ setupserver
17 $ setupserver
17 $ cd ..
18 $ cd ..
18 $ hg clone ssh://user@dummy/repo client -q
19 $ hg clone ssh://user@dummy/repo client -q
19 $ cd client
20 $ cd client
20 $ mkcommit initialcommit
21 $ mkcommit initialcommit
21 $ hg push -r .
22 $ hg push -r .
22 pushing to ssh://user@dummy/repo
23 pushing to ssh://user@dummy/repo
23 searching for changes
24 searching for changes
24 remote: adding changesets
25 remote: adding changesets
25 remote: adding manifests
26 remote: adding manifests
26 remote: adding file changes
27 remote: adding file changes
27 remote: added 1 changesets with 1 changes to 1 files
28 remote: added 1 changesets with 1 changes to 1 files
28 $ mkcommit scratchcommit
29 $ mkcommit scratchcommit
29 $ hg push -r . -B scratch/mybranch
30 $ hg push -r . -B scratch/mybranch
30 pushing to ssh://user@dummy/repo
31 pushing to ssh://user@dummy/repo
31 searching for changes
32 searching for changes
32 remote: pushing 1 commit:
33 remote: pushing 1 commit:
33 remote: 20759b6926ce scratchcommit
34 remote: 20759b6926ce scratchcommit
34 $ hg log -G
35 $ hg log -G
35 @ changeset: 1:20759b6926ce
36 @ changeset: 1:20759b6926ce
36 | bookmark: scratch/mybranch
37 | bookmark: scratch/mybranch
37 | tag: tip
38 | tag: tip
38 | user: test
39 | user: test
39 | date: Thu Jan 01 00:00:00 1970 +0000
40 | date: Thu Jan 01 00:00:00 1970 +0000
40 | summary: scratchcommit
41 | summary: scratchcommit
41 |
42 |
42 o changeset: 0:67145f466344
43 o changeset: 0:67145f466344
43 user: test
44 user: test
44 date: Thu Jan 01 00:00:00 1970 +0000
45 date: Thu Jan 01 00:00:00 1970 +0000
45 summary: initialcommit
46 summary: initialcommit
46
47
47 $ hg log -G -R ../repo
48 $ hg log -G -R ../repo
48 o changeset: 0:67145f466344
49 o changeset: 0:67145f466344
49 tag: tip
50 tag: tip
50 user: test
51 user: test
51 date: Thu Jan 01 00:00:00 1970 +0000
52 date: Thu Jan 01 00:00:00 1970 +0000
52 summary: initialcommit
53 summary: initialcommit
53
54
54 $ find ../repo/.hg/scratchbranches | sort
55 $ find ../repo/.hg/scratchbranches | sort
55 ../repo/.hg/scratchbranches
56 ../repo/.hg/scratchbranches
56 ../repo/.hg/scratchbranches/filebundlestore
57 ../repo/.hg/scratchbranches/filebundlestore
57 ../repo/.hg/scratchbranches/filebundlestore/b9
58 ../repo/.hg/scratchbranches/filebundlestore/b9
58 ../repo/.hg/scratchbranches/filebundlestore/b9/e1
59 ../repo/.hg/scratchbranches/filebundlestore/b9/e1
59 ../repo/.hg/scratchbranches/filebundlestore/b9/e1/b9e1ee5f93fb6d7c42496fc176c09839639dd9cc
60 ../repo/.hg/scratchbranches/filebundlestore/b9/e1/b9e1ee5f93fb6d7c42496fc176c09839639dd9cc
60 ../repo/.hg/scratchbranches/index
61 ../repo/.hg/scratchbranches/index
61 ../repo/.hg/scratchbranches/index/bookmarkmap
62 ../repo/.hg/scratchbranches/index/bookmarkmap
62 ../repo/.hg/scratchbranches/index/bookmarkmap/scratch
63 ../repo/.hg/scratchbranches/index/bookmarkmap/scratch
63 ../repo/.hg/scratchbranches/index/bookmarkmap/scratch/mybranch
64 ../repo/.hg/scratchbranches/index/bookmarkmap/scratch/mybranch
64 ../repo/.hg/scratchbranches/index/nodemap
65 ../repo/.hg/scratchbranches/index/nodemap
65 ../repo/.hg/scratchbranches/index/nodemap/20759b6926ce827d5a8c73eb1fa9726d6f7defb2
66 ../repo/.hg/scratchbranches/index/nodemap/20759b6926ce827d5a8c73eb1fa9726d6f7defb2
66
67
67 From another client we can get the scratchbranch if we ask for it explicitely
68 From another client we can get the scratchbranch if we ask for it explicitely
68
69
69 $ cd ..
70 $ cd ..
70 $ hg clone ssh://user@dummy/repo client2 -q
71 $ hg clone ssh://user@dummy/repo client2 -q
71 $ cd client2
72 $ cd client2
72 $ hg pull -B scratch/mybranch --traceback
73 $ hg pull -B scratch/mybranch --traceback
73 pulling from ssh://user@dummy/repo
74 pulling from ssh://user@dummy/repo
74 searching for changes
75 searching for changes
75 adding changesets
76 adding changesets
76 adding manifests
77 adding manifests
77 adding file changes
78 adding file changes
78 added 1 changesets with 1 changes to 1 files
79 added 1 changesets with 1 changes to 1 files
79 new changesets 20759b6926ce
80 new changesets 20759b6926ce
80 (run 'hg update' to get a working copy)
81 (run 'hg update' to get a working copy)
81 $ hg log -G
82 $ hg log -G
82 o changeset: 1:20759b6926ce
83 o changeset: 1:20759b6926ce
83 | bookmark: scratch/mybranch
84 | bookmark: scratch/mybranch
84 | tag: tip
85 | tag: tip
85 | user: test
86 | user: test
86 | date: Thu Jan 01 00:00:00 1970 +0000
87 | date: Thu Jan 01 00:00:00 1970 +0000
87 | summary: scratchcommit
88 | summary: scratchcommit
88 |
89 |
89 @ changeset: 0:67145f466344
90 @ changeset: 0:67145f466344
90 user: test
91 user: test
91 date: Thu Jan 01 00:00:00 1970 +0000
92 date: Thu Jan 01 00:00:00 1970 +0000
92 summary: initialcommit
93 summary: initialcommit
93
94
94 $ cd ..
95 $ cd ..
95
96
96 Push to non-scratch bookmark
97 Push to non-scratch bookmark
97
98
98 $ cd client
99 $ cd client
99 $ hg up 0
100 $ hg up 0
100 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
101 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
101 $ mkcommit newcommit
102 $ mkcommit newcommit
102 created new head
103 created new head
103 $ hg push -r .
104 $ hg push -r .
104 pushing to ssh://user@dummy/repo
105 pushing to ssh://user@dummy/repo
105 searching for changes
106 searching for changes
106 remote: adding changesets
107 remote: adding changesets
107 remote: adding manifests
108 remote: adding manifests
108 remote: adding file changes
109 remote: adding file changes
109 remote: added 1 changesets with 1 changes to 1 files
110 remote: added 1 changesets with 1 changes to 1 files
110 $ hg log -G -T '{desc} {phase} {bookmarks}'
111 $ hg log -G -T '{desc} {phase} {bookmarks}'
111 @ newcommit public
112 @ newcommit public
112 |
113 |
113 | o scratchcommit draft scratch/mybranch
114 | o scratchcommit draft scratch/mybranch
114 |/
115 |/
115 o initialcommit public
116 o initialcommit public
116
117
117
118
118 Push to scratch branch
119 Push to scratch branch
119 $ cd ../client2
120 $ cd ../client2
120 $ hg up -q scratch/mybranch
121 $ hg up -q scratch/mybranch
121 $ mkcommit 'new scratch commit'
122 $ mkcommit 'new scratch commit'
122 $ hg push -r . -B scratch/mybranch
123 $ hg push -r . -B scratch/mybranch
123 pushing to ssh://user@dummy/repo
124 pushing to ssh://user@dummy/repo
124 searching for changes
125 searching for changes
125 remote: pushing 2 commits:
126 remote: pushing 2 commits:
126 remote: 20759b6926ce scratchcommit
127 remote: 20759b6926ce scratchcommit
127 remote: 1de1d7d92f89 new scratch commit
128 remote: 1de1d7d92f89 new scratch commit
128 $ hg log -G -T '{desc} {phase} {bookmarks}'
129 $ hg log -G -T '{desc} {phase} {bookmarks}'
129 @ new scratch commit draft scratch/mybranch
130 @ new scratch commit draft scratch/mybranch
130 |
131 |
131 o scratchcommit draft
132 o scratchcommit draft
132 |
133 |
133 o initialcommit public
134 o initialcommit public
134
135
135 $ scratchnodes
136 $ scratchnodes
136 1de1d7d92f8965260391d0513fe8a8d5973d3042 bed63daed3beba97fff2e819a148cf415c217a85
137 1de1d7d92f8965260391d0513fe8a8d5973d3042 bed63daed3beba97fff2e819a148cf415c217a85
137 20759b6926ce827d5a8c73eb1fa9726d6f7defb2 bed63daed3beba97fff2e819a148cf415c217a85
138 20759b6926ce827d5a8c73eb1fa9726d6f7defb2 bed63daed3beba97fff2e819a148cf415c217a85
138
139
139 $ scratchbookmarks
140 $ scratchbookmarks
140 scratch/mybranch 1de1d7d92f8965260391d0513fe8a8d5973d3042
141 scratch/mybranch 1de1d7d92f8965260391d0513fe8a8d5973d3042
141
142
142 Push scratch bookmark with no new revs
143 Push scratch bookmark with no new revs
143 $ hg push -r . -B scratch/anotherbranch
144 $ hg push -r . -B scratch/anotherbranch
144 pushing to ssh://user@dummy/repo
145 pushing to ssh://user@dummy/repo
145 searching for changes
146 searching for changes
146 remote: pushing 2 commits:
147 remote: pushing 2 commits:
147 remote: 20759b6926ce scratchcommit
148 remote: 20759b6926ce scratchcommit
148 remote: 1de1d7d92f89 new scratch commit
149 remote: 1de1d7d92f89 new scratch commit
149 $ hg log -G -T '{desc} {phase} {bookmarks}'
150 $ hg log -G -T '{desc} {phase} {bookmarks}'
150 @ new scratch commit draft scratch/anotherbranch scratch/mybranch
151 @ new scratch commit draft scratch/anotherbranch scratch/mybranch
151 |
152 |
152 o scratchcommit draft
153 o scratchcommit draft
153 |
154 |
154 o initialcommit public
155 o initialcommit public
155
156
156 $ scratchbookmarks
157 $ scratchbookmarks
157 scratch/anotherbranch 1de1d7d92f8965260391d0513fe8a8d5973d3042
158 scratch/anotherbranch 1de1d7d92f8965260391d0513fe8a8d5973d3042
158 scratch/mybranch 1de1d7d92f8965260391d0513fe8a8d5973d3042
159 scratch/mybranch 1de1d7d92f8965260391d0513fe8a8d5973d3042
159
160
160 Pull scratch and non-scratch bookmark at the same time
161 Pull scratch and non-scratch bookmark at the same time
161
162
162 $ hg -R ../repo book newbook
163 $ hg -R ../repo book newbook
163 $ cd ../client
164 $ cd ../client
164 $ hg pull -B newbook -B scratch/mybranch --traceback
165 $ hg pull -B newbook -B scratch/mybranch --traceback
165 pulling from ssh://user@dummy/repo
166 pulling from ssh://user@dummy/repo
166 searching for changes
167 searching for changes
167 adding changesets
168 adding changesets
168 adding manifests
169 adding manifests
169 adding file changes
170 adding file changes
170 added 1 changesets with 1 changes to 2 files
171 added 1 changesets with 1 changes to 2 files
171 adding remote bookmark newbook
172 adding remote bookmark newbook
172 new changesets 1de1d7d92f89
173 new changesets 1de1d7d92f89
173 (run 'hg update' to get a working copy)
174 (run 'hg update' to get a working copy)
174 $ hg log -G -T '{desc} {phase} {bookmarks}'
175 $ hg log -G -T '{desc} {phase} {bookmarks}'
175 o new scratch commit draft scratch/mybranch
176 o new scratch commit draft scratch/mybranch
176 |
177 |
177 | @ newcommit public
178 | @ newcommit public
178 | |
179 | |
179 o | scratchcommit draft
180 o | scratchcommit draft
180 |/
181 |/
181 o initialcommit public
182 o initialcommit public
182
183
183
184
184 Push scratch revision without bookmark with --bundle-store
185 Push scratch revision without bookmark with --bundle-store
185
186
186 $ hg up -q tip
187 $ hg up -q tip
187 $ mkcommit scratchcommitnobook
188 $ mkcommit scratchcommitnobook
188 $ hg log -G -T '{desc} {phase} {bookmarks}'
189 $ hg log -G -T '{desc} {phase} {bookmarks}'
189 @ scratchcommitnobook draft
190 @ scratchcommitnobook draft
190 |
191 |
191 o new scratch commit draft scratch/mybranch
192 o new scratch commit draft scratch/mybranch
192 |
193 |
193 | o newcommit public
194 | o newcommit public
194 | |
195 | |
195 o | scratchcommit draft
196 o | scratchcommit draft
196 |/
197 |/
197 o initialcommit public
198 o initialcommit public
198
199
199 $ hg push -r . --bundle-store
200 $ hg push -r . --bundle-store
200 pushing to ssh://user@dummy/repo
201 pushing to ssh://user@dummy/repo
201 searching for changes
202 searching for changes
202 remote: pushing 3 commits:
203 remote: pushing 3 commits:
203 remote: 20759b6926ce scratchcommit
204 remote: 20759b6926ce scratchcommit
204 remote: 1de1d7d92f89 new scratch commit
205 remote: 1de1d7d92f89 new scratch commit
205 remote: 2b5d271c7e0d scratchcommitnobook
206 remote: 2b5d271c7e0d scratchcommitnobook
206 $ hg -R ../repo log -G -T '{desc} {phase}'
207 $ hg -R ../repo log -G -T '{desc} {phase}'
207 o newcommit public
208 o newcommit public
208 |
209 |
209 o initialcommit public
210 o initialcommit public
210
211
211
212
212 $ scratchnodes
213 $ scratchnodes
213 1de1d7d92f8965260391d0513fe8a8d5973d3042 66fa08ff107451320512817bed42b7f467a1bec3
214 1de1d7d92f8965260391d0513fe8a8d5973d3042 66fa08ff107451320512817bed42b7f467a1bec3
214 20759b6926ce827d5a8c73eb1fa9726d6f7defb2 66fa08ff107451320512817bed42b7f467a1bec3
215 20759b6926ce827d5a8c73eb1fa9726d6f7defb2 66fa08ff107451320512817bed42b7f467a1bec3
215 2b5d271c7e0d25d811359a314d413ebcc75c9524 66fa08ff107451320512817bed42b7f467a1bec3
216 2b5d271c7e0d25d811359a314d413ebcc75c9524 66fa08ff107451320512817bed42b7f467a1bec3
216
217
217 Test with pushrebase
218 Test with pushrebase
218 $ mkcommit scratchcommitwithpushrebase
219 $ mkcommit scratchcommitwithpushrebase
219 $ hg push -r . -B scratch/mybranch
220 $ hg push -r . -B scratch/mybranch
220 pushing to ssh://user@dummy/repo
221 pushing to ssh://user@dummy/repo
221 searching for changes
222 searching for changes
222 remote: pushing 4 commits:
223 remote: pushing 4 commits:
223 remote: 20759b6926ce scratchcommit
224 remote: 20759b6926ce scratchcommit
224 remote: 1de1d7d92f89 new scratch commit
225 remote: 1de1d7d92f89 new scratch commit
225 remote: 2b5d271c7e0d scratchcommitnobook
226 remote: 2b5d271c7e0d scratchcommitnobook
226 remote: d8c4f54ab678 scratchcommitwithpushrebase
227 remote: d8c4f54ab678 scratchcommitwithpushrebase
227 $ hg -R ../repo log -G -T '{desc} {phase}'
228 $ hg -R ../repo log -G -T '{desc} {phase}'
228 o newcommit public
229 o newcommit public
229 |
230 |
230 o initialcommit public
231 o initialcommit public
231
232
232 $ scratchnodes
233 $ scratchnodes
233 1de1d7d92f8965260391d0513fe8a8d5973d3042 e3cb2ac50f9e1e6a5ead3217fc21236c84af4397
234 1de1d7d92f8965260391d0513fe8a8d5973d3042 e3cb2ac50f9e1e6a5ead3217fc21236c84af4397
234 20759b6926ce827d5a8c73eb1fa9726d6f7defb2 e3cb2ac50f9e1e6a5ead3217fc21236c84af4397
235 20759b6926ce827d5a8c73eb1fa9726d6f7defb2 e3cb2ac50f9e1e6a5ead3217fc21236c84af4397
235 2b5d271c7e0d25d811359a314d413ebcc75c9524 e3cb2ac50f9e1e6a5ead3217fc21236c84af4397
236 2b5d271c7e0d25d811359a314d413ebcc75c9524 e3cb2ac50f9e1e6a5ead3217fc21236c84af4397
236 d8c4f54ab678fd67cb90bb3f272a2dc6513a59a7 e3cb2ac50f9e1e6a5ead3217fc21236c84af4397
237 d8c4f54ab678fd67cb90bb3f272a2dc6513a59a7 e3cb2ac50f9e1e6a5ead3217fc21236c84af4397
237
238
238 Change the order of pushrebase and infinitepush
239 Change the order of pushrebase and infinitepush
239 $ mkcommit scratchcommitwithpushrebase2
240 $ mkcommit scratchcommitwithpushrebase2
240 $ hg push -r . -B scratch/mybranch
241 $ hg push -r . -B scratch/mybranch
241 pushing to ssh://user@dummy/repo
242 pushing to ssh://user@dummy/repo
242 searching for changes
243 searching for changes
243 remote: pushing 5 commits:
244 remote: pushing 5 commits:
244 remote: 20759b6926ce scratchcommit
245 remote: 20759b6926ce scratchcommit
245 remote: 1de1d7d92f89 new scratch commit
246 remote: 1de1d7d92f89 new scratch commit
246 remote: 2b5d271c7e0d scratchcommitnobook
247 remote: 2b5d271c7e0d scratchcommitnobook
247 remote: d8c4f54ab678 scratchcommitwithpushrebase
248 remote: d8c4f54ab678 scratchcommitwithpushrebase
248 remote: 6c10d49fe927 scratchcommitwithpushrebase2
249 remote: 6c10d49fe927 scratchcommitwithpushrebase2
249 $ hg -R ../repo log -G -T '{desc} {phase}'
250 $ hg -R ../repo log -G -T '{desc} {phase}'
250 o newcommit public
251 o newcommit public
251 |
252 |
252 o initialcommit public
253 o initialcommit public
253
254
254 $ scratchnodes
255 $ scratchnodes
255 1de1d7d92f8965260391d0513fe8a8d5973d3042 cd0586065eaf8b483698518f5fc32531e36fd8e0
256 1de1d7d92f8965260391d0513fe8a8d5973d3042 cd0586065eaf8b483698518f5fc32531e36fd8e0
256 20759b6926ce827d5a8c73eb1fa9726d6f7defb2 cd0586065eaf8b483698518f5fc32531e36fd8e0
257 20759b6926ce827d5a8c73eb1fa9726d6f7defb2 cd0586065eaf8b483698518f5fc32531e36fd8e0
257 2b5d271c7e0d25d811359a314d413ebcc75c9524 cd0586065eaf8b483698518f5fc32531e36fd8e0
258 2b5d271c7e0d25d811359a314d413ebcc75c9524 cd0586065eaf8b483698518f5fc32531e36fd8e0
258 6c10d49fe92751666c40263f96721b918170d3da cd0586065eaf8b483698518f5fc32531e36fd8e0
259 6c10d49fe92751666c40263f96721b918170d3da cd0586065eaf8b483698518f5fc32531e36fd8e0
259 d8c4f54ab678fd67cb90bb3f272a2dc6513a59a7 cd0586065eaf8b483698518f5fc32531e36fd8e0
260 d8c4f54ab678fd67cb90bb3f272a2dc6513a59a7 cd0586065eaf8b483698518f5fc32531e36fd8e0
260
261
261 Non-fastforward scratch bookmark push
262 Non-fastforward scratch bookmark push
262
263
263 $ hg log -GT "{rev}:{node} {desc}\n"
264 $ hg log -GT "{rev}:{node} {desc}\n"
264 @ 6:6c10d49fe92751666c40263f96721b918170d3da scratchcommitwithpushrebase2
265 @ 6:6c10d49fe92751666c40263f96721b918170d3da scratchcommitwithpushrebase2
265 |
266 |
266 o 5:d8c4f54ab678fd67cb90bb3f272a2dc6513a59a7 scratchcommitwithpushrebase
267 o 5:d8c4f54ab678fd67cb90bb3f272a2dc6513a59a7 scratchcommitwithpushrebase
267 |
268 |
268 o 4:2b5d271c7e0d25d811359a314d413ebcc75c9524 scratchcommitnobook
269 o 4:2b5d271c7e0d25d811359a314d413ebcc75c9524 scratchcommitnobook
269 |
270 |
270 o 3:1de1d7d92f8965260391d0513fe8a8d5973d3042 new scratch commit
271 o 3:1de1d7d92f8965260391d0513fe8a8d5973d3042 new scratch commit
271 |
272 |
272 | o 2:91894e11e8255bf41aa5434b7b98e8b2aa2786eb newcommit
273 | o 2:91894e11e8255bf41aa5434b7b98e8b2aa2786eb newcommit
273 | |
274 | |
274 o | 1:20759b6926ce827d5a8c73eb1fa9726d6f7defb2 scratchcommit
275 o | 1:20759b6926ce827d5a8c73eb1fa9726d6f7defb2 scratchcommit
275 |/
276 |/
276 o 0:67145f4663446a9580364f70034fea6e21293b6f initialcommit
277 o 0:67145f4663446a9580364f70034fea6e21293b6f initialcommit
277
278
278 $ hg up 6c10d49fe927
279 $ hg up 6c10d49fe927
279 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
280 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
280 $ echo 1 > amend
281 $ echo 1 > amend
281 $ hg add amend
282 $ hg add amend
282 $ hg ci --amend -m 'scratch amended commit'
283 $ hg ci --amend -m 'scratch amended commit'
283 saved backup bundle to $TESTTMP/client/.hg/strip-backup/6c10d49fe927-c99ffec5-amend.hg (glob)
284 saved backup bundle to $TESTTMP/client/.hg/strip-backup/6c10d49fe927-c99ffec5-amend.hg (glob)
284 $ hg log -G -T '{desc} {phase} {bookmarks}'
285 $ hg log -G -T '{desc} {phase} {bookmarks}'
285 @ scratch amended commit draft scratch/mybranch
286 @ scratch amended commit draft scratch/mybranch
286 |
287 |
287 o scratchcommitwithpushrebase draft
288 o scratchcommitwithpushrebase draft
288 |
289 |
289 o scratchcommitnobook draft
290 o scratchcommitnobook draft
290 |
291 |
291 o new scratch commit draft
292 o new scratch commit draft
292 |
293 |
293 | o newcommit public
294 | o newcommit public
294 | |
295 | |
295 o | scratchcommit draft
296 o | scratchcommit draft
296 |/
297 |/
297 o initialcommit public
298 o initialcommit public
298
299
299
300
300 $ scratchbookmarks
301 $ scratchbookmarks
301 scratch/anotherbranch 1de1d7d92f8965260391d0513fe8a8d5973d3042
302 scratch/anotherbranch 1de1d7d92f8965260391d0513fe8a8d5973d3042
302 scratch/mybranch 6c10d49fe92751666c40263f96721b918170d3da
303 scratch/mybranch 6c10d49fe92751666c40263f96721b918170d3da
303 $ hg push -r . -B scratch/mybranch
304 $ hg push -r . -B scratch/mybranch
304 pushing to ssh://user@dummy/repo
305 pushing to ssh://user@dummy/repo
305 searching for changes
306 searching for changes
306 remote: pushing 5 commits:
307 remote: pushing 5 commits:
307 remote: 20759b6926ce scratchcommit
308 remote: 20759b6926ce scratchcommit
308 remote: 1de1d7d92f89 new scratch commit
309 remote: 1de1d7d92f89 new scratch commit
309 remote: 2b5d271c7e0d scratchcommitnobook
310 remote: 2b5d271c7e0d scratchcommitnobook
310 remote: d8c4f54ab678 scratchcommitwithpushrebase
311 remote: d8c4f54ab678 scratchcommitwithpushrebase
311 remote: 8872775dd97a scratch amended commit
312 remote: 8872775dd97a scratch amended commit
312 $ scratchbookmarks
313 $ scratchbookmarks
313 scratch/anotherbranch 1de1d7d92f8965260391d0513fe8a8d5973d3042
314 scratch/anotherbranch 1de1d7d92f8965260391d0513fe8a8d5973d3042
314 scratch/mybranch 8872775dd97a750e1533dc1fbbca665644b32547
315 scratch/mybranch 8872775dd97a750e1533dc1fbbca665644b32547
315 $ hg log -G -T '{desc} {phase} {bookmarks}'
316 $ hg log -G -T '{desc} {phase} {bookmarks}'
316 @ scratch amended commit draft scratch/mybranch
317 @ scratch amended commit draft scratch/mybranch
317 |
318 |
318 o scratchcommitwithpushrebase draft
319 o scratchcommitwithpushrebase draft
319 |
320 |
320 o scratchcommitnobook draft
321 o scratchcommitnobook draft
321 |
322 |
322 o new scratch commit draft
323 o new scratch commit draft
323 |
324 |
324 | o newcommit public
325 | o newcommit public
325 | |
326 | |
326 o | scratchcommit draft
327 o | scratchcommit draft
327 |/
328 |/
328 o initialcommit public
329 o initialcommit public
329
330
330 Check that push path is not ignored. Add new path to the hgrc
331 Check that push path is not ignored. Add new path to the hgrc
331 $ cat >> .hg/hgrc << EOF
332 $ cat >> .hg/hgrc << EOF
332 > [paths]
333 > [paths]
333 > peer=ssh://user@dummy/client2
334 > peer=ssh://user@dummy/client2
334 > EOF
335 > EOF
335
336
336 Checkout last non-scrath commit
337 Checkout last non-scrath commit
337 $ hg up 91894e11e8255
338 $ hg up 91894e11e8255
338 1 files updated, 0 files merged, 6 files removed, 0 files unresolved
339 1 files updated, 0 files merged, 6 files removed, 0 files unresolved
339 $ mkcommit peercommit
340 $ mkcommit peercommit
340 Use --force because this push creates new head
341 Use --force because this push creates new head
341 $ hg push peer -r . -f
342 $ hg push peer -r . -f
342 pushing to ssh://user@dummy/client2
343 pushing to ssh://user@dummy/client2
343 searching for changes
344 searching for changes
344 remote: adding changesets
345 remote: adding changesets
345 remote: adding manifests
346 remote: adding manifests
346 remote: adding file changes
347 remote: adding file changes
347 remote: added 2 changesets with 2 changes to 2 files (+1 heads)
348 remote: added 2 changesets with 2 changes to 2 files (+1 heads)
348 $ hg -R ../repo log -G -T '{desc} {phase} {bookmarks}'
349 $ hg -R ../repo log -G -T '{desc} {phase} {bookmarks}'
349 o newcommit public
350 o newcommit public
350 |
351 |
351 o initialcommit public
352 o initialcommit public
352
353
353 $ hg -R ../client2 log -G -T '{desc} {phase} {bookmarks}'
354 $ hg -R ../client2 log -G -T '{desc} {phase} {bookmarks}'
354 o peercommit public
355 o peercommit public
355 |
356 |
356 o newcommit public
357 o newcommit public
357 |
358 |
358 | @ new scratch commit draft scratch/anotherbranch scratch/mybranch
359 | @ new scratch commit draft scratch/anotherbranch scratch/mybranch
359 | |
360 | |
360 | o scratchcommit draft
361 | o scratchcommit draft
361 |/
362 |/
362 o initialcommit public
363 o initialcommit public
363
364
@@ -1,382 +1,384
1 #require no-reposimplestore
2
1 Testing the case when there is no infinitepush extension present on the client
3 Testing the case when there is no infinitepush extension present on the client
2 side and the server routes each push to bundlestore. This case is very much
4 side and the server routes each push to bundlestore. This case is very much
3 similar to CI use case.
5 similar to CI use case.
4
6
5 Setup
7 Setup
6 -----
8 -----
7
9
8 $ . "$TESTDIR/library-infinitepush.sh"
10 $ . "$TESTDIR/library-infinitepush.sh"
9 $ cat >> $HGRCPATH <<EOF
11 $ cat >> $HGRCPATH <<EOF
10 > [alias]
12 > [alias]
11 > glog = log -GT "{rev}:{node|short} {desc}\n{phase}"
13 > glog = log -GT "{rev}:{node|short} {desc}\n{phase}"
12 > EOF
14 > EOF
13 $ cp $HGRCPATH $TESTTMP/defaulthgrc
15 $ cp $HGRCPATH $TESTTMP/defaulthgrc
14 $ hg init repo
16 $ hg init repo
15 $ cd repo
17 $ cd repo
16 $ setupserver
18 $ setupserver
17 $ echo "pushtobundlestore = True" >> .hg/hgrc
19 $ echo "pushtobundlestore = True" >> .hg/hgrc
18 $ echo "[extensions]" >> .hg/hgrc
20 $ echo "[extensions]" >> .hg/hgrc
19 $ echo "infinitepush=" >> .hg/hgrc
21 $ echo "infinitepush=" >> .hg/hgrc
20 $ echo initialcommit > initialcommit
22 $ echo initialcommit > initialcommit
21 $ hg ci -Aqm "initialcommit"
23 $ hg ci -Aqm "initialcommit"
22 $ hg phase --public .
24 $ hg phase --public .
23
25
24 $ cd ..
26 $ cd ..
25 $ hg clone repo client -q
27 $ hg clone repo client -q
26 $ hg clone repo client2 -q
28 $ hg clone repo client2 -q
27 $ cd client
29 $ cd client
28
30
29 Pushing a new commit from the client to the server
31 Pushing a new commit from the client to the server
30 -----------------------------------------------------
32 -----------------------------------------------------
31
33
32 $ echo foobar > a
34 $ echo foobar > a
33 $ hg ci -Aqm "added a"
35 $ hg ci -Aqm "added a"
34 $ hg glog
36 $ hg glog
35 @ 1:6cb0989601f1 added a
37 @ 1:6cb0989601f1 added a
36 | draft
38 | draft
37 o 0:67145f466344 initialcommit
39 o 0:67145f466344 initialcommit
38 public
40 public
39
41
40 $ hg push
42 $ hg push
41 pushing to $TESTTMP/repo
43 pushing to $TESTTMP/repo
42 searching for changes
44 searching for changes
43 storing changesets on the bundlestore
45 storing changesets on the bundlestore
44 pushing 1 commit:
46 pushing 1 commit:
45 6cb0989601f1 added a
47 6cb0989601f1 added a
46
48
47 $ scratchnodes
49 $ scratchnodes
48 6cb0989601f1fb5805238edfb16f3606713d9a0b a4c202c147a9c4bb91bbadb56321fc5f3950f7f2
50 6cb0989601f1fb5805238edfb16f3606713d9a0b a4c202c147a9c4bb91bbadb56321fc5f3950f7f2
49
51
50 Understanding how data is stored on the bundlestore in server
52 Understanding how data is stored on the bundlestore in server
51 -------------------------------------------------------------
53 -------------------------------------------------------------
52
54
53 There are two things, filebundlestore and index
55 There are two things, filebundlestore and index
54 $ ls ../repo/.hg/scratchbranches
56 $ ls ../repo/.hg/scratchbranches
55 filebundlestore
57 filebundlestore
56 index
58 index
57
59
58 filebundlestore stores the bundles
60 filebundlestore stores the bundles
59 $ ls ../repo/.hg/scratchbranches/filebundlestore/a4/c2/
61 $ ls ../repo/.hg/scratchbranches/filebundlestore/a4/c2/
60 a4c202c147a9c4bb91bbadb56321fc5f3950f7f2
62 a4c202c147a9c4bb91bbadb56321fc5f3950f7f2
61
63
62 index/nodemap stores a map of node id and file in which bundle is stored in filebundlestore
64 index/nodemap stores a map of node id and file in which bundle is stored in filebundlestore
63 $ ls ../repo/.hg/scratchbranches/index/
65 $ ls ../repo/.hg/scratchbranches/index/
64 nodemap
66 nodemap
65 $ ls ../repo/.hg/scratchbranches/index/nodemap/
67 $ ls ../repo/.hg/scratchbranches/index/nodemap/
66 6cb0989601f1fb5805238edfb16f3606713d9a0b
68 6cb0989601f1fb5805238edfb16f3606713d9a0b
67
69
68 $ cd ../repo
70 $ cd ../repo
69
71
70 Checking that the commit was not applied to revlog on the server
72 Checking that the commit was not applied to revlog on the server
71 ------------------------------------------------------------------
73 ------------------------------------------------------------------
72
74
73 $ hg glog
75 $ hg glog
74 @ 0:67145f466344 initialcommit
76 @ 0:67145f466344 initialcommit
75 public
77 public
76
78
77 Applying the changeset from the bundlestore
79 Applying the changeset from the bundlestore
78 --------------------------------------------
80 --------------------------------------------
79
81
80 $ hg unbundle .hg/scratchbranches/filebundlestore/a4/c2/a4c202c147a9c4bb91bbadb56321fc5f3950f7f2
82 $ hg unbundle .hg/scratchbranches/filebundlestore/a4/c2/a4c202c147a9c4bb91bbadb56321fc5f3950f7f2
81 adding changesets
83 adding changesets
82 adding manifests
84 adding manifests
83 adding file changes
85 adding file changes
84 added 1 changesets with 1 changes to 1 files
86 added 1 changesets with 1 changes to 1 files
85 new changesets 6cb0989601f1
87 new changesets 6cb0989601f1
86 (run 'hg update' to get a working copy)
88 (run 'hg update' to get a working copy)
87
89
88 $ hg glog
90 $ hg glog
89 o 1:6cb0989601f1 added a
91 o 1:6cb0989601f1 added a
90 | public
92 | public
91 @ 0:67145f466344 initialcommit
93 @ 0:67145f466344 initialcommit
92 public
94 public
93
95
94 Pushing more changesets from the local repo
96 Pushing more changesets from the local repo
95 --------------------------------------------
97 --------------------------------------------
96
98
97 $ cd ../client
99 $ cd ../client
98 $ echo b > b
100 $ echo b > b
99 $ hg ci -Aqm "added b"
101 $ hg ci -Aqm "added b"
100 $ echo c > c
102 $ echo c > c
101 $ hg ci -Aqm "added c"
103 $ hg ci -Aqm "added c"
102 $ hg glog
104 $ hg glog
103 @ 3:bf8a6e3011b3 added c
105 @ 3:bf8a6e3011b3 added c
104 | draft
106 | draft
105 o 2:eaba929e866c added b
107 o 2:eaba929e866c added b
106 | draft
108 | draft
107 o 1:6cb0989601f1 added a
109 o 1:6cb0989601f1 added a
108 | public
110 | public
109 o 0:67145f466344 initialcommit
111 o 0:67145f466344 initialcommit
110 public
112 public
111
113
112 $ hg push
114 $ hg push
113 pushing to $TESTTMP/repo
115 pushing to $TESTTMP/repo
114 searching for changes
116 searching for changes
115 storing changesets on the bundlestore
117 storing changesets on the bundlestore
116 pushing 2 commits:
118 pushing 2 commits:
117 eaba929e866c added b
119 eaba929e866c added b
118 bf8a6e3011b3 added c
120 bf8a6e3011b3 added c
119
121
120 Checking that changesets are not applied on the server
122 Checking that changesets are not applied on the server
121 ------------------------------------------------------
123 ------------------------------------------------------
122
124
123 $ hg glog -R ../repo
125 $ hg glog -R ../repo
124 o 1:6cb0989601f1 added a
126 o 1:6cb0989601f1 added a
125 | public
127 | public
126 @ 0:67145f466344 initialcommit
128 @ 0:67145f466344 initialcommit
127 public
129 public
128
130
129 Both of the new changesets are stored in a single bundle-file
131 Both of the new changesets are stored in a single bundle-file
130 $ scratchnodes
132 $ scratchnodes
131 6cb0989601f1fb5805238edfb16f3606713d9a0b a4c202c147a9c4bb91bbadb56321fc5f3950f7f2
133 6cb0989601f1fb5805238edfb16f3606713d9a0b a4c202c147a9c4bb91bbadb56321fc5f3950f7f2
132 bf8a6e3011b345146bbbedbcb1ebd4837571492a ee41a41cefb7817cbfb235b4f6e9f27dbad6ca1f
134 bf8a6e3011b345146bbbedbcb1ebd4837571492a ee41a41cefb7817cbfb235b4f6e9f27dbad6ca1f
133 eaba929e866c59bc9a6aada5a9dd2f6990db83c0 ee41a41cefb7817cbfb235b4f6e9f27dbad6ca1f
135 eaba929e866c59bc9a6aada5a9dd2f6990db83c0 ee41a41cefb7817cbfb235b4f6e9f27dbad6ca1f
134
136
135 Pushing more changesets to the server
137 Pushing more changesets to the server
136 -------------------------------------
138 -------------------------------------
137
139
138 $ echo d > d
140 $ echo d > d
139 $ hg ci -Aqm "added d"
141 $ hg ci -Aqm "added d"
140 $ echo e > e
142 $ echo e > e
141 $ hg ci -Aqm "added e"
143 $ hg ci -Aqm "added e"
142
144
143 XXX: we should have pushed only the parts which are not in bundlestore
145 XXX: we should have pushed only the parts which are not in bundlestore
144 $ hg push
146 $ hg push
145 pushing to $TESTTMP/repo
147 pushing to $TESTTMP/repo
146 searching for changes
148 searching for changes
147 storing changesets on the bundlestore
149 storing changesets on the bundlestore
148 pushing 4 commits:
150 pushing 4 commits:
149 eaba929e866c added b
151 eaba929e866c added b
150 bf8a6e3011b3 added c
152 bf8a6e3011b3 added c
151 1bb96358eda2 added d
153 1bb96358eda2 added d
152 b4e4bce66051 added e
154 b4e4bce66051 added e
153
155
154 Sneak peek into the bundlestore at the server
156 Sneak peek into the bundlestore at the server
155 $ scratchnodes
157 $ scratchnodes
156 1bb96358eda285b536c6d1c66846a7cdb2336cea 57e00c0d4f26e2a2a72b751b63d9abc4f3eb28e7
158 1bb96358eda285b536c6d1c66846a7cdb2336cea 57e00c0d4f26e2a2a72b751b63d9abc4f3eb28e7
157 6cb0989601f1fb5805238edfb16f3606713d9a0b a4c202c147a9c4bb91bbadb56321fc5f3950f7f2
159 6cb0989601f1fb5805238edfb16f3606713d9a0b a4c202c147a9c4bb91bbadb56321fc5f3950f7f2
158 b4e4bce660512ad3e71189e14588a70ac8e31fef 57e00c0d4f26e2a2a72b751b63d9abc4f3eb28e7
160 b4e4bce660512ad3e71189e14588a70ac8e31fef 57e00c0d4f26e2a2a72b751b63d9abc4f3eb28e7
159 bf8a6e3011b345146bbbedbcb1ebd4837571492a 57e00c0d4f26e2a2a72b751b63d9abc4f3eb28e7
161 bf8a6e3011b345146bbbedbcb1ebd4837571492a 57e00c0d4f26e2a2a72b751b63d9abc4f3eb28e7
160 eaba929e866c59bc9a6aada5a9dd2f6990db83c0 57e00c0d4f26e2a2a72b751b63d9abc4f3eb28e7
162 eaba929e866c59bc9a6aada5a9dd2f6990db83c0 57e00c0d4f26e2a2a72b751b63d9abc4f3eb28e7
161
163
162 Checking if `hg pull` pulls something or `hg incoming` shows something
164 Checking if `hg pull` pulls something or `hg incoming` shows something
163 -----------------------------------------------------------------------
165 -----------------------------------------------------------------------
164
166
165 $ hg incoming
167 $ hg incoming
166 comparing with $TESTTMP/repo
168 comparing with $TESTTMP/repo
167 searching for changes
169 searching for changes
168 no changes found
170 no changes found
169 [1]
171 [1]
170
172
171 $ hg pull
173 $ hg pull
172 pulling from $TESTTMP/repo
174 pulling from $TESTTMP/repo
173 searching for changes
175 searching for changes
174 no changes found
176 no changes found
175
177
176 Pulling from second client to test `hg pull -r <rev>`
178 Pulling from second client to test `hg pull -r <rev>`
177 ------------------------------------------------------
179 ------------------------------------------------------
178
180
179 Pulling the revision which is applied
181 Pulling the revision which is applied
180
182
181 $ cd ../client2
183 $ cd ../client2
182 $ hg pull -r 6cb0989601f1
184 $ hg pull -r 6cb0989601f1
183 pulling from $TESTTMP/repo
185 pulling from $TESTTMP/repo
184 searching for changes
186 searching for changes
185 adding changesets
187 adding changesets
186 adding manifests
188 adding manifests
187 adding file changes
189 adding file changes
188 added 1 changesets with 1 changes to 1 files
190 added 1 changesets with 1 changes to 1 files
189 new changesets 6cb0989601f1
191 new changesets 6cb0989601f1
190 (run 'hg update' to get a working copy)
192 (run 'hg update' to get a working copy)
191 $ hg glog
193 $ hg glog
192 o 1:6cb0989601f1 added a
194 o 1:6cb0989601f1 added a
193 | public
195 | public
194 @ 0:67145f466344 initialcommit
196 @ 0:67145f466344 initialcommit
195 public
197 public
196
198
197 Pulling the revision which is in bundlestore
199 Pulling the revision which is in bundlestore
198 XXX: we should support pulling revisions from bundlestore without client side
200 XXX: we should support pulling revisions from bundlestore without client side
199 wrapping
201 wrapping
200
202
201 $ hg pull -r b4e4bce660512ad3e71189e14588a70ac8e31fef
203 $ hg pull -r b4e4bce660512ad3e71189e14588a70ac8e31fef
202 pulling from $TESTTMP/repo
204 pulling from $TESTTMP/repo
203 abort: unknown revision 'b4e4bce660512ad3e71189e14588a70ac8e31fef'!
205 abort: unknown revision 'b4e4bce660512ad3e71189e14588a70ac8e31fef'!
204 [255]
206 [255]
205 $ hg glog
207 $ hg glog
206 o 1:6cb0989601f1 added a
208 o 1:6cb0989601f1 added a
207 | public
209 | public
208 @ 0:67145f466344 initialcommit
210 @ 0:67145f466344 initialcommit
209 public
211 public
210
212
211 $ cd ../client
213 $ cd ../client
212
214
213 Checking storage of phase information with the bundle on bundlestore
215 Checking storage of phase information with the bundle on bundlestore
214 ---------------------------------------------------------------------
216 ---------------------------------------------------------------------
215
217
216 creating a draft commit
218 creating a draft commit
217 $ cat >> $HGRCPATH <<EOF
219 $ cat >> $HGRCPATH <<EOF
218 > [phases]
220 > [phases]
219 > publish = False
221 > publish = False
220 > EOF
222 > EOF
221 $ echo f > f
223 $ echo f > f
222 $ hg ci -Aqm "added f"
224 $ hg ci -Aqm "added f"
223 $ hg glog -r '.^::'
225 $ hg glog -r '.^::'
224 @ 6:9b42578d4447 added f
226 @ 6:9b42578d4447 added f
225 | draft
227 | draft
226 o 5:b4e4bce66051 added e
228 o 5:b4e4bce66051 added e
227 | public
229 | public
228 ~
230 ~
229
231
230 $ hg push
232 $ hg push
231 pushing to $TESTTMP/repo
233 pushing to $TESTTMP/repo
232 searching for changes
234 searching for changes
233 storing changesets on the bundlestore
235 storing changesets on the bundlestore
234 pushing 5 commits:
236 pushing 5 commits:
235 eaba929e866c added b
237 eaba929e866c added b
236 bf8a6e3011b3 added c
238 bf8a6e3011b3 added c
237 1bb96358eda2 added d
239 1bb96358eda2 added d
238 b4e4bce66051 added e
240 b4e4bce66051 added e
239 9b42578d4447 added f
241 9b42578d4447 added f
240
242
241 XXX: the phase of 9b42578d4447 should not be changed here
243 XXX: the phase of 9b42578d4447 should not be changed here
242 $ hg glog -r .
244 $ hg glog -r .
243 @ 6:9b42578d4447 added f
245 @ 6:9b42578d4447 added f
244 | public
246 | public
245 ~
247 ~
246
248
247 applying the bundle on the server to check preservation of phase-information
249 applying the bundle on the server to check preservation of phase-information
248
250
249 $ cd ../repo
251 $ cd ../repo
250 $ scratchnodes
252 $ scratchnodes
251 1bb96358eda285b536c6d1c66846a7cdb2336cea 0a6e70ecd5b98d22382f69b93909f557ac6a9927
253 1bb96358eda285b536c6d1c66846a7cdb2336cea 0a6e70ecd5b98d22382f69b93909f557ac6a9927
252 6cb0989601f1fb5805238edfb16f3606713d9a0b a4c202c147a9c4bb91bbadb56321fc5f3950f7f2
254 6cb0989601f1fb5805238edfb16f3606713d9a0b a4c202c147a9c4bb91bbadb56321fc5f3950f7f2
253 9b42578d44473575994109161430d65dd147d16d 0a6e70ecd5b98d22382f69b93909f557ac6a9927
255 9b42578d44473575994109161430d65dd147d16d 0a6e70ecd5b98d22382f69b93909f557ac6a9927
254 b4e4bce660512ad3e71189e14588a70ac8e31fef 0a6e70ecd5b98d22382f69b93909f557ac6a9927
256 b4e4bce660512ad3e71189e14588a70ac8e31fef 0a6e70ecd5b98d22382f69b93909f557ac6a9927
255 bf8a6e3011b345146bbbedbcb1ebd4837571492a 0a6e70ecd5b98d22382f69b93909f557ac6a9927
257 bf8a6e3011b345146bbbedbcb1ebd4837571492a 0a6e70ecd5b98d22382f69b93909f557ac6a9927
256 eaba929e866c59bc9a6aada5a9dd2f6990db83c0 0a6e70ecd5b98d22382f69b93909f557ac6a9927
258 eaba929e866c59bc9a6aada5a9dd2f6990db83c0 0a6e70ecd5b98d22382f69b93909f557ac6a9927
257
259
258 $ hg unbundle .hg/scratchbranches/filebundlestore/0a/6e/0a6e70ecd5b98d22382f69b93909f557ac6a9927
260 $ hg unbundle .hg/scratchbranches/filebundlestore/0a/6e/0a6e70ecd5b98d22382f69b93909f557ac6a9927
259 adding changesets
261 adding changesets
260 adding manifests
262 adding manifests
261 adding file changes
263 adding file changes
262 added 5 changesets with 5 changes to 5 files
264 added 5 changesets with 5 changes to 5 files
263 new changesets eaba929e866c:9b42578d4447
265 new changesets eaba929e866c:9b42578d4447
264 (run 'hg update' to get a working copy)
266 (run 'hg update' to get a working copy)
265
267
266 $ hg glog
268 $ hg glog
267 o 6:9b42578d4447 added f
269 o 6:9b42578d4447 added f
268 | draft
270 | draft
269 o 5:b4e4bce66051 added e
271 o 5:b4e4bce66051 added e
270 | public
272 | public
271 o 4:1bb96358eda2 added d
273 o 4:1bb96358eda2 added d
272 | public
274 | public
273 o 3:bf8a6e3011b3 added c
275 o 3:bf8a6e3011b3 added c
274 | public
276 | public
275 o 2:eaba929e866c added b
277 o 2:eaba929e866c added b
276 | public
278 | public
277 o 1:6cb0989601f1 added a
279 o 1:6cb0989601f1 added a
278 | public
280 | public
279 @ 0:67145f466344 initialcommit
281 @ 0:67145f466344 initialcommit
280 public
282 public
281
283
282 Checking storage of obsmarkers in the bundlestore
284 Checking storage of obsmarkers in the bundlestore
283 --------------------------------------------------
285 --------------------------------------------------
284
286
285 enabling obsmarkers and rebase extension
287 enabling obsmarkers and rebase extension
286
288
287 $ cat >> $HGRCPATH << EOF
289 $ cat >> $HGRCPATH << EOF
288 > [experimental]
290 > [experimental]
289 > evolution = all
291 > evolution = all
290 > [extensions]
292 > [extensions]
291 > rebase =
293 > rebase =
292 > EOF
294 > EOF
293
295
294 $ cd ../client
296 $ cd ../client
295
297
296 $ hg phase -r . --draft --force
298 $ hg phase -r . --draft --force
297 $ hg rebase -r 6 -d 3
299 $ hg rebase -r 6 -d 3
298 rebasing 6:9b42578d4447 "added f" (tip)
300 rebasing 6:9b42578d4447 "added f" (tip)
299
301
300 $ hg glog
302 $ hg glog
301 @ 7:99949238d9ac added f
303 @ 7:99949238d9ac added f
302 | draft
304 | draft
303 | o 5:b4e4bce66051 added e
305 | o 5:b4e4bce66051 added e
304 | | public
306 | | public
305 | o 4:1bb96358eda2 added d
307 | o 4:1bb96358eda2 added d
306 |/ public
308 |/ public
307 o 3:bf8a6e3011b3 added c
309 o 3:bf8a6e3011b3 added c
308 | public
310 | public
309 o 2:eaba929e866c added b
311 o 2:eaba929e866c added b
310 | public
312 | public
311 o 1:6cb0989601f1 added a
313 o 1:6cb0989601f1 added a
312 | public
314 | public
313 o 0:67145f466344 initialcommit
315 o 0:67145f466344 initialcommit
314 public
316 public
315
317
316 $ hg push -f
318 $ hg push -f
317 pushing to $TESTTMP/repo
319 pushing to $TESTTMP/repo
318 searching for changes
320 searching for changes
319 storing changesets on the bundlestore
321 storing changesets on the bundlestore
320 pushing 1 commit:
322 pushing 1 commit:
321 99949238d9ac added f
323 99949238d9ac added f
322
324
323 XXX: the phase should not have changed here
325 XXX: the phase should not have changed here
324 $ hg glog -r .
326 $ hg glog -r .
325 @ 7:99949238d9ac added f
327 @ 7:99949238d9ac added f
326 | public
328 | public
327 ~
329 ~
328
330
329 Unbundling on server to see obsmarkers being applied
331 Unbundling on server to see obsmarkers being applied
330
332
331 $ cd ../repo
333 $ cd ../repo
332
334
333 $ scratchnodes
335 $ scratchnodes
334 1bb96358eda285b536c6d1c66846a7cdb2336cea 0a6e70ecd5b98d22382f69b93909f557ac6a9927
336 1bb96358eda285b536c6d1c66846a7cdb2336cea 0a6e70ecd5b98d22382f69b93909f557ac6a9927
335 6cb0989601f1fb5805238edfb16f3606713d9a0b a4c202c147a9c4bb91bbadb56321fc5f3950f7f2
337 6cb0989601f1fb5805238edfb16f3606713d9a0b a4c202c147a9c4bb91bbadb56321fc5f3950f7f2
336 99949238d9ac7f2424a33a46dface6f866afd059 090a24fe63f31d3b4bee714447f835c8c362ff57
338 99949238d9ac7f2424a33a46dface6f866afd059 090a24fe63f31d3b4bee714447f835c8c362ff57
337 9b42578d44473575994109161430d65dd147d16d 0a6e70ecd5b98d22382f69b93909f557ac6a9927
339 9b42578d44473575994109161430d65dd147d16d 0a6e70ecd5b98d22382f69b93909f557ac6a9927
338 b4e4bce660512ad3e71189e14588a70ac8e31fef 0a6e70ecd5b98d22382f69b93909f557ac6a9927
340 b4e4bce660512ad3e71189e14588a70ac8e31fef 0a6e70ecd5b98d22382f69b93909f557ac6a9927
339 bf8a6e3011b345146bbbedbcb1ebd4837571492a 0a6e70ecd5b98d22382f69b93909f557ac6a9927
341 bf8a6e3011b345146bbbedbcb1ebd4837571492a 0a6e70ecd5b98d22382f69b93909f557ac6a9927
340 eaba929e866c59bc9a6aada5a9dd2f6990db83c0 0a6e70ecd5b98d22382f69b93909f557ac6a9927
342 eaba929e866c59bc9a6aada5a9dd2f6990db83c0 0a6e70ecd5b98d22382f69b93909f557ac6a9927
341
343
342 $ hg glog
344 $ hg glog
343 o 6:9b42578d4447 added f
345 o 6:9b42578d4447 added f
344 | draft
346 | draft
345 o 5:b4e4bce66051 added e
347 o 5:b4e4bce66051 added e
346 | public
348 | public
347 o 4:1bb96358eda2 added d
349 o 4:1bb96358eda2 added d
348 | public
350 | public
349 o 3:bf8a6e3011b3 added c
351 o 3:bf8a6e3011b3 added c
350 | public
352 | public
351 o 2:eaba929e866c added b
353 o 2:eaba929e866c added b
352 | public
354 | public
353 o 1:6cb0989601f1 added a
355 o 1:6cb0989601f1 added a
354 | public
356 | public
355 @ 0:67145f466344 initialcommit
357 @ 0:67145f466344 initialcommit
356 public
358 public
357
359
358 $ hg unbundle .hg/scratchbranches/filebundlestore/09/0a/090a24fe63f31d3b4bee714447f835c8c362ff57
360 $ hg unbundle .hg/scratchbranches/filebundlestore/09/0a/090a24fe63f31d3b4bee714447f835c8c362ff57
359 adding changesets
361 adding changesets
360 adding manifests
362 adding manifests
361 adding file changes
363 adding file changes
362 added 1 changesets with 0 changes to 1 files (+1 heads)
364 added 1 changesets with 0 changes to 1 files (+1 heads)
363 1 new obsolescence markers
365 1 new obsolescence markers
364 obsoleted 1 changesets
366 obsoleted 1 changesets
365 new changesets 99949238d9ac
367 new changesets 99949238d9ac
366 (run 'hg heads' to see heads, 'hg merge' to merge)
368 (run 'hg heads' to see heads, 'hg merge' to merge)
367
369
368 $ hg glog
370 $ hg glog
369 o 7:99949238d9ac added f
371 o 7:99949238d9ac added f
370 | draft
372 | draft
371 | o 5:b4e4bce66051 added e
373 | o 5:b4e4bce66051 added e
372 | | public
374 | | public
373 | o 4:1bb96358eda2 added d
375 | o 4:1bb96358eda2 added d
374 |/ public
376 |/ public
375 o 3:bf8a6e3011b3 added c
377 o 3:bf8a6e3011b3 added c
376 | public
378 | public
377 o 2:eaba929e866c added b
379 o 2:eaba929e866c added b
378 | public
380 | public
379 o 1:6cb0989601f1 added a
381 o 1:6cb0989601f1 added a
380 | public
382 | public
381 @ 0:67145f466344 initialcommit
383 @ 0:67145f466344 initialcommit
382 public
384 public
@@ -1,167 +1,169
1 #require no-reposimplestore
2
1 Testing infinipush extension and the confi options provided by it
3 Testing infinipush extension and the confi options provided by it
2
4
3 Setup
5 Setup
4
6
5 $ . "$TESTDIR/library-infinitepush.sh"
7 $ . "$TESTDIR/library-infinitepush.sh"
6 $ cp $HGRCPATH $TESTTMP/defaulthgrc
8 $ cp $HGRCPATH $TESTTMP/defaulthgrc
7 $ setupcommon
9 $ setupcommon
8 $ hg init repo
10 $ hg init repo
9 $ cd repo
11 $ cd repo
10 $ setupserver
12 $ setupserver
11 $ echo initialcommit > initialcommit
13 $ echo initialcommit > initialcommit
12 $ hg ci -Aqm "initialcommit"
14 $ hg ci -Aqm "initialcommit"
13 $ hg phase --public .
15 $ hg phase --public .
14
16
15 $ cd ..
17 $ cd ..
16 $ hg clone ssh://user@dummy/repo client -q
18 $ hg clone ssh://user@dummy/repo client -q
17
19
18 Create two heads. Push first head alone, then two heads together. Make sure that
20 Create two heads. Push first head alone, then two heads together. Make sure that
19 multihead push works.
21 multihead push works.
20 $ cd client
22 $ cd client
21 $ echo multihead1 > multihead1
23 $ echo multihead1 > multihead1
22 $ hg add multihead1
24 $ hg add multihead1
23 $ hg ci -m "multihead1"
25 $ hg ci -m "multihead1"
24 $ hg up null
26 $ hg up null
25 0 files updated, 0 files merged, 2 files removed, 0 files unresolved
27 0 files updated, 0 files merged, 2 files removed, 0 files unresolved
26 $ echo multihead2 > multihead2
28 $ echo multihead2 > multihead2
27 $ hg ci -Am "multihead2"
29 $ hg ci -Am "multihead2"
28 adding multihead2
30 adding multihead2
29 created new head
31 created new head
30 $ hg push -r . --bundle-store
32 $ hg push -r . --bundle-store
31 pushing to ssh://user@dummy/repo
33 pushing to ssh://user@dummy/repo
32 searching for changes
34 searching for changes
33 remote: pushing 1 commit:
35 remote: pushing 1 commit:
34 remote: ee4802bf6864 multihead2
36 remote: ee4802bf6864 multihead2
35 $ hg push -r '1:2' --bundle-store
37 $ hg push -r '1:2' --bundle-store
36 pushing to ssh://user@dummy/repo
38 pushing to ssh://user@dummy/repo
37 searching for changes
39 searching for changes
38 remote: pushing 2 commits:
40 remote: pushing 2 commits:
39 remote: bc22f9a30a82 multihead1
41 remote: bc22f9a30a82 multihead1
40 remote: ee4802bf6864 multihead2
42 remote: ee4802bf6864 multihead2
41 $ scratchnodes
43 $ scratchnodes
42 bc22f9a30a821118244deacbd732e394ed0b686c ab1bc557aa090a9e4145512c734b6e8a828393a5
44 bc22f9a30a821118244deacbd732e394ed0b686c ab1bc557aa090a9e4145512c734b6e8a828393a5
43 ee4802bf6864326a6b3dcfff5a03abc2a0a69b8f ab1bc557aa090a9e4145512c734b6e8a828393a5
45 ee4802bf6864326a6b3dcfff5a03abc2a0a69b8f ab1bc557aa090a9e4145512c734b6e8a828393a5
44
46
45 Create two new scratch bookmarks
47 Create two new scratch bookmarks
46 $ hg up 0
48 $ hg up 0
47 1 files updated, 0 files merged, 1 files removed, 0 files unresolved
49 1 files updated, 0 files merged, 1 files removed, 0 files unresolved
48 $ echo scratchfirstpart > scratchfirstpart
50 $ echo scratchfirstpart > scratchfirstpart
49 $ hg ci -Am "scratchfirstpart"
51 $ hg ci -Am "scratchfirstpart"
50 adding scratchfirstpart
52 adding scratchfirstpart
51 created new head
53 created new head
52 $ hg push -r . -B scratch/firstpart
54 $ hg push -r . -B scratch/firstpart
53 pushing to ssh://user@dummy/repo
55 pushing to ssh://user@dummy/repo
54 searching for changes
56 searching for changes
55 remote: pushing 1 commit:
57 remote: pushing 1 commit:
56 remote: 176993b87e39 scratchfirstpart
58 remote: 176993b87e39 scratchfirstpart
57 $ hg up 0
59 $ hg up 0
58 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
60 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
59 $ echo scratchsecondpart > scratchsecondpart
61 $ echo scratchsecondpart > scratchsecondpart
60 $ hg ci -Am "scratchsecondpart"
62 $ hg ci -Am "scratchsecondpart"
61 adding scratchsecondpart
63 adding scratchsecondpart
62 created new head
64 created new head
63 $ hg push -r . -B scratch/secondpart
65 $ hg push -r . -B scratch/secondpart
64 pushing to ssh://user@dummy/repo
66 pushing to ssh://user@dummy/repo
65 searching for changes
67 searching for changes
66 remote: pushing 1 commit:
68 remote: pushing 1 commit:
67 remote: 8db3891c220e scratchsecondpart
69 remote: 8db3891c220e scratchsecondpart
68
70
69 Pull two bookmarks from the second client
71 Pull two bookmarks from the second client
70 $ cd ..
72 $ cd ..
71 $ hg clone ssh://user@dummy/repo client2 -q
73 $ hg clone ssh://user@dummy/repo client2 -q
72 $ cd client2
74 $ cd client2
73 $ hg pull -B scratch/firstpart -B scratch/secondpart
75 $ hg pull -B scratch/firstpart -B scratch/secondpart
74 pulling from ssh://user@dummy/repo
76 pulling from ssh://user@dummy/repo
75 searching for changes
77 searching for changes
76 adding changesets
78 adding changesets
77 adding manifests
79 adding manifests
78 adding file changes
80 adding file changes
79 added 1 changesets with 1 changes to 1 files
81 added 1 changesets with 1 changes to 1 files
80 adding changesets
82 adding changesets
81 adding manifests
83 adding manifests
82 adding file changes
84 adding file changes
83 added 1 changesets with 1 changes to 1 files (+1 heads)
85 added 1 changesets with 1 changes to 1 files (+1 heads)
84 new changesets * (glob)
86 new changesets * (glob)
85 (run 'hg heads' to see heads, 'hg merge' to merge)
87 (run 'hg heads' to see heads, 'hg merge' to merge)
86 $ hg log -r scratch/secondpart -T '{node}'
88 $ hg log -r scratch/secondpart -T '{node}'
87 8db3891c220e216f6da214e8254bd4371f55efca (no-eol)
89 8db3891c220e216f6da214e8254bd4371f55efca (no-eol)
88 $ hg log -r scratch/firstpart -T '{node}'
90 $ hg log -r scratch/firstpart -T '{node}'
89 176993b87e39bd88d66a2cccadabe33f0b346339 (no-eol)
91 176993b87e39bd88d66a2cccadabe33f0b346339 (no-eol)
90 Make two commits to the scratch branch
92 Make two commits to the scratch branch
91
93
92 $ echo testpullbycommithash1 > testpullbycommithash1
94 $ echo testpullbycommithash1 > testpullbycommithash1
93 $ hg ci -Am "testpullbycommithash1"
95 $ hg ci -Am "testpullbycommithash1"
94 adding testpullbycommithash1
96 adding testpullbycommithash1
95 created new head
97 created new head
96 $ hg log -r '.' -T '{node}\n' > ../testpullbycommithash1
98 $ hg log -r '.' -T '{node}\n' > ../testpullbycommithash1
97 $ echo testpullbycommithash2 > testpullbycommithash2
99 $ echo testpullbycommithash2 > testpullbycommithash2
98 $ hg ci -Aqm "testpullbycommithash2"
100 $ hg ci -Aqm "testpullbycommithash2"
99 $ hg push -r . -B scratch/mybranch -q
101 $ hg push -r . -B scratch/mybranch -q
100
102
101 Create third client and pull by commit hash.
103 Create third client and pull by commit hash.
102 Make sure testpullbycommithash2 has not fetched
104 Make sure testpullbycommithash2 has not fetched
103 $ cd ..
105 $ cd ..
104 $ hg clone ssh://user@dummy/repo client3 -q
106 $ hg clone ssh://user@dummy/repo client3 -q
105 $ cd client3
107 $ cd client3
106 $ hg pull -r `cat ../testpullbycommithash1`
108 $ hg pull -r `cat ../testpullbycommithash1`
107 pulling from ssh://user@dummy/repo
109 pulling from ssh://user@dummy/repo
108 searching for changes
110 searching for changes
109 adding changesets
111 adding changesets
110 adding manifests
112 adding manifests
111 adding file changes
113 adding file changes
112 added 1 changesets with 1 changes to 1 files
114 added 1 changesets with 1 changes to 1 files
113 new changesets 33910bfe6ffe
115 new changesets 33910bfe6ffe
114 (run 'hg update' to get a working copy)
116 (run 'hg update' to get a working copy)
115 $ hg log -G -T '{desc} {phase} {bookmarks}'
117 $ hg log -G -T '{desc} {phase} {bookmarks}'
116 o testpullbycommithash1 draft
118 o testpullbycommithash1 draft
117 |
119 |
118 @ initialcommit public
120 @ initialcommit public
119
121
120 Make public commit in the repo and pull it.
122 Make public commit in the repo and pull it.
121 Make sure phase on the client is public.
123 Make sure phase on the client is public.
122 $ cd ../repo
124 $ cd ../repo
123 $ echo publiccommit > publiccommit
125 $ echo publiccommit > publiccommit
124 $ hg ci -Aqm "publiccommit"
126 $ hg ci -Aqm "publiccommit"
125 $ hg phase --public .
127 $ hg phase --public .
126 $ cd ../client3
128 $ cd ../client3
127 $ hg pull
129 $ hg pull
128 pulling from ssh://user@dummy/repo
130 pulling from ssh://user@dummy/repo
129 searching for changes
131 searching for changes
130 adding changesets
132 adding changesets
131 adding manifests
133 adding manifests
132 adding file changes
134 adding file changes
133 added 1 changesets with 1 changes to 1 files (+1 heads)
135 added 1 changesets with 1 changes to 1 files (+1 heads)
134 new changesets a79b6597f322
136 new changesets a79b6597f322
135 (run 'hg heads' to see heads, 'hg merge' to merge)
137 (run 'hg heads' to see heads, 'hg merge' to merge)
136 $ hg log -G -T '{desc} {phase} {bookmarks} {node|short}'
138 $ hg log -G -T '{desc} {phase} {bookmarks} {node|short}'
137 o publiccommit public a79b6597f322
139 o publiccommit public a79b6597f322
138 |
140 |
139 | o testpullbycommithash1 draft 33910bfe6ffe
141 | o testpullbycommithash1 draft 33910bfe6ffe
140 |/
142 |/
141 @ initialcommit public 67145f466344
143 @ initialcommit public 67145f466344
142
144
143 $ hg up a79b6597f322
145 $ hg up a79b6597f322
144 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
146 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
145 $ echo scratchontopofpublic > scratchontopofpublic
147 $ echo scratchontopofpublic > scratchontopofpublic
146 $ hg ci -Aqm "scratchontopofpublic"
148 $ hg ci -Aqm "scratchontopofpublic"
147 $ hg push -r . -B scratch/scratchontopofpublic
149 $ hg push -r . -B scratch/scratchontopofpublic
148 pushing to ssh://user@dummy/repo
150 pushing to ssh://user@dummy/repo
149 searching for changes
151 searching for changes
150 remote: pushing 1 commit:
152 remote: pushing 1 commit:
151 remote: c70aee6da07d scratchontopofpublic
153 remote: c70aee6da07d scratchontopofpublic
152 $ cd ../client2
154 $ cd ../client2
153 $ hg pull -B scratch/scratchontopofpublic
155 $ hg pull -B scratch/scratchontopofpublic
154 pulling from ssh://user@dummy/repo
156 pulling from ssh://user@dummy/repo
155 searching for changes
157 searching for changes
156 adding changesets
158 adding changesets
157 adding manifests
159 adding manifests
158 adding file changes
160 adding file changes
159 added 1 changesets with 1 changes to 1 files (+1 heads)
161 added 1 changesets with 1 changes to 1 files (+1 heads)
160 adding changesets
162 adding changesets
161 adding manifests
163 adding manifests
162 adding file changes
164 adding file changes
163 added 1 changesets with 1 changes to 1 files
165 added 1 changesets with 1 changes to 1 files
164 new changesets a79b6597f322:c70aee6da07d
166 new changesets a79b6597f322:c70aee6da07d
165 (run 'hg heads .' to see heads, 'hg merge' to merge)
167 (run 'hg heads .' to see heads, 'hg merge' to merge)
166 $ hg log -r scratch/scratchontopofpublic -T '{phase}'
168 $ hg log -r scratch/scratchontopofpublic -T '{phase}'
167 draft (no-eol)
169 draft (no-eol)
General Comments 0
You need to be logged in to leave comments. Login now