forked from dalibo/check_patroni
-
Notifications
You must be signed in to change notification settings - Fork 0
/
tox.ini
49 lines (44 loc) · 1.17 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
[tox]
# the versions specified here are overridden by github workflow
envlist = lint, mypy, py{39,310,311,312,313}
skip_missing_interpreters = True
[testenv]
extras = test
commands =
pytest {toxinidir}/check_patroni {toxinidir}/tests {posargs:-vv --log-level=debug}
[testenv:lint]
skip_install = True
deps =
codespell
black
flake8
isort
commands =
codespell {toxinidir}/check_patroni {toxinidir}/tests {toxinidir}/docs/ {toxinidir}/RELEASE.md {toxinidir}/CONTRIBUTING.md
black --check --diff {toxinidir}/check_patroni {toxinidir}/tests
flake8 {toxinidir}/check_patroni {toxinidir}/tests
isort --check --diff {toxinidir}/check_patroni {toxinidir}/tests
[testenv:mypy]
deps =
mypy
commands =
# we need to install types-requests
mypy --install-types --non-interactive
[testenv:build]
deps =
wheel
setuptools
twine
allowlist_externals =
rm
commands =
rm --verbose --recursive --force {toxinidir}/dist/
python -m build
python -m twine check dist/*
[testenv:upload]
# requires a check_patroni section in ~/.pypirc
skip_install = True
deps =
twine
commands =
python -m twine upload --repository check_patroni dist/*