chrony/test/simulation/run
Miroslav Lichvar 8b676502de test: don't download files in tests
Remove automatic download and compilation of clknetsim. If clknetsim is
not found, skip all simulation tests, but don't fail "make check".
Also, respect the CLKNETSIM_PATH environment variable.
2016-02-05 15:20:40 +01:00

24 lines
574 B
Bash
Executable file

#!/bin/bash
passed=() failed=() skipped=()
[ $# -gt 0 ] && tests=($@) || tests=([0-9]*-*[^_])
for test in "${tests[@]}"; do
echo "$test ($[${#passed[@]} + ${#failed[@]} + 1]/${#tests[@]})"
./$test
case $? in
0) passed=(${passed[@]} $test);;
9) skipped=(${skipped[@]} $test);;
*) failed=(${failed[@]} $test);;
esac
echo
done
echo "SUMMARY:"
echo " TOTAL $[${#passed[@]} + ${#failed[@]} + ${#skipped[@]}]"
echo " PASSED ${#passed[@]}"
echo " FAILED ${#failed[@]} (${failed[@]})"
echo " SKIPPED ${#skipped[@]} (${skipped[@]})"
[ ${#failed[@]} -eq 0 ]