endif()
if(WITH_TESTS)
include(AddCephTest)
- add_tox_test(mgr ${CMAKE_CURRENT_SOURCE_DIR} TOX_ENVS py3 mypy)
+ add_tox_test(mgr ${CMAKE_CURRENT_SOURCE_DIR} TOX_ENVS py3 mypy flake8)
endif()
# Location needs to match default setting for mgr_module_path, currently:
mypy,
test,
fix
+ flake8
skipsdist = true
requires = cython
[flake8]
max-line-length = 100
+ignore =
+ E114,
+ E121,
+ E122,
+ E124,
+ E126,
+ E128,
+ E131,
+ E225,
+ E226,
+ E231,
+ E241,
+ E261,
+ E302,
+ E306,
+ E501,
+ E703,
+ E704,
+ E712,
+ E722,
+ E731,
+ E741,
+ F401,
+ F541,
+ F632,
+ F811,
+ F821,
+ F841,
+ W291,
+ W503,
+ W504,
exclude =
.tox,
.vagrant,
*.pyc,
templates,
.eggs
+statistics = True
[autopep8]
addopts =
python --version
autopep8 {[autopep8]addopts} {posargs: \
cephadm/ orchestrator/}
+
+[testenv:flake8]
+basepython = python3
+deps =
+ flake8
+modules =
+ cephadm
+ orchestrator
+commands =
+ flake8 --config=tox.ini {posargs} \
+ {posargs:{[testenv:flake8]modules}}