bumpver/travis_run_tests.sh

24 lines
665 B
Bash
Raw Normal View History

2018-09-05 09:57:52 +02:00
#!/bin/bash
set -e
rst2html5 --strict README.rst > /dev/null
rst2html5 --strict CHANGELOG.rst > /dev/null
# first test module from installed wheel
python -m pip install $(ls -1t dist/pycalver*.whl | head -n 1)
grep 'coding: utf-8' $(python -c 'import pycalver;print(pycalver.__file__)')
python -m pip install pytest
python -m pytest test/
2018-09-05 09:57:52 +02:00
if [[ $(python -c "import sys;print(sys.version[:3])") == "3.7" ]]; then
python -m pip install $(cat requirements-test.txt)
2018-09-05 09:57:52 +02:00
python -m flake8 src/pycalver/
2018-09-05 20:22:28 +02:00
MYPYPATH=stubs/ python -m mypy src/pycalver/;
2018-09-05 09:57:52 +02:00
# next test module from src/
2018-09-05 20:22:28 +02:00
PYTHONPATH=src/:$PYTHONPATH python -m pytest --cov=pycalver test/;
codecov
2018-09-05 09:57:52 +02:00
fi