Improved tests script

This commit is contained in:
Fabio Manganiello 2021-02-23 01:09:03 +01:00
parent 1a7d0a3b07
commit d1b7b1768c

View file

@ -1,11 +1,22 @@
#!/bin/bash #!/bin/bash
PYTHON=python PYTHON=python
tests_ret=0
for testcase in tests/test_*.py for testcase in tests/test_*.py
do do
$PYTHON -m unittest $testcase $PYTHON -m unittest $testcase
test_ret=$?
if [[ $test_ret != 0 ]]; then
tests_ret=$test_ret
echo "-------------" >&2
echo "Test FAILED: $testcase" >&2
echo "-------------" >&2
fi
done done
# vim:sw=4:ts=4:et: exit $tests_ret
# vim:sw=4:ts=4:et: