This commit is contained in:
Sylvain Bellemare 2017-12-19 05:07:21 +01:00
parent 8bd8dc02a4
commit 1ebeaae6d9
No known key found for this signature in database
GPG Key ID: C38AE0ECCAB7D5C8
3 changed files with 5 additions and 4 deletions

View File

@ -8,13 +8,13 @@ elif [[ "${BIGCHAINDB_DATABASE_BACKEND}" == mongodb && \
-z "${BIGCHAINDB_DATABASE_SSL}" ]]; then
# Run the full suite of tests for MongoDB over an unsecure connection
pytest -sv --database-backend=mongodb -m "serial"
pytest -sv --database-backend=mongodb --cov=bigchaindb -m "not serial"
pytest -sv --database-backend=mongodb --cov-config=setup.cfg --cov=bigchaindb -m "not serial"
elif [[ "${BIGCHAINDB_DATABASE_BACKEND}" == mongodb && \
"${BIGCHAINDB_DATABASE_SSL}" == true ]]; then
# Run a sub-set of tests over SSL; those marked as 'pytest.mark.bdb_ssl'.
pytest -sv --database-backend=mongodb-ssl --cov=bigchaindb -m bdb_ssl
pytest -sv --database-backend=mongodb-ssl --cov-config=setup.cfg --cov=bigchaindb -m bdb_ssl
else
# Run the full suite of tests for RethinkDB (the default backend when testing)
pytest -sv -m "serial"
pytest -sv --cov=bigchaindb -m "not serial"
pytest -sv --cov-config=setup.cfg --cov=bigchaindb -m "not serial"
fi

View File

@ -4,6 +4,7 @@ test=pytest
[coverage:run]
source = .
omit = *test*
branch = True
[flake8]
max_line_length = 119

View File

@ -15,7 +15,7 @@ setenv =
deps = {[base]deps}
install_command = pip install {opts} {packages}
extras = test
commands = pytest -v -n auto --cov=bigchaindb --basetemp={envtmpdir}
commands = pytest -v -n auto --cov-config=setup.cfg --cov=bigchaindb --basetemp={envtmpdir}
[testenv:flake8]
basepython = {[base]basepython}