/
tox.ini
66 lines (54 loc) · 1.45 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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
[tox]
envlist = py36-{pytest, codecov, dochtml, doctest, flake8, pylint, bandit}
[travis]
python =
3.6: py36
[travis:env]
TOX =
linter: flake8, pylint, bandit
pytest: pytest, codecov
docs: dochtml, doctest
[testenv]
basepython = python3
[testenv:py36-pytest]
deps =
-rrequirements.txt
-rtests/requirements.txt
commands = py.test --cov {envsitepackagesdir}/webgeocalc {posargs}
[testenv:py36-codecov]
passenv = CI TRAVIS TRAVIS_*
deps = codecov
commands = codecov
[testenv:py36-dochtml]
deps = -rdocs/requirements.txt
commands =
sphinx-build docs "{toxworkdir}/docs/_build" --color -W -bhtml {posargs}
[testenv:py36-doctest]
deps = -rdocs/requirements.txt
commands =
sphinx-build docs "{toxworkdir}/docs/_build" --color -W -bdoctest {posargs}
[testenv:py36-flake8]
skip_install = true
deps =
flake8
flake8-colors
flake8-docstrings
flake8-import-order
pep8-naming
mccabe
commands = flake8 setup.py docs/conf.py tests/ webgeocalc/
[flake8]
application-import-names = flake8
format = ${cyan}%(path)s${reset}:${yellow_bold}%(row)d${reset}:${green_bold}%(col)d${reset}: ${red_bold}%(code)s${reset} %(text)s
[testenv:py36-pylint]
skip_install = true
deps = pylint
commands =
pylint webgeocalc --disable=import-error
/bin/bash -c 'pylint setup.py docs/conf.py tests/*.py --disable=R0801,import-error'
[testenv:py36-bandit]
skip_install = true
deps = bandit
commands =
bandit -r webgeocalc
bandit -r tests --skip B101