tests: move update requiredest test to own test file
authorRyan McElroy <rmcelroy@fb.com>
Fri, 07 Apr 2017 05:41:03 -0700
changeset 31844 478999e8281d
parent 31843 526e4597cca5
child 31845 86246530b8d2
tests: move update requiredest test to own test file More tests for this flag are coming in upcoming patches.
tests/test-update-dest.t
tests/test-update-names.t
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-update-dest.t	Fri Apr 07 05:41:03 2017 -0700
@@ -0,0 +1,23 @@
+Test update.requiredest
+  $ cd $TESTTMP
+  $ cat >> $HGRCPATH <<EOF
+  > [commands]
+  > update.requiredest = True
+  > EOF
+  $ hg init repo
+  $ cd repo
+  $ echo a >> a
+  $ hg commit -qAm aa
+  $ hg up
+  abort: you must specify a destination
+  (for example: hg update ".::")
+  [255]
+  $ hg up .
+  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ HGPLAIN=1 hg up
+  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ hg --config commands.update.requiredest=False up
+  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+  $ cd ..
+
--- a/tests/test-update-names.t	Fri Apr 07 23:35:51 2017 +0530
+++ b/tests/test-update-names.t	Fri Apr 07 05:41:03 2017 -0700
@@ -88,23 +88,3 @@
   (consider changing to repo root: $TESTTMP/r1/r4)
 
 #endif
-
-  $ cd $TESTTMP
-  $ cat >> $HGRCPATH <<EOF
-  > [commands]
-  > update.requiredest = True
-  > EOF
-  $ hg init dest
-  $ cd dest
-  $ echo a >> a
-  $ hg commit -qAm aa
-  $ hg up
-  abort: you must specify a destination
-  (for example: hg update ".::")
-  [255]
-  $ hg up .
-  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
-  $ HGPLAIN=1 hg up
-  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
-  $ hg --config commands.update.requiredest=False up
-  0 files updated, 0 files merged, 0 files removed, 0 files unresolved