From: Alon Bar-Lev Date: Fri, 20 Jan 2017 21:39:41 +0000 (+0200) Subject: tests: skip tests that requires tools if tools are disabled X-Git-Tag: gnutls_3_6_0~1053 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=087298974ca620a4aebfdc421b2f067924057749;p=thirdparty%2Fgnutls.git tests: skip tests that requires tools if tools are disabled building with --disable-tools should not cause test failure. Signed-off-by: Alon Bar-Lev --- diff --git a/tests/key-tests/illegal-rsa b/tests/key-tests/illegal-rsa index aacd97e306..9e6a5b6895 100755 --- a/tests/key-tests/illegal-rsa +++ b/tests/key-tests/illegal-rsa @@ -22,12 +22,16 @@ srcdir="${srcdir:-.}" CERTTOOL="${CERTTOOL:-../../src/certtool${EXEEXT}}" GREP="${GREP:-grep}" -TMPFILE=tmp-key.$$.p8 +if ! test -x "${CERTTOOL}"; then + exit 77 +fi if ! test -z "${VALGRIND}"; then VALGRIND="${LIBTOOL:-libtool} --mode=execute ${VALGRIND} --error-exitcode=1" fi +TMPFILE=tmp-key.$$.p8 + ${VALGRIND} "${CERTTOOL}" -k --password 1234 --infile "${srcdir}/data/p8key-illegal.pem" rc=$? # We're done.