Mercurial > evolve
comparison tests/test-evolve-topic.t @ 6032:2800aa3c3dbf
topic: drop the old workaround for detecting amends by amend_source
We don't need to have this workaround because amends are handled differently
now. See previous commits, where the old code for handling amends in topic
extension gets removed.
Various commits now preserve amend_source when going through the _changetopics
function (used when changing a topic via the hg topics command).
author | Anton Shestakov <av6@dwimlabs.net> |
---|---|
date | Mon, 30 Aug 2021 12:05:14 +0300 |
parents | c3d66af4cb07 |
children | c0921b5277a0 53d63b608230 |
comparison
equal
deleted
inserted
replaced
6031:c3d66af4cb07 | 6032:2800aa3c3dbf |
---|---|
249 | 249 |
250 $ hg topic -r 070c5573d8f9 bar | 250 $ hg topic -r 070c5573d8f9 bar |
251 4 new orphan changesets | 251 4 new orphan changesets |
252 changed topic on 1 changesets to "bar" | 252 changed topic on 1 changesets to "bar" |
253 $ hg log -r 18 -T '{rev}: {join(extras, " ")}\n' | 253 $ hg log -r 18 -T '{rev}: {join(extras, " ")}\n' |
254 18: _rewrite_noise=[0-9a-f]+ branch=default rebase_source=[0-9a-f]+ topic=bar (re) | 254 18: _rewrite_noise=[0-9a-f]+ amend_source=[0-9a-f]+ branch=default rebase_source=[0-9a-f]+ topic=bar (re) |
255 $ hg up 16d6f664b17c | 255 $ hg up 16d6f664b17c |
256 switching to topic bar | 256 switching to topic bar |
257 2 files updated, 0 files merged, 0 files removed, 0 files unresolved | 257 2 files updated, 0 files merged, 0 files removed, 0 files unresolved |
258 | 258 |
259 $ hg stack | 259 $ hg stack |
272 | 272 |
273 Testing issue 5708 when we are on obsolete changeset and there is active topic | 273 Testing issue 5708 when we are on obsolete changeset and there is active topic |
274 ------------------------------------------------------------------------------ | 274 ------------------------------------------------------------------------------ |
275 | 275 |
276 $ hg log --graph | 276 $ hg log --graph |
277 @ 18 - {bar} 793eb6370b2d add fff (draft) | 277 @ 18 - {bar} c80027c7cda1 add fff (draft) |
278 | | 278 | |
279 | * 17 - {bar} 9bf430c106b7 add jjj (draft) | 279 | * 17 - {bar} 9bf430c106b7 add jjj (draft) |
280 | | | 280 | | |
281 | * 16 - {bar} d2dc89c57700 add iii (draft) | 281 | * 16 - {bar} d2dc89c57700 add iii (draft) |
282 | | | 282 | | |
341 | | 341 | |
342 * 20 - {bar} 7858bd7e9906 add iii (draft) | 342 * 20 - {bar} 7858bd7e9906 add iii (draft) |
343 | | 343 | |
344 * 19 - {bar} d834582d9ee3 add hhh (draft) | 344 * 19 - {bar} d834582d9ee3 add hhh (draft) |
345 | | 345 | |
346 | o 18 - {bar} 793eb6370b2d add fff (draft) | 346 | o 18 - {bar} c80027c7cda1 add fff (draft) |
347 | | | 347 | | |
348 @ | 14 - {bar} 16d6f664b17c add ggg (draft) | 348 @ | 14 - {bar} 16d6f664b17c add ggg (draft) |
349 | | | 349 | | |
350 x | 13 - {foo} 070c5573d8f9 add fff (draft) | 350 x | 13 - {foo} 070c5573d8f9 add fff (draft) |
351 |/ | 351 |/ |
355 | 355 |
356 $ hg up 070c5573d8f9 | 356 $ hg up 070c5573d8f9 |
357 switching to topic foo | 357 switching to topic foo |
358 0 files updated, 0 files merged, 1 files removed, 0 files unresolved | 358 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
359 working directory parent is obsolete! (070c5573d8f9) | 359 working directory parent is obsolete! (070c5573d8f9) |
360 (use 'hg evolve' to update to its successor: 793eb6370b2d) | 360 (use 'hg evolve' to update to its successor: c80027c7cda1) |
361 | 361 |
362 $ hg topic bar | 362 $ hg topic bar |
363 | 363 |
364 $ hg prev | 364 $ hg prev |
365 no parent in topic "bar" | 365 no parent in topic "bar" |
390 $ echo "changes in hhh" > hhh | 390 $ echo "changes in hhh" > hhh |
391 $ hg add hhh | 391 $ hg add hhh |
392 $ hg ci --amend | 392 $ hg ci --amend |
393 4 new orphan changesets | 393 4 new orphan changesets |
394 $ hg log -G | 394 $ hg log -G |
395 @ 26 - {bar} 2c295936ac04 add fff (draft) | 395 @ 26 - {bar} 239dcab64bc0 add fff (draft) |
396 | | 396 | |
397 | * 25 - {bar} 38a82cbb794a add jjj (draft) | 397 | * 25 - {bar} e49f8682fb23 add jjj (draft) |
398 | | | 398 | | |
399 | * 24 - {bar} 4a44eba0fdb3 add iii (draft) | 399 | * 24 - {bar} 318094e157e3 add iii (draft) |
400 | | | 400 | | |
401 | * 23 - {bar} 7acd9ea5d677 add hhh (draft) | 401 | * 23 - {bar} aa8b0df2da21 add hhh (draft) |
402 | | | 402 | | |
403 | * 22 - {bar} 735c7bd8f133 add ggg (draft) | 403 | * 22 - {bar} 310e9f9bceb1 add ggg (draft) |
404 | | | 404 | | |
405 | x 18 - {bar} 793eb6370b2d add fff (draft) | 405 | x 18 - {bar} c80027c7cda1 add fff (draft) |
406 |/ | 406 |/ |
407 o 12 - {foo} 42b49017ff90 add eee (draft) | 407 o 12 - {foo} 42b49017ff90 add eee (draft) |
408 | | 408 | |
409 o 10 - {foo} d9cacd156ffc add ddd (draft) | 409 o 10 - {foo} d9cacd156ffc add ddd (draft) |
410 | | 410 | |
426 $ echo "resolved hhh" > hhh | 426 $ echo "resolved hhh" > hhh |
427 $ hg resolve --mark hhh | 427 $ hg resolve --mark hhh |
428 (no more unresolved files) | 428 (no more unresolved files) |
429 continue: hg evolve --continue | 429 continue: hg evolve --continue |
430 $ hg evolve --continue | 430 $ hg evolve --continue |
431 evolving 23:7acd9ea5d677 "add hhh" | 431 evolving 23:aa8b0df2da21 "add hhh" |
432 move:[s4] add iii | 432 move:[s4] add iii |
433 atop:[s3] add hhh | 433 atop:[s3] add hhh |
434 move:[s5] add jjj | 434 move:[s5] add jjj |
435 | 435 |
436 Test to make sure that evolve don't crash with FilteredRepoLookupError when obsolete revs are in play: | 436 Test to make sure that evolve don't crash with FilteredRepoLookupError when obsolete revs are in play: |
439 update to obsolete revision | 439 update to obsolete revision |
440 $ hg up -r 'min(desc("add fff"))' --hidden | 440 $ hg up -r 'min(desc("add fff"))' --hidden |
441 switching to topic foo | 441 switching to topic foo |
442 2 files updated, 0 files merged, 1 files removed, 0 files unresolved | 442 2 files updated, 0 files merged, 1 files removed, 0 files unresolved |
443 updated to hidden changeset 6a6b7365c751 | 443 updated to hidden changeset 6a6b7365c751 |
444 (hidden revision '6a6b7365c751' was rewritten as: 2c295936ac04) | 444 (hidden revision '6a6b7365c751' was rewritten as: 239dcab64bc0) |
445 working directory parent is obsolete! (6a6b7365c751) | 445 working directory parent is obsolete! (6a6b7365c751) |
446 (use 'hg evolve' to update to its successor: 2c295936ac04) | 446 (use 'hg evolve' to update to its successor: 239dcab64bc0) |
447 | 447 |
448 Evolve: | 448 Evolve: |
449 $ hg evolve | 449 $ hg evolve |
450 update:[26] add fff | 450 update:[26] add fff |
451 switching to topic bar | 451 switching to topic bar |
452 3 files updated, 0 files merged, 0 files removed, 0 files unresolved | 452 3 files updated, 0 files merged, 0 files removed, 0 files unresolved |
453 working directory is now at 2c295936ac04 | 453 working directory is now at 239dcab64bc0 |