test.sh: Use PYTHON and PYTEST from environment
This commit is contained in:
parent
5fd400991b
commit
2a15473c20
7
test.sh
7
test.sh
|
@ -2,6 +2,7 @@
|
||||||
|
|
||||||
export PYTHONPATH=$(pwd)/tools:$(pwd)
|
export PYTHONPATH=$(pwd)/tools:$(pwd)
|
||||||
export TESTPATH="$(pwd)/test/"
|
export TESTPATH="$(pwd)/test/"
|
||||||
|
: ${PYTHON:=python} ${PYTEST:=py.test}
|
||||||
|
|
||||||
echo
|
echo
|
||||||
echo "Please ignore the possibly occurring output like this:"
|
echo "Please ignore the possibly occurring output like this:"
|
||||||
|
@ -9,7 +10,7 @@ echo " .../Patch*.patch: No such file or directory"
|
||||||
echo
|
echo
|
||||||
|
|
||||||
for i in $TESTPATH/test.*.py; do
|
for i in $TESTPATH/test.*.py; do
|
||||||
python $i
|
$PYTHON $i
|
||||||
RET=$?
|
RET=$?
|
||||||
if [ $RET -ne 0 ]; then
|
if [ $RET -ne 0 ]; then
|
||||||
exit $RET
|
exit $RET
|
||||||
|
@ -17,9 +18,9 @@ for i in $TESTPATH/test.*.py; do
|
||||||
done
|
done
|
||||||
|
|
||||||
echo "Check that rpmlint executes with no unexpected errors"
|
echo "Check that rpmlint executes with no unexpected errors"
|
||||||
python ./rpmlint -C $(pwd) test/*/*.rpm test/spec/*.spec >/dev/null
|
$PYTHON ./rpmlint -C $(pwd) test/*/*.rpm test/spec/*.spec >/dev/null
|
||||||
rc=$?
|
rc=$?
|
||||||
test $rc -eq 0 -o $rc -eq 64
|
test $rc -eq 0 -o $rc -eq 64
|
||||||
|
|
||||||
# SCLCheck tests
|
# SCLCheck tests
|
||||||
py.test -v
|
$PYTEST -v
|
||||||
|
|
Loading…
Reference in New Issue