[PATCH 1 of 2 STABLE] test: move ignore test run into a subdirectory

Durham Goode durham at fb.com
Fri Jul 24 23:59:22 UTC 2015


# HG changeset patch
# User Durham Goode <durham at fb.com>
# Date 1437781401 25200
#      Fri Jul 24 16:43:21 2015 -0700
# Branch stable
# Node ID 952b733d64bf8cbb5c0d1e83b3bd6ffb5b811699
# Parent  a74e9806d17d777595f02bef912da25b876cb56f
test: move ignore test run into a subdirectory

Previously the hgignore test just called hg init in the test directory. A future
patch needs to test hgignore stuff from outside of the repo, so let's move the
entire test repo into a subdirectory.

diff --git a/tests/test-hgignore.t b/tests/test-hgignore.t
--- a/tests/test-hgignore.t
+++ b/tests/test-hgignore.t
@@ -1,4 +1,5 @@
-  $ hg init
+  $ hg init ignorerepo
+  $ cd ignorerepo
 
 Issue562: .hgignore requires newline at end:
 
@@ -44,7 +45,7 @@ Should display baz only:
 
   $ echo "*.o" > .hgignore
   $ hg status
-  abort: $TESTTMP/.hgignore: invalid pattern (relre): *.o (glob)
+  abort: $TESTTMP/ignorerepo/.hgignore: invalid pattern (relre): *.o (glob)
   [255]
 
   $ echo ".*\.o" > .hgignore
@@ -69,7 +70,7 @@ Test that patterns from ui.ignore option
   $ echo > .hgignore
   $ cat >> $HGRCPATH << EOF
   > [ui]
-  > ignore.other = $TESTTMP/.hg/testhgignore
+  > ignore.other = $TESTTMP/ignorerepo/.hg/testhgignore
   > EOF
   $ echo "glob:**.o" > .hg/testhgignore
   $ hg status
@@ -107,7 +108,7 @@ Test relative ignore path (issue4473):
 
   $ echo "syntax: invalid" > .hgignore
   $ hg status
-  $TESTTMP/.hgignore: ignoring invalid syntax 'invalid' (glob)
+  $TESTTMP/ignorerepo/.hgignore: ignoring invalid syntax 'invalid' (glob)
   A dir/b.o
   ? .hgignore
   ? a.c


More information about the Mercurial-devel mailing list