tests/test-topic.t
changeset 4703 e15dc6defc99
parent 4648 493470e7a0f2
child 4704 5f90eb8fd63c
--- a/tests/test-topic.t	Sun Jun 30 23:50:57 2019 +0530
+++ b/tests/test-topic.t	Sun Apr 14 12:55:46 2019 +0530
@@ -1066,3 +1066,29 @@
   abort: cannot use --age while setting a topic
   [255]
   $ cd ..
+
+Test that topics doesn't confuse branchheads checking logic
+-----------------------------------------------------------
+
+  $ hg init hgtags
+  $ cd hgtags
+  $ echo a > a
+  $ hg ci -Am "added a" --config experimental.topic-mode=default
+  adding a
+  $ echo b > b
+  $ hg ci -Am "added b" --config experimental.topic-mode=default
+  adding b
+
+  $ hg topic foo -r .
+  switching to topic foo
+  changed topic on 1 changesets to "foo"
+
+Try to put a tag on current rev which also has an active topic:
+XXX: it shouldn't have aborted here
+  $ hg tag 1.0
+  abort: working directory is not at a branch head (use -f to force)
+  [255]
+  $ hg tags
+  tip                                2:3bbb3fdb2546
+
+  $ cd ..