summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNikos Mavrogiannopoulos <nmav@gnutls.org>2014-04-05 10:12:42 +0200
committerNikos Mavrogiannopoulos <nmav@gnutls.org>2014-04-05 10:12:42 +0200
commitd9677096da77397d57591f2aba20796101ba4df7 (patch)
treed3a8ae243bf73665a6dc8992d1f8f83f7918f874
parent6a930e76bcd789724d1be3d41a3047cb41129d82 (diff)
downloadgnutls-d9677096da77397d57591f2aba20796101ba4df7.tar.gz
Use separate softhsm databases and config in tests to allow parallel runs.
-rw-r--r--.gitignore5
-rwxr-xr-xtests/suite/testpkcs115
2 files changed, 6 insertions, 4 deletions
diff --git a/.gitignore b/.gitignore
index 9587fdcc73..05e92c2e9e 100644
--- a/.gitignore
+++ b/.gitignore
@@ -702,5 +702,6 @@ tests/x509-extensions
tests/sec-params
tests/suite/pkcs11-chainverify
tests/suite/softhsm.config
-tests/suite/softhsm.db
-tests/suite/softhsm.db-journal
+tests/suite/softhsm*.db
+tests/suite/softhsm*.db-journal
+tests/suite/softhsm*.config
diff --git a/tests/suite/testpkcs11 b/tests/suite/testpkcs11
index 6f3ffd23d7..a315d5f6fc 100755
--- a/tests/suite/testpkcs11
+++ b/tests/suite/testpkcs11
@@ -56,12 +56,13 @@ if test "$1" = "pkcs15";then
exit 1
fi
else
- export SOFTHSM_CONF="softhsm.config"
+ export SOFTHSM_CONF="softhsm-testpkcs11.config"
if test -f /usr/lib/softhsm/libsofthsm.so;then
ADDITIONAL_PARAM="--provider /usr/lib/softhsm/libsofthsm.so"
else
ADDITIONAL_PARAM="--provider /usr/lib/softhsm/libsofthsm.so"
fi
+ echo "0:./softhsm-testpkcs11.db" > $SOFTHSM_CONF
echo -n "* Initializing smart card... "
softhsm --init-token --slot 0 --label "GnuTLS-Test" --so-pin 1234 --pin 1234 >/dev/null 2>&1
@@ -190,6 +191,6 @@ wait
echo ok
echo "* All smart cards tests succeeded"
-rm -f tmp-client.crt tmp-client.pub
+rm -f tmp-client.crt tmp-client.pub $SOFTHSM_CONF
exit 0