summaryrefslogtreecommitdiff
path: root/tests/scripts
diff options
context:
space:
mode:
authorNikos Mavrogiannopoulos <nmav@redhat.com>2014-09-19 10:40:44 +0200
committerNikos Mavrogiannopoulos <nmav@redhat.com>2014-09-19 10:51:55 +0200
commit8b2c9137356e8f12421275bc8d039517002e46f0 (patch)
treed9b749740e2479b1affbe5fadfeb0ec3b4d928ae /tests/scripts
parent8a35aa03cab2c54e1f9133ff0a3effadc4c6494e (diff)
downloadgnutls-8b2c9137356e8f12421275bc8d039517002e46f0.tar.gz
tests: enhanced test suite to pass more of the PKCS #11 API under valgrind
Diffstat (limited to 'tests/scripts')
-rw-r--r--tests/scripts/common.sh17
1 files changed, 17 insertions, 0 deletions
diff --git a/tests/scripts/common.sh b/tests/scripts/common.sh
index 2ba11b4af3..50880f53c4 100644
--- a/tests/scripts/common.sh
+++ b/tests/scripts/common.sh
@@ -43,6 +43,23 @@ launch_server() {
fi
}
+launch_pkcs11_server() {
+ PARENT=$1;
+ shift;
+ PROVIDER=$1;
+ shift;
+ $VALGRIND $SERV $PROVIDER $DEBUG -p $PORT $* &
+ LOCALPID="$!";
+ trap "[ ! -z \"${LOCALPID}\" ] && kill ${LOCALPID};" 15
+ wait "${LOCALPID}"
+ LOCALRET="$?"
+ if [ "${LOCALRET}" != "0" ] && [ "${LOCALRET}" != "143" ] ; then
+ # Houston, we'v got a problem...
+ echo "Failed to launch a gnutls-serv server !"
+ kill -10 ${PARENT}
+ fi
+}
+
launch_bare_server() {
PARENT=$1;
shift;