summaryrefslogtreecommitdiffstats
path: root/t_client.sh.in
diff options
context:
space:
mode:
authorDavid Sommerseth <dazo@users.sourceforge.net>2010-08-18 15:00:13 +0200
committerDavid Sommerseth <dazo@users.sourceforge.net>2010-10-21 11:40:36 +0200
commitf25fe91a40aa3fad21657f590fd5f5c34d9f64d9 (patch)
tree73737e5cc35362d15108e5fd87648f2f5f934057 /t_client.sh.in
parent5086d75d8e8a3ec294cdb4ef5dacc403acc96bac (diff)
downloadopenvpn-f25fe91a40aa3fad21657f590fd5f5c34d9f64d9.tar.gz
openvpn-f25fe91a40aa3fad21657f590fd5f5c34d9f64d9.tar.xz
openvpn-f25fe91a40aa3fad21657f590fd5f5c34d9f64d9.zip
Test framework improvment - Do not FAIL if t_client.rc is missing
This is to avoid 'make check' fail if this extra test case is not configured. Signed-off-by: David Sommerseth <dazo@users.sourceforge.net> Acked-by: Gert Doering <gert@greenie.muc.de>
Diffstat (limited to 't_client.sh.in')
-rwxr-xr-xt_client.sh.in20
1 files changed, 10 insertions, 10 deletions
diff --git a/t_client.sh.in b/t_client.sh.in
index 664b2fd..d3a4295 100755
--- a/t_client.sh.in
+++ b/t_client.sh.in
@@ -12,6 +12,16 @@
# - for "ping6" checks: fping6 binary in $PATH
#
+if [ -r ./t_client.rc ] ; then
+ . ./t_client.rc
+elif [ -r "${srcdir}"/t_client.rc ] ; then
+ . "${srcdir}"/t_client.rc
+else
+ echo "$0: cannot find 't_client.rc' in current directory or" >&2
+ echo "$0: source dir ('${srcdir}'). SKIPPING TEST." >&2
+ exit 77
+fi
+
if [ ! -x ./openvpn ]
then
echo "no (executable) openvpn binary in current directory. FAIL." >&2
@@ -24,16 +34,6 @@ then
exit 1
fi
-if [ -r ./t_client.rc ] ; then
- . ./t_client.rc
-elif [ -r "${srcdir}"/t_client.rc ] ; then
- . "${srcdir}"/t_client.rc
-else
- echo "cannot find 't_client.rc' in current directory or" >&2
- echo "source dir ('${srcdir}'). FAIL." >&2
- exit 1
-fi
-
if [ -z "$CA_CERT" ] ; then
echo "CA_CERT not defined in 't_client.rc'. SKIP test." >&2
exit 0