mirror of
https://github.com/davidhalter/parso.git
synced 2026-02-06 09:57:58 +08:00
tests: add coverage tox factor, use it on Travis
This commit is contained in:
committed by
Dave Halter
parent
7770e73609
commit
c4d6de2aab
13
tox.ini
13
tox.ini
@@ -1,19 +1,16 @@
|
||||
[tox]
|
||||
envlist = py27, py33, py34, py35, py36, py37, pypy
|
||||
envlist = {py27,py33,py34,py35,py36,py37,pypy}{,-coverage}
|
||||
[testenv]
|
||||
extras = testing
|
||||
deps =
|
||||
py26,py33: pytest>=3.0.7,<3.3
|
||||
py26,py33: setuptools<37
|
||||
coverage: coverage
|
||||
setenv =
|
||||
# https://github.com/tomchristie/django-rest-framework/issues/1957
|
||||
# tox corrupts __pycache__, solution from here:
|
||||
PYTHONDONTWRITEBYTECODE=1
|
||||
coverage: TOX_TESTENV_COMMAND=coverage run -m pytest
|
||||
commands =
|
||||
pytest {posargs:parso test}
|
||||
[testenv:cov]
|
||||
deps =
|
||||
coverage
|
||||
commands =
|
||||
coverage run --source parso -m pytest
|
||||
coverage report
|
||||
{env:TOX_TESTENV_COMMAND:pytest} {posargs}
|
||||
coverage: coverage report
|
||||
|
||||
Reference in New Issue
Block a user