1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23#!/bin/sh -e
export PREFIX=""
if [ -d 'venv' ] ; then
export PREFIX="venv/bin/"
fi
# export VERSION_SCRIPT="import sys; print('%s.%s' % sys.version_info[0:2])"
# export PYTHON_VERSION=`python -c "$VERSION_SCRIPT"`
#
# if [ -z "$TEST_DATABASE_URLS" ] ; then
# echo "Variable TEST_DATABASE_URLS must be set."
# exit 1
# fi
set -x
PYTHONPATH=. ${PREFIX}pytest --ignore venv -W ignore::DeprecationWarning --cov=savannah --cov=tests --cov-report= ${@}
${PREFIX}coverage report --show-missing
#${PREFIX}mypy databases --ignore-missing-imports --disallow-untyped-defs
#${PREFIX}autoflake --recursive databases tests
${PREFIX}black savannah tests --check