1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/security/nss/tests/libpkix/pkix_tests/runTests.sh Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,98 @@ 1.4 +#!/bin/sh 1.5 +# 1.6 +# This Source Code Form is subject to the terms of the Mozilla Public 1.7 +# License, v. 2.0. If a copy of the MPL was not distributed with this 1.8 +# file, You can obtain one at http://mozilla.org/MPL/2.0/. 1.9 +# 1.10 +# runTests.sh 1.11 +# 1.12 + 1.13 +curdir=`pwd` 1.14 +cd ../common 1.15 +. ./libpkix_init.sh > /dev/null 1.16 +cd ${curdir} 1.17 + 1.18 +testunit="PKIX" 1.19 + 1.20 +totalErrors=0 1.21 +utilErrors=0 1.22 +crlselErrors=0 1.23 +paramsErrors=0 1.24 +resultsErrors=0 1.25 +topErrors=0 1.26 +checkerErrors=0 1.27 +certselErrors=0 1.28 +quiet=0 1.29 + 1.30 +checkMemArg="" 1.31 +arenasArg="" 1.32 +quietArg="" 1.33 +memText="" 1.34 + 1.35 +### ParseArgs 1.36 +ParseArgs() # args 1.37 +{ 1.38 + while [ $# -gt 0 ]; do 1.39 + if [ $1 = "-checkmem" ]; then 1.40 + checkMemArg=$1 1.41 + memText=" (Memory Checking Enabled)" 1.42 + elif [ $1 = "-quiet" ]; then 1.43 + quietArg=$1 1.44 + quiet=1 1.45 + elif [ $1 = "-arenas" ]; then 1.46 + arenasArg=$1 1.47 + fi 1.48 + shift 1.49 + done 1.50 +} 1.51 + 1.52 +ParseArgs $* 1.53 + 1.54 +testHeadingEcho 1.55 + 1.56 +echo "RUNNING tests in certsel"; 1.57 +cd certsel; 1.58 +runTests.sh ${arenasArg} ${checkMemArg} ${quietArg} 1.59 +certselErrors=$? 1.60 + 1.61 +echo "RUNNING tests in checker"; 1.62 +cd ../checker; 1.63 +runTests.sh ${arenasArg} ${checkMemArg} ${quietArg} 1.64 +checkerErrors=$? 1.65 + 1.66 +echo "RUNNING tests in results"; 1.67 +cd ../results; 1.68 +runTests.sh ${arenasArg} ${checkMemArg} ${quietArg} 1.69 +resultsErrors=$? 1.70 + 1.71 +echo "RUNNING tests in params"; 1.72 +cd ../params; 1.73 +runTests.sh ${arenasArg} ${checkMemArg} ${quietArg} 1.74 +paramsErrors=$? 1.75 + 1.76 +echo "RUNNING tests in crlsel"; 1.77 +cd ../crlsel; 1.78 +runTests.sh ${arenasArg} ${checkMemArg} ${quietArg} 1.79 +crlselErrors=$? 1.80 + 1.81 +echo "RUNNING tests in store"; 1.82 +cd ../store; 1.83 +runTests.sh ${arenasArg} ${checkMemArg} ${quietArg} 1.84 +storeErrors=$? 1.85 + 1.86 +echo "RUNNING tests in util"; 1.87 +cd ../util; 1.88 +runTests.sh ${arenasArg} ${checkMemArg} ${quietArg} 1.89 +utilErrors=$? 1.90 + 1.91 +echo "RUNNING tests in top"; 1.92 +cd ../top; 1.93 +runTests.sh ${arenasArg} ${checkMemArg} ${quietArg} 1.94 +topErrors=$? 1.95 + 1.96 +totalErrors=`expr ${certselErrors} + ${checkerErrors} + ${resultsErrors} + ${paramsErrors} + ${crlselErrors} + ${storeErrors} + ${utilErrors} + ${topErrors}` 1.97 + 1.98 +testEndingEcho 1.99 + 1.100 +exit ${totalErrors} 1.101 +