1
0
mirror of https://github.com/enpaul/keyosk.git synced 2025-12-19 09:42:34 +00:00

Update toxfile with better optimized settings and task dist

Fix pycache cleanup in makefile
Update makefile to use tox doc env for building documentation
This commit is contained in:
2020-03-08 23:53:52 -04:00
parent ce3e2e34ab
commit ce20868b49
2 changed files with 18 additions and 20 deletions

31
tox.ini
View File

@@ -1,9 +1,10 @@
[tox]
envlist = py37, py36, lint, typing, security, docs
envlist = py36, py37, py38, format, static, docs
skip_missing_interpreters = true
isolated_build = true
[testenv]
description = Run the unit tests (pytest)
description = Run unit tests (pytest+{basepython})
deps =
marshmallow == 3.5.0
passlib == 1.7.2
@@ -14,32 +15,30 @@ deps =
commands =
pytest --cov={envsitepackagesdir}/keyosk --cov-config .coveragerc tests/ --cov-report term-missing
[testenv:lint]
description = Check code formatting against black and pylint
[testenv:format]
description = Enforce code formatting (pre-commit)
skip_install = true
deps =
pre-commit == 2.1.0
pylint == 2.3.1
astroid == 2.2.5
commands =
pre-commit run --all-files
pylint keyosk
[testenv:typing]
description = Check type annotations with mypy
[testenv:static]
description = Static code analysis (mypy+pylint+bandit)
skip_install = true
ignore_errors = true
deps =
pylint == 2.3.1
astroid == 2.2.5
mypy == 0.761
commands =
mypy keyosk --ignore-missing-imports --no-strict-optional
[testenv:security]
description = Check security vulnerabilities (bandit)
deps =
bandit == 1.6.2
commands =
mypy keyosk --ignore-missing-imports --no-strict-optional
pylint keyosk --rcfile .pylintrc
bandit --recursive keyosk
[testenv:docs]
description = Build documentation to check RST syntax (sphinx)
description = Build documentation (sphinx)
deps =
sphinx == 2.4.2
sphinx-autodoc-typehints == 1.10.3