1
0
mirror of https://gitlab.crans.org/bde/nk20 synced 2025-02-05 23:03:02 +00:00
nk20/tox.ini

58 lines
1.3 KiB
INI
Raw Normal View History

2019-07-08 12:55:48 +02:00
[tox]
2020-02-18 20:58:01 +01:00
envlist =
2020-08-09 19:34:01 +02:00
# Debian Buster Python
2020-02-18 20:58:01 +01:00
py37-django22
2020-08-09 19:34:01 +02:00
# Ubuntu 20.04 Python
py38-django22
2020-08-09 19:34:01 +02:00
2020-02-18 20:58:01 +01:00
linters
2019-07-08 12:55:48 +02:00
skipsdist = True
[testenv]
2020-02-18 20:58:01 +01:00
setenv =
PYTHONWARNINGS = all
2019-07-08 12:55:48 +02:00
deps =
2020-03-08 22:42:22 +01:00
-r{toxinidir}/requirements/base.txt
-r{toxinidir}/requirements/cas.txt
-r{toxinidir}/requirements/production.txt
2019-07-08 12:55:48 +02:00
coverage
commands =
2019-07-16 15:24:05 +02:00
./manage.py makemigrations
2020-08-09 19:54:31 +02:00
coverage run --omit='*migrations*' --source=apps,note_kfet ./manage.py test
2019-07-08 12:55:48 +02:00
coverage report -m
[testenv:linters]
deps =
2020-03-08 22:42:22 +01:00
-r{toxinidir}/requirements/base.txt
-r{toxinidir}/requirements/cas.txt
-r{toxinidir}/requirements/production.txt
2019-07-08 12:55:48 +02:00
flake8
flake8-colors
flake8-import-order
flake8-typing-imports
pep8-naming
pyflakes
commands =
2020-04-11 23:02:12 +02:00
flake8 apps/activity apps/api apps/logs apps/member apps/note apps/permission apps/treasury apps/wei
2019-07-08 12:55:48 +02:00
[flake8]
2020-02-18 20:58:01 +01:00
# Ignore too many errors, should be reduced in the future
2020-04-05 21:56:56 +02:00
ignore = D203, W503, E203, I100, I101, C901
2019-07-08 12:55:48 +02:00
exclude =
.tox,
.git,
__pycache__,
build,
dist,
*.pyc,
*.egg-info,
.cache,
2019-07-16 12:59:11 +02:00
.eggs,
*migrations*
2019-07-08 12:55:48 +02:00
max-complexity = 10
2020-02-18 20:58:01 +01:00
max-line-length = 160
2019-07-08 12:55:48 +02:00
import-order-style = google
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