[PATCH] tests: allow running tests with alternate ocserv
Mike Miller
mtmiller at debian.org
Thu Dec 22 14:40:46 PST 2016
Allow $OCSERV in the caller's environment to override the default ocserv
system installation.
Signed-off-by: Mike Miller <mtmiller at debian.org>
---
tests/common.sh | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/tests/common.sh b/tests/common.sh
index 6d5736a..fbfde7a 100644
--- a/tests/common.sh
+++ b/tests/common.sh
@@ -19,13 +19,13 @@
#this test can only be run as root
-if ! test -x /usr/sbin/ocserv;then
+OCSERV=${OCSERV:-/usr/sbin/ocserv}
+
+if ! test -x ${OCSERV};then
echo "You need ocserv to run this test"
exit 77
fi
-OCSERV=/usr/sbin/ocserv
-
SOCKDIR="./sockwrap.$$.tmp"
mkdir -p $SOCKDIR
export SOCKET_WRAPPER_DIR=$SOCKDIR
--
2.10.2
More information about the openconnect-devel
mailing list