From 8b5d2a552dad22f0b08bdc9081dafa871d0129d8 Mon Sep 17 00:00:00 2001 From: J08nY Date: Tue, 27 Jun 2017 19:42:55 +0200 Subject: Add coverage testing. --- tox.ini | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'tox.ini') diff --git a/tox.ini b/tox.ini index 69ec284..45633d4 100644 --- a/tox.ini +++ b/tox.ini @@ -1,5 +1,5 @@ [tox] -envlist = qa, py35, py36, setup35, setup36 +envlist = qa, {py35, py36}{,-dev,-head}{-nocov,-cov} setup35, setup36 skip_missing_interpreters = True [testenv] @@ -8,13 +8,17 @@ deps = flufl.testing parameterized nose2 + cov: coverage head: git+https://gitlab.com/mailman/mailman.git head: git+https://github.com/SecurityInnovation/PGPy # Expects a mailman repo and PGPy repo in parent directory. dev: -e../mailman dev: -e../PGPy commands = - python -m nose2 -v {posargs} + nocov: python -m nose2 -v {posargs} + cov: python -m coverage run {[coverage]rc} -m nose2 -v {posargs} + cov: python -m coverage html {[coverage]rc} + cov: python -m coverage report -m {[coverage]rc} [testenv:qa] basepython = python3 @@ -37,6 +41,10 @@ recreate = True basepython = python3.6 commands = pip install -e . +[coverage] +rcfile = {toxinidir}/coverage.ini +rc = --rcfile={[coverage]rcfile} + [flake8] jobs = 1 max-line-length = 79 -- cgit v1.2.3-70-g09d2