-
Notifications
You must be signed in to change notification settings - Fork 20
/
tox.ini
82 lines (70 loc) · 1.56 KB
/
tox.ini
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
[tox]
envlist =
py38
py39
py310
black
flake8
pylint
prettier
skip_missing_interpreters=true
isolated_build = True
[tox:.package]
basepython = python3
[testenv]
commands =
poetry install
poetry run pytest {posargs:-n auto}
whitelist_externals = poetry
[testenv:black]
skip_install = true
whitelist_externals = poetry
commands =
poetry install
poetry run black --check --target-version py38 feeder/ tests/
[testenv:flake8]
skip_install = true
whitelist_externals = poetry
commands =
poetry install
poetry run flake8 feeder/ tests/
[testenv:pylint]
skip_install = true
whitelist_externals = poetry
commands =
poetry install
poetry run pylint feeder/
[testenv:prettier]
skip_install = true
install_command = npm -C {envdir} install --no-save --no-package-lock {packages}
setenv =
NODE_PATH = {envdir}/node_modules
deps =
commands =
{envdir}/node_modules/.bin/prettier --prose-wrap=always {posargs:--check} ./static/src
whitelist_externals =
npm
[pytest]
testpaths = tests
addopts =
--cov
--cov-config=tox.ini
--cov-report=term
--cov-report=xml
[flake8]
# Match Black Formatter
max-line-length = 88
extend-ignore = E203, E501, W503
[coverage:run]
source = feeder
branch = True
omit = feeder/database/alembic/*, feeder/util/mkcert.py, feeder/__main__.py, feeder/main.py
[coverage:report]
show_missing = True
fail_under = 75
[gh-actions]
python =
3.8: py38, black, flake8, pylint, prettier
3.9: py39, black, flake8, pylint, prettier
3.10: py310, black, flake8, pylint, prettier