comparison tests/test-topic.t @ 2664:ed6fb5f20b24

topics: return early so that other if conditions don't get execute (issue5600) We were not returning after the _changetopics() call and hence the if's below it were also executed which resulted in changing of current topic. This prevent current topic to be updated even when we only affect changeset unrelated to the working copy. Not that the rebase output change as it expose a new bug (rebased changeset gain a topic)
author Pulkit Goyal <7895pulkit@gmail.com>
date Sun, 25 Jun 2017 06:53:22 +0530
parents c01dc624b358
children 0ade6e87346b
comparison
equal deleted inserted replaced
2663:c01dc624b358 2664:ed6fb5f20b24
601 branch: default 601 branch: default
602 commit: (clean) 602 commit: (clean)
603 update: 5 new changesets, 2 branch heads (merge) 603 update: 5 new changesets, 2 branch heads (merge)
604 phases: 3 draft 604 phases: 3 draft
605 unstable: 1 changesets 605 unstable: 1 changesets
606 topic: wat
607 $ hg topic 606 $ hg topic
608 * wat 607 wat
609 $ hg log -Gr 'draft() and not obsolete()' 608 $ hg log -Gr 'draft() and not obsolete()'
610 o changeset: 13:686a642006db 609 o changeset: 13:686a642006db
611 | tag: tip 610 | tag: tip
612 | topic: wat 611 | topic: wat
613 | parent: 3:a53952faf762 612 | parent: 3:a53952faf762
624 623
625 Normally you'd do this with evolve, but we'll use rebase to avoid 624 Normally you'd do this with evolve, but we'll use rebase to avoid
626 bonus deps in the testsuite. 625 bonus deps in the testsuite.
627 626
628 $ hg topic 627 $ hg topic
629 * wat 628 wat
630 $ hg rebase -d tip -s . 629 $ hg rebase -d tip -s .
631 rebasing 12:18b70b8de1f0 "fran?" 630 rebasing 12:18b70b8de1f0 "fran?"
631 switching to topic wat
632 $ hg topic 632 $ hg topic
633 * wat 633 * wat
634 634
635 $ hg log -Gr 'draft()' 635 $ hg log -Gr 'draft()'
636 @ changeset: 14:503497a14c3e 636 @ changeset: 14:503497a14c3e