2016-02-14 00:56:32 +00:00
|
|
|
[tox]
|
2017-01-03 20:33:48 +00:00
|
|
|
envlist = py34, py35, py36, lint, requirements, typing
|
2016-02-14 00:56:32 +00:00
|
|
|
skip_missing_interpreters = True
|
|
|
|
|
|
|
|
[testenv]
|
|
|
|
setenv =
|
2017-02-01 03:30:53 +00:00
|
|
|
PYTHONPATH = {toxinidir}:{toxinidir}/homeassistant
|
2016-02-14 00:56:32 +00:00
|
|
|
; both temper-python and XBee modules have utf8 in their README files
|
|
|
|
; which get read in from setup.py. If we don't force our locale to a
|
|
|
|
; utf8 one, tox's env is reset. And the install of these 2 packages
|
|
|
|
; fail.
|
2017-05-07 23:55:22 +00:00
|
|
|
whitelist_externals = /usr/bin/env
|
|
|
|
install_command = /usr/bin/env LANG=C.UTF-8 pip install {opts} {packages}
|
2016-02-14 00:56:32 +00:00
|
|
|
commands =
|
2017-11-20 01:39:24 +00:00
|
|
|
py.test --timeout=15 --duration=10 --cov --cov-report= {posargs}
|
2016-02-14 00:56:32 +00:00
|
|
|
deps =
|
2017-05-07 05:37:31 +00:00
|
|
|
-r{toxinidir}/requirements_test_all.txt
|
2017-08-05 06:06:10 +00:00
|
|
|
-c{toxinidir}/homeassistant/package_constraints.txt
|
2016-02-14 00:56:32 +00:00
|
|
|
|
2017-11-20 01:39:24 +00:00
|
|
|
[testenv:pylint]
|
2017-12-20 10:50:31 +00:00
|
|
|
basepython = {env:PYTHON3_PATH:python3}
|
2016-02-15 10:00:46 +00:00
|
|
|
ignore_errors = True
|
2017-05-07 05:37:31 +00:00
|
|
|
deps =
|
|
|
|
-r{toxinidir}/requirements_all.txt
|
|
|
|
-r{toxinidir}/requirements_test.txt
|
2017-08-05 06:06:10 +00:00
|
|
|
-c{toxinidir}/homeassistant/package_constraints.txt
|
2016-02-14 00:56:32 +00:00
|
|
|
commands =
|
|
|
|
pylint homeassistant
|
|
|
|
|
2017-11-20 01:39:24 +00:00
|
|
|
[testenv:lint]
|
2017-12-20 10:50:31 +00:00
|
|
|
basepython = {env:PYTHON3_PATH:python3}
|
2016-02-14 00:56:32 +00:00
|
|
|
deps =
|
2017-11-20 01:39:24 +00:00
|
|
|
-r{toxinidir}/requirements_test.txt
|
2016-02-14 00:56:32 +00:00
|
|
|
commands =
|
2016-02-15 10:00:46 +00:00
|
|
|
python script/gen_requirements_all.py validate
|
2017-11-20 01:39:24 +00:00
|
|
|
flake8
|
|
|
|
pydocstyle homeassistant tests
|
2016-07-21 05:38:52 +00:00
|
|
|
|
|
|
|
[testenv:typing]
|
2017-12-20 10:50:31 +00:00
|
|
|
basepython = {env:PYTHON3_PATH:python3}
|
2016-07-22 06:54:25 +00:00
|
|
|
deps =
|
|
|
|
-r{toxinidir}/requirements_test.txt
|
2016-07-21 05:38:52 +00:00
|
|
|
commands =
|
|
|
|
mypy --silent-imports homeassistant
|