add bandit and flake8 plugins to tox, remove redundant deps
This commit is contained in:
parent
14f6125f4e
commit
605a82680d
26
tox.ini
26
tox.ini
@ -4,22 +4,13 @@
|
|||||||
# and then run "tox" from this directory.
|
# and then run "tox" from this directory.
|
||||||
|
|
||||||
[tox]
|
[tox]
|
||||||
envlist = py37,lint
|
envlist = py37,security,lint
|
||||||
|
|
||||||
[testenv]
|
[testenv]
|
||||||
# build a wheel and test it
|
# build a wheel and test it
|
||||||
wheel = true
|
wheel = true
|
||||||
wheel_build_env = build
|
wheel_build_env = build
|
||||||
|
|
||||||
deps =
|
|
||||||
flake8
|
|
||||||
flake8-docstrings
|
|
||||||
pytest
|
|
||||||
pytest-cov
|
|
||||||
commands =
|
|
||||||
flake8
|
|
||||||
pytest --cov={envsitepackagesdir}/incorporealcms/
|
|
||||||
|
|
||||||
# whitelist commands we need
|
# whitelist commands we need
|
||||||
whitelist_externals = ln
|
whitelist_externals = ln
|
||||||
|
|
||||||
@ -38,15 +29,28 @@ commands =
|
|||||||
coverage report -m --fail-under=80
|
coverage report -m --fail-under=80
|
||||||
ln -sf {distdir} dist
|
ln -sf {distdir} dist
|
||||||
|
|
||||||
|
[testenv:security]
|
||||||
|
# run security checks
|
||||||
|
#
|
||||||
|
# again it seems the most valuable here to run against the packaged code
|
||||||
|
deps =
|
||||||
|
bandit
|
||||||
|
commands =
|
||||||
|
bandit {envsitepackagesdir}/incorporealcms/ -r
|
||||||
|
|
||||||
[testenv:lint]
|
[testenv:lint]
|
||||||
# run style checks
|
# run style checks
|
||||||
skip_install = true
|
skip_install = true
|
||||||
deps =
|
deps =
|
||||||
flake8
|
flake8
|
||||||
|
flake8-blind-except
|
||||||
|
flake8-builtins
|
||||||
flake8-docstrings
|
flake8-docstrings
|
||||||
|
flake8-executable
|
||||||
|
flake8-logging-format
|
||||||
commands =
|
commands =
|
||||||
flake8
|
flake8
|
||||||
- flake8 --disable-noqa --select=E,W,F,C,D
|
- flake8 --disable-noqa --select=E,W,F,C,D,A,G,B
|
||||||
|
|
||||||
[flake8]
|
[flake8]
|
||||||
max-line-length = 120
|
max-line-length = 120
|
||||||
|
Loading…
Reference in New Issue
Block a user