mirror of
https://github.com/ubuntu/microk8s.git
synced 2021-05-23 02:23:41 +03:00
* Fix linting and switch to tox Switched linting to tox Added codspell to tox Fixed black and codespell identified mistakes
39 lines
823 B
INI
39 lines
823 B
INI
[tox]
|
|
skipsdist=True
|
|
skip_missing_interpreters = True
|
|
envlist = lint, unit, func-parallel
|
|
|
|
[testenv]
|
|
basepython = python3
|
|
envdir = {toxinidir}/.tox_env
|
|
passenv =
|
|
MK8S_*
|
|
deps =
|
|
black
|
|
flake8
|
|
flake8-colors
|
|
pep8-naming
|
|
codespell
|
|
-r{toxinidir}/tests/requirements.txt
|
|
|
|
[testenv:lint]
|
|
commands =
|
|
-flake8
|
|
codespell --ignore-words-list="aks" --quiet-level=2 --skip="*.patch,*.spec,.tox_env"
|
|
black --diff --check --exclude "/(\.eggs|\.git|\.tox|\.venv|\.build|dist|charmhelpers|mod)/" .
|
|
|
|
[testenv:func]
|
|
commands = pytest -v --ignore {toxinidir}/installer {posargs}
|
|
|
|
[testenv:func-parallel]
|
|
commands = pytest -v --ignore {toxinidir}/installer --dist=loadscope {posargs:-n 2}
|
|
|
|
[flake8]
|
|
exclude =
|
|
.git,
|
|
__pycache__,
|
|
.tox,
|
|
.tox_env,
|
|
max-complexity = 10
|
|
import-order-style = google
|