Files
jedi/tox.ini
2020-07-02 00:17:21 +02:00

40 lines
1.2 KiB
INI

[tox]
envlist = py36, py37, py38, qa
[testenv]
extras = testing
deps =
# numpydoc for typing scipy stack
numpydoc
sphinx
cov: coverage
# Overwrite the parso version (only used sometimes).
git+https://github.com/davidhalter/parso.git
passenv = JEDI_TEST_ENVIRONMENT
setenv =
# https://github.com/tomchristie/django-rest-framework/issues/1957
# tox corrupts __pycache__, solution from here:
PYTHONDONTWRITEBYTECODE=1
# Enable all warnings.
PYTHONWARNINGS=always
# To test Jedi in different versions than the same Python version, set a
# different test environment.
env36: JEDI_TEST_ENVIRONMENT=36
env37: JEDI_TEST_ENVIRONMENT=37
env38: JEDI_TEST_ENVIRONMENT=38
interpreter: JEDI_TEST_ENVIRONMENT=interpreter
commands =
pytest {posargs}
[testenv:cov-py37]
commands =
coverage run --source jedi -m pytest {posargs}
coverage report
[testenv:sith]
commands =
{envpython} -c "import os; a='{envtmpdir}'; os.path.exists(a) or os.makedirs(a)"
{envpython} sith.py --record {envtmpdir}/record.json random {posargs:jedi}
[testenv:qa]
# Ignore F401, which are unused imports. flake8 is a primitive tool and is sometimes wrong.
commands = flake8 --extend-ignore F401 {posargs:jedi}
deps =
extras = qa