Avoid running test if our conditions are not met.

This commit is contained in:
Nikos Mavrogiannopoulos
2014-04-19 12:15:16 +02:00
parent 03f6e7cc16
commit d2931cfd88

View File

@@ -37,9 +37,13 @@ if ! test -x $DOCKER;then
exit 77
fi
echo "****************************************************************"
echo "This test requires compiling ocserv using --enable-local-libopts"
echo "****************************************************************"
grep lo_cv_test_autoopts $srcdir/../config.log|grep lopts >/dev/null 2>&1
if test $? = 0;then
echo "****************************************************************"
echo "This test requires compiling ocserv using --enable-local-libopts"
echo "****************************************************************"
exit 77
fi
stop() {
$DOCKER stop test_ocserv
@@ -74,6 +78,10 @@ fi
sleep 5
IP=`$DOCKER inspect test_ocserv | grep IPAddress | cut -d '"' -f 4`
if test -z "$IP";then
echo "Detected IP is null!"
stop
fi
printf "test\ntest\n" >pass.tmp
openconnect $IP:5551 -u test --passwd-on-stdin --servercert=d66b507ae074d03b02eafca40d35f87dd81049d3 < pass.tmp &