forked from jmc265/docker-events-pushbullet
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtox.ini
51 lines (45 loc) · 1.65 KB
/
tox.ini
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
# content of: tox.ini , put in same dir as setup.py
[tox]
envlist = py39_pylint,py39_flake8,py39_shellcheck,py39_test
skipsdist=True
skip_missing_interpreters=true
#requires = setuptools >= 30.0.0
# pytest
[testenv:py39_flake8]
basepython = python3.9
setenv = PYTHONPATH = {toxinidir}/utils:{toxinidir}/.
install_command = python -m pip install -r ./requirements-test.txt {opts} {packages}
commands =
python -m pip install -r ./requirements-test.txt
flake8 --count app.py
[testenv:py39_pylint]
basepython = python3.9
setenv = PYTHONPATH = {toxinidir}/utils:{toxinidir}/.
install_command = python -m pip install -r ./requirements-test.txt {opts} {packages}
commands =
python -m pip install -r ./requirements-test.txt
pylint -rn --rcfile={toxinidir}/.pylintrc --load-plugins=pylint.extensions.docparams,pylint.extensions.mccabe --output-format=text app.py
[testenv:py39_shellcheck]
allowlist_externals = /bin/sh
basepython = python3.9
setenv = PYTHONPATH = {toxinidir}/utils:{toxinidir}/.
commands =
/bin/sh -c 'find * -name "*.sh" | xargs shellcheck'
[testenv:py39_test]
allowlist_externals = /bin/sh
#pytest # install pytest in the virtualenv where commands will be executed
basepython = python3.9
setenv = PYTHONPATH = {toxinidir}/utils:{toxinidir}/.
install_command = python -m pip install -r ./requirements-test.txt {opts} {packages}
commands =
python -m pip install -r ./requirements-test.txt
python -m pip freeze
# Test doctest
#pytest -v --doctest-modules {posargs:} ./app.py
# Test all
#pytest -v {posargs:} ./tests
[flake8]
ignore = E226,E302,E41,E241,W503
max-line-length = 140
exclude = */tests/*
max-complexity = 10