--- a/tests/test-topic-push.t Wed Mar 16 12:14:20 2016 -0700
+++ b/tests/test-topic-push.t Tue Mar 15 17:26:57 2016 +0000
@@ -200,8 +200,34 @@
o 0 default public CA
+Pushing a new topic to a non publishing server without topic -> new head
+
+ $ cat << EOF >> ../draft/.hg/hgrc
+ > [extensions]
+ > topic=!
+ > EOF
+ $ hg push ssh://user@dummy/draft
+ pushing to ssh://user@dummy/draft
+ searching for changes
+ abort: push creates new remote head 84eaf32db6c3!
+ (merge or see "hg help push" for details about pushing new heads)
+ [255]
+ $ hg log -G
+ @ 6 default celeste draft CE
+ |
+ | o 5 default babar draft CD
+ |/
+ | o 4 mountain public CC
+ |/
+ | o 1 default public CB
+ |/
+ o 0 default public CA
+
+
Pushing a new topic to a non publishing server should not be seen as a new head
+ $ printf "topic=" >> ../draft/.hg/hgrc
+ $ hg config extensions.topic >> ../draft/.hg/hgrc
$ hg push ssh://user@dummy/draft
pushing to ssh://user@dummy/draft
searching for changes