diff options
author | Paul Eggert <eggert@cs.ucla.edu> | 2010-12-14 10:07:36 -0800 |
---|---|---|
committer | Paul Eggert <eggert@cs.ucla.edu> | 2010-12-14 10:08:04 -0800 |
commit | dcb3f60d0af77ec06d58e4fa18c8ee2b80d10cc6 (patch) | |
tree | 1aeddfed97fdf4a6a8830e6bbc93787298321b21 /tests/check.mk | |
parent | 0da4d843003e9d38624e19c24c7fb670f1bb4749 (diff) | |
download | coreutils-dcb3f60d0af77ec06d58e4fa18c8ee2b80d10cc6.tar.xz |
tests: default to /tmp as the temporary directory
* tests/check.mk (TESTS_ENVIRONMENT): Default TMPDIR to /tmp,
rather than to the working directory; this is more common in
practice, which makes the tests more real-worldish; and it is
often faster. Also, it avoids some problems with NFS cleanups.
* tests/misc/sort-compress: Remove unnecessary code setting TMPDIR.
* tests/misc/sort-compress-proc: Likewise. Do the final sleep
only if TMPDIR is relative, which should be rarely given the
change to TESTS_ENVIRONMENT.
Diffstat (limited to 'tests/check.mk')
-rw-r--r-- | tests/check.mk | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/check.mk b/tests/check.mk index df0c92467..1391d516b 100644 --- a/tests/check.mk +++ b/tests/check.mk @@ -49,7 +49,8 @@ built_programs = \ # variables to test scripts. TESTS_ENVIRONMENT = \ . $(srcdir)/lang-default; \ - tmp__=$$TMPDIR; test -d "$$tmp__" || tmp__=.; \ + tmp__=$${TMPDIR-/tmp}; \ + test -d "$$tmp__" && test -w "$$tmp__" || tmp__=.; \ . $(srcdir)/envvar-check; \ TMPDIR=$$tmp__; export TMPDIR; \ exec 9>&2; \ |