Mercurial > evolve
diff tests/test-topic-dest.t @ 5025:21168e99ba88 stable
evolve: add test to demonstrate a bug when no active topic
Added test shows that the logic to find the destination for
`hg up` in the case when "working directory parent has a topic
but wdir has no active topic" is buggy.
This will be fixed in next patch.
author | Sushil khanchi <sushilkhanchi97@gmail.com> |
---|---|
date | Fri, 20 Dec 2019 17:32:07 +0530 |
parents | b1a9d548af52 |
children | e7949274c3f9 |
line wrap: on
line diff
--- a/tests/test-topic-dest.t Fri Dec 20 17:31:57 2019 +0530 +++ b/tests/test-topic-dest.t Fri Dec 20 17:32:07 2019 +0530 @@ -515,3 +515,16 @@ $ hg up clearing empty topic "foo" 0 files updated, 0 files merged, 0 files removed, 0 files unresolved + +destination check: when wdp has a topic but wdir has no active topic: + + $ hg topic foo + marked working directory as topic: foo + $ echo b > b + $ hg ci -Am "added b" + adding b + active topic 'foo' grew its first changeset + (see 'hg help topics' for more information) + $ hg topic --clear + $ hg up 2>&1 | grep "AssertionError" + AssertionError: any revision has at least one descendant branch head