changeset 3021:5f4c42d4f2e8

test: update tests to use topic-mode enforce
author Boris Feld <boris.feld@octobus.net>
date Sat, 30 Sep 2017 22:42:52 +0100
parents 361d83261d7a
children 255e66783505
files hgext3rd/topic/__init__.py tests/test-topic-tutorial.t tests/test-topic.t
diffstat 3 files changed, 7 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/hgext3rd/topic/__init__.py	Sat Sep 30 22:24:24 2017 +0100
+++ b/hgext3rd/topic/__init__.py	Sat Sep 30 22:42:52 2017 +0100
@@ -898,7 +898,7 @@
         elif not repo.currenttopic and topicmode == "enforce":
             msg = _("no active topic")
             hint = _("set a current topic or use '--config " +
-                     "experimental.enforce-topic=no' to commit without a topic")
+                     "experimental.topic-mode=off' to commit without a topic")
             raise error.Abort(msg, hint=hint)
         return orig(ui, repo, *args, **opts)
 
--- a/tests/test-topic-tutorial.t	Sat Sep 30 22:24:24 2017 +0100
+++ b/tests/test-topic-tutorial.t	Sat Sep 30 22:42:52 2017 +0100
@@ -703,7 +703,7 @@
 
   $ cat << EOF >> .hg/hgrc
   > [experimental]
-  > enforce-topic = yes
+  > topic-mode = enforce
   > EOF
 
 You can also use `hg config --edit` to update your mercurial configuration.
@@ -714,7 +714,7 @@
   $ echo sickle >> shopping
   $ hg commit -m 'Adding sickle'
   abort: no active topic
-  (set a current topic or use '--config experimental.enforce-topic=no' to commit without a topic)
+  (set a current topic or use '--config experimental.topic-mode=off' to commit without a topic)
   [255]
 
 Ok, let's clean this up and delve into multiple topics.
--- a/tests/test-topic.t	Sat Sep 30 22:24:24 2017 +0100
+++ b/tests/test-topic.t	Sat Sep 30 22:42:52 2017 +0100
@@ -920,22 +920,22 @@
   > EOF
   $ cat <<EOF >> $HGRCPATH
   > [experimental]
-  > enforce-topic = yes
+  > topic-mode = enforce
   > EOF
   $ touch a b c d
   $ hg add a
   $ hg ci -m "Added a"
   abort: no active topic
-  (set a current topic or use '--config experimental.enforce-topic=no' to commit without a topic)
+  (set a current topic or use '--config experimental.topic-mode=off' to commit without a topic)
   [255]
 
 (same test, checking we abort before the editor)
 
   $ EDITOR=cat hg ci -m "Added a" --edit
   abort: no active topic
-  (set a current topic or use '--config experimental.enforce-topic=no' to commit without a topic)
+  (set a current topic or use '--config experimental.topic-mode=off' to commit without a topic)
   [255]
-  $ hg ci -m "added a" --config experimental.enforce-topic=no
+  $ hg ci -m "added a" --config experimental.topic-mode=off
   $ hg log
   changeset:   0:a154386e50d1
   tag:         tip