Patchwork run-tests: use $HGTEST_RUN_TESTS_PURE

login
register
mail settings
Submitter timeless@mozdev.org
Date Sept. 2, 2015, 7:38 p.m.
Message ID <1556a7f532ba6255afee.1441222697@waste.org>
Download mbox | patch
Permalink /patch/10371/
State Accepted
Headers show

Comments

timeless@mozdev.org - Sept. 2, 2015, 7:38 p.m.
# HG changeset patch
# User timeless@mozdev.org
# Date 1441221545 14400
#      Wed Sep 02 15:19:05 2015 -0400
# Node ID 1556a7f532ba6255afeecc0adcf3991395a47334
# Parent  f77a3f27cea533232dc107a72773e90e2de9549d
run-tests: use $HGTEST_RUN_TESTS_PURE

test-run-tests and test-hghave call run-tests;
if you don't have a working build environment, and you are trying
to use --pure, then if they don't use --pure or --with-hg,
they'll break.
Matt Mackall - Sept. 3, 2015, 11:02 p.m.
On Wed, 2015-09-02 at 14:38 -0500, timeless@mozdev.org wrote:
> # HG changeset patch
> # User timeless@mozdev.org
> # Date 1441221545 14400
> #      Wed Sep 02 15:19:05 2015 -0400
> # Node ID 1556a7f532ba6255afeecc0adcf3991395a47334
> # Parent  f77a3f27cea533232dc107a72773e90e2de9549d
> run-tests: use $HGTEST_RUN_TESTS_PURE

Queued for default, thanks.

Patch

diff --git a/tests/run-tests.py b/tests/run-tests.py
--- a/tests/run-tests.py
+++ b/tests/run-tests.py
@@ -35,6 +35,8 @@ 
 #      ./run-tests.py -j2 -c --local test-s*  # unsupported (and broken)
 #  9) parallel, custom tmp dir:
 #      ./run-tests.py -j2 --tmpdir /tmp/myhgtests
+#  10) parallel, pure, tests that call run-tests:
+#      ./run-tests.py --pure `grep -l run-tests.py *.t`
 #
 # (You could use any subset of the tests: test-s* happens to match
 # enough that it's worth doing parallel runs, few enough that it
diff --git a/tests/test-hghave.t b/tests/test-hghave.t
--- a/tests/test-hghave.t
+++ b/tests/test-hghave.t
@@ -18,7 +18,7 @@ 
   >   $ echo foo
   >   foo
   > EOF
-  $ run-tests.py test-hghaveaddon.t
+  $ run-tests.py $HGTEST_RUN_TESTS_PURE test-hghaveaddon.t
   .
   # Ran 1 tests, 0 skipped, 0 warned, 0 failed.
 
diff --git a/tests/test-run-tests.t b/tests/test-run-tests.t
--- a/tests/test-run-tests.t
+++ b/tests/test-run-tests.t
@@ -580,7 +580,7 @@ 
   >   $ echo foo
   >   foo
   > EOF
-  $ run-tests.py test-hghave.t
+  $ run-tests.py $HGTEST_RUN_TESTS_PURE test-hghave.t
   .
   # Ran 1 tests, 0 skipped, 0 warned, 0 failed.
 
@@ -599,7 +599,7 @@ 
   >   #
   >   # check-code - a style and portability checker for Mercurial
   > EOF
-  $ run-tests.py test-runtestdir.t
+  $ run-tests.py $HGTEST_RUN_TESTS_PURE test-runtestdir.t
   .
   # Ran 1 tests, 0 skipped, 0 warned, 0 failed.
 
@@ -616,7 +616,7 @@ 
   >   $ custom-command.sh
   >   hello world
   > EOF
-  $ run-tests.py test-testdir-path.t
+  $ run-tests.py $HGTEST_RUN_TESTS_PURE test-testdir-path.t
   .
   # Ran 1 tests, 0 skipped, 0 warned, 0 failed.
 
@@ -628,10 +628,10 @@ 
   >   $ echo pass
   >   pass
   > EOF
-  $ run-tests.py test-very-slow-test.t
+  $ run-tests.py $HGTEST_RUN_TESTS_PURE test-very-slow-test.t
   s
   Skipped test-very-slow-test.t: skipped
   # Ran 0 tests, 1 skipped, 0 warned, 0 failed.
-  $ run-tests.py --allow-slow-tests test-very-slow-test.t
+  $ run-tests.py $HGTEST_RUN_TESTS_PURE --allow-slow-tests test-very-slow-test.t
   .
   # Ran 1 tests, 0 skipped, 0 warned, 0 failed.