aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Bremner <david@tethera.net>2017-02-27 19:53:56 -0400
committerDavid Bremner <david@tethera.net>2017-02-27 20:01:42 -0400
commit1044775fc003914ee63b53254b7ca8700983a6e7 (patch)
treeb6e5b9e82bb145681b6ca0d4fb63abf255944e81
parenta4ddc63b2372bcb826d8c46e79e0f64ac7af255b (diff)
test: move GNUPGHOME to TEST_TMPDIR
We already use this directory for dtach sockets, so it makes sense to put gnupg sockets there as well. There doesn't seem to be a clean way to put a fully functional socket in a different location than GNUPGHOME.
-rw-r--r--test/test-lib-common.sh1
-rw-r--r--test/test-lib.sh2
2 files changed, 2 insertions, 1 deletions
diff --git a/test/test-lib-common.sh b/test/test-lib-common.sh
index 03ef1d2d..a96cfbeb 100644
--- a/test/test-lib-common.sh
+++ b/test/test-lib-common.sh
@@ -158,7 +158,6 @@ export HOME="${TMP_DIRECTORY}/home"
mkdir -p "${HOME}"
MAIL_DIR="${TMP_DIRECTORY}/mail"
-export GNUPGHOME="${TMP_DIRECTORY}/gnupg"
export NOTMUCH_CONFIG="${TMP_DIRECTORY}/notmuch-config"
mkdir -p "${test}"
diff --git a/test/test-lib.sh b/test/test-lib.sh
index 86e792a8..518d9c7f 100644
--- a/test/test-lib.sh
+++ b/test/test-lib.sh
@@ -270,6 +270,8 @@ die () {
GIT_EXIT_OK=
# Note: TEST_TMPDIR *NOT* exported!
TEST_TMPDIR=$(mktemp -d "${TMPDIR:-/tmp}/notmuch-test-$$.XXXXXX")
+# Put GNUPGHOME in TMPDIR to avoid problems with long paths.
+export GNUPGHOME="${TEST_TMPDIR}/gnupg"
trap 'trap_exit' EXIT
trap 'trap_signal' HUP INT TERM