]> git.ipfire.org Git - thirdparty/bind9.git/commit
Allow retaining system test output using an environment variable
authorMichał Kępień <michal@isc.org>
Wed, 21 Feb 2018 13:59:33 +0000 (14:59 +0100)
committerEvan Hunt <each@isc.org>
Sun, 25 Feb 2018 01:37:44 +0000 (17:37 -0800)
commite9c4dbe36147c6ae16dd353793eb7d376ff622a7
treeb7844050a22399172c091d7b4662d9cf9bccae46
parentf09698659a0d8a9fbaa3181824df66b351768527
Allow retaining system test output using an environment variable

Instead of exporting an environment variable containing a command line
argument (NOCLEAN="-n"), extend run.sh to handle a "boolean" environment
variable (SYSTEMTEST_NO_CLEAN) itself.  The former method is buggy
because the value of NOCLEAN is set in parallel.mk when that file is
first created, but it is not subsequently updated upon each test run
(because make considers parallel.mk to be up to date).

To retain backward compatibility, the "-n" command line argument for
run.sh is still supported (and has a higher priority than the relevant
environment variable).

The SYSTEMTEST_NO_CLEAN environment variable can also be used directly
to prevent cleanup when using "make test" instead of runall.sh.

Apart from fixing a bug, this simplifies the way runall.sh controls
run.sh behavior due to the Makefile being bypassed.  Direct processing
of environment variables in run.sh is more scalable in the long run,
given that the previously utilized technique, even with its
implementation fixed, would still require Makefile.in to be modified in
two places each time a new flag needed to be passed from runall.sh to
run.sh.

(cherry picked from commit 3862043879534542a75e40d5e6c0cc09f37f8d6b)
bin/tests/system/Makefile.in
bin/tests/system/README
bin/tests/system/run.sh
bin/tests/system/runall.sh