Mercurial > evolve
comparison tests/test-topic-dest.t @ 1892:b1fadc089b82
update: change default update destination to take topic in account
When within a branch update to ngtip(branch). When within a topic update to the
top topic.
author | Pierre-Yves David <pierre-yves.david@fb.com> |
---|---|
date | Sun, 13 Mar 2016 12:29:43 +0000 |
parents | 077c40f206d1 |
children | 27ea12c05e99 |
comparison
equal
deleted
inserted
replaced
1891:077c40f206d1 | 1892:b1fadc089b82 |
---|---|
253 | | 253 | |
254 o 1 () c_beta | 254 o 1 () c_beta |
255 | | 255 | |
256 o 0 () c_alpha | 256 o 0 () c_alpha |
257 | 257 |
258 | |
259 Default destination for update | |
260 =============================== | |
261 | |
262 initial setup | |
263 | |
264 $ hg up elephant | |
265 switching to topic elephant | |
266 1 files updated, 0 files merged, 1 files removed, 0 files unresolved | |
267 $ echo arthur >> jungle | |
268 $ hg ci -m arthur | |
269 created new head | |
270 $ echo pompadour >> jungle | |
271 $ hg ci -m pompadour | |
272 created new head | |
273 $ hg up 'roots(all())' | |
274 0 files updated, 0 files merged, 6 files removed, 0 files unresolved | |
275 $ hg log -G | |
276 o 15 (elephant) pompadour | |
277 | | |
278 o 14 (elephant) arthur | |
279 | | |
280 | o 13 (monkey) merge with default | |
281 | |\ | |
282 o---+ 12 (elephant) babar | |
283 / / | |
284 | o 11 () c_zeta | |
285 | | | |
286 o | 10 (monkey) Huc | |
287 | | | |
288 o | 8 (monkey) zephir | |
289 |/ | |
290 o 6 () c_epsilon | |
291 | | |
292 o 3 () c_delta | |
293 | | |
294 o 2 () c_gamma | |
295 | | |
296 o 1 () c_beta | |
297 | | |
298 @ 0 () c_alpha | |
299 | |
300 | |
301 testing default destination on a branch | |
302 | |
303 $ hg up | |
304 5 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
305 $ hg log -G | |
306 o 15 (elephant) pompadour | |
307 | | |
308 o 14 (elephant) arthur | |
309 | | |
310 | o 13 (monkey) merge with default | |
311 | |\ | |
312 o---+ 12 (elephant) babar | |
313 / / | |
314 | @ 11 () c_zeta | |
315 | | | |
316 o | 10 (monkey) Huc | |
317 | | | |
318 o | 8 (monkey) zephir | |
319 |/ | |
320 o 6 () c_epsilon | |
321 | | |
322 o 3 () c_delta | |
323 | | |
324 o 2 () c_gamma | |
325 | | |
326 o 1 () c_beta | |
327 | | |
328 o 0 () c_alpha | |
329 | |
330 | |
331 extra setup for topic | |
332 (making sure tip is not the topic) | |
333 | |
334 $ hg up 'desc(c_zeta)' | |
335 0 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
336 $ echo 'eta' >> 'eta' | |
337 $ hg add 'eta' | |
338 $ hg commit -m 'c_eta' | |
339 $ hg log -G | |
340 @ 16 () c_eta | |
341 | | |
342 | o 15 (elephant) pompadour | |
343 | | | |
344 | o 14 (elephant) arthur | |
345 | | | |
346 +---o 13 (monkey) merge with default | |
347 | | | | |
348 | o | 12 (elephant) babar | |
349 |/ / | |
350 o | 11 () c_zeta | |
351 | | | |
352 | o 10 (monkey) Huc | |
353 | | | |
354 | o 8 (monkey) zephir | |
355 |/ | |
356 o 6 () c_epsilon | |
357 | | |
358 o 3 () c_delta | |
359 | | |
360 o 2 () c_gamma | |
361 | | |
362 o 1 () c_beta | |
363 | | |
364 o 0 () c_alpha | |
365 | |
366 | |
367 Testing default destination for topic | |
368 | |
369 $ hg up 'roots(topic(elephant))' | |
370 switching to topic elephant | |
371 1 files updated, 0 files merged, 1 files removed, 0 files unresolved | |
372 $ hg up | |
373 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
374 $ hg log -G | |
375 o 16 () c_eta | |
376 | | |
377 | @ 15 (elephant) pompadour | |
378 | | | |
379 | o 14 (elephant) arthur | |
380 | | | |
381 +---o 13 (monkey) merge with default | |
382 | | | | |
383 | o | 12 (elephant) babar | |
384 |/ / | |
385 o | 11 () c_zeta | |
386 | | | |
387 | o 10 (monkey) Huc | |
388 | | | |
389 | o 8 (monkey) zephir | |
390 |/ | |
391 o 6 () c_epsilon | |
392 | | |
393 o 3 () c_delta | |
394 | | |
395 o 2 () c_gamma | |
396 | | |
397 o 1 () c_beta | |
398 | | |
399 o 0 () c_alpha | |
400 | |
401 | |
402 Testing default destination for topic | |
403 | |
404 $ hg up 'p1(roots(topic(elephant)))' | |
405 0 files updated, 0 files merged, 1 files removed, 0 files unresolved | |
406 $ hg topic elephant | |
407 $ hg up | |
408 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
409 $ hg log -G | |
410 o 16 () c_eta | |
411 | | |
412 | @ 15 (elephant) pompadour | |
413 | | | |
414 | o 14 (elephant) arthur | |
415 | | | |
416 +---o 13 (monkey) merge with default | |
417 | | | | |
418 | o | 12 (elephant) babar | |
419 |/ / | |
420 o | 11 () c_zeta | |
421 | | | |
422 | o 10 (monkey) Huc | |
423 | | | |
424 | o 8 (monkey) zephir | |
425 |/ | |
426 o 6 () c_epsilon | |
427 | | |
428 o 3 () c_delta | |
429 | | |
430 o 2 () c_gamma | |
431 | | |
432 o 1 () c_beta | |
433 | | |
434 o 0 () c_alpha | |
435 |