2020-09-23 02:17:30 -04:00
|
|
|
[tox]
|
2024-08-16 14:30:20 -04:00
|
|
|
envlist = py3{8,9,10,11,12} static, static-tests, security
|
2020-11-26 12:54:14 -05:00
|
|
|
skip_missing_interpreters = true
|
2020-09-23 02:17:30 -04:00
|
|
|
|
|
|
|
[testenv]
|
2020-09-23 20:36:11 -04:00
|
|
|
description = Run the tests
|
2020-09-26 10:45:47 -04:00
|
|
|
require_locked_deps = true
|
2021-04-19 23:47:20 -04:00
|
|
|
require_poetry = true
|
2020-11-12 00:25:40 -05:00
|
|
|
locked_deps =
|
2020-09-24 21:55:23 -04:00
|
|
|
pytest
|
|
|
|
pytest-cov
|
|
|
|
toml
|
2020-09-23 02:17:30 -04:00
|
|
|
commands =
|
2022-01-05 01:13:44 -05:00
|
|
|
pytest {toxinidir}/tests/ \
|
|
|
|
--cov {toxinidir}/tox_poetry_installer \
|
|
|
|
--cov-config {toxinidir}/.coveragerc \
|
|
|
|
--cov-report term-missing
|
2020-09-23 20:36:11 -04:00
|
|
|
|
|
|
|
[testenv:static]
|
2020-09-24 21:55:23 -04:00
|
|
|
description = Static formatting and quality enforcement
|
2023-05-20 00:03:44 +02:00
|
|
|
basepython = py310
|
2020-11-11 22:34:42 -05:00
|
|
|
platform = linux
|
2020-09-23 20:36:11 -04:00
|
|
|
ignore_errors = true
|
2020-11-12 00:25:40 -05:00
|
|
|
locked_deps =
|
2020-09-23 20:36:11 -04:00
|
|
|
black
|
2020-11-26 12:41:06 -05:00
|
|
|
blacken-docs
|
2024-08-16 14:41:25 -04:00
|
|
|
isort
|
2021-04-16 01:26:12 -04:00
|
|
|
mdformat
|
|
|
|
mdformat-gfm
|
|
|
|
mypy
|
|
|
|
pre-commit
|
|
|
|
pre-commit-hooks
|
2020-11-26 12:41:06 -05:00
|
|
|
pylint
|
2022-01-05 01:40:02 -05:00
|
|
|
types-toml
|
2020-09-23 20:36:11 -04:00
|
|
|
commands =
|
2022-01-05 01:13:44 -05:00
|
|
|
pre-commit run \
|
|
|
|
--all-files
|
|
|
|
pylint {toxinidir}/tox_poetry_installer/ \
|
|
|
|
--rcfile {toxinidir}/.pylintrc
|
|
|
|
mypy {toxinidir}/tox_poetry_installer/ \
|
|
|
|
--ignore-missing-imports \
|
|
|
|
--no-strict-optional
|
2020-09-24 21:55:23 -04:00
|
|
|
|
|
|
|
[testenv:static-tests]
|
|
|
|
description = Static formatting and quality enforcement for the tests
|
2023-05-20 00:03:44 +02:00
|
|
|
basepython = py310
|
2020-11-11 22:34:42 -05:00
|
|
|
platform = linux
|
2021-04-16 22:33:24 -04:00
|
|
|
ignore_errors = true
|
2020-11-12 00:25:40 -05:00
|
|
|
locked_deps =
|
2020-09-24 21:55:23 -04:00
|
|
|
pylint
|
2021-04-16 22:33:24 -04:00
|
|
|
pytest
|
2020-09-24 21:55:23 -04:00
|
|
|
mypy
|
2024-08-16 14:41:25 -04:00
|
|
|
toml
|
2022-01-05 01:40:02 -05:00
|
|
|
types-toml
|
2020-09-24 21:55:23 -04:00
|
|
|
commands =
|
2022-01-05 01:13:44 -05:00
|
|
|
pylint {toxinidir}/tests/ \
|
|
|
|
--rcfile {toxinidir}/.pylintrc
|
|
|
|
mypy {toxinidir}/tests/ \
|
|
|
|
--ignore-missing-imports \
|
|
|
|
--no-strict-optional
|
2020-09-23 20:36:11 -04:00
|
|
|
|
|
|
|
[testenv:security]
|
|
|
|
description = Security checks
|
2023-05-20 00:03:44 +02:00
|
|
|
basepython = py310
|
2020-11-11 22:34:42 -05:00
|
|
|
platform = linux
|
2021-04-16 22:33:24 -04:00
|
|
|
ignore_errors = true
|
2022-01-05 01:13:44 -05:00
|
|
|
skip_install = true
|
2020-11-12 00:25:40 -05:00
|
|
|
locked_deps =
|
2020-09-23 20:36:11 -04:00
|
|
|
bandit
|
|
|
|
safety
|
2020-09-24 21:55:23 -04:00
|
|
|
poetry
|
2020-09-23 20:36:11 -04:00
|
|
|
commands =
|
2022-01-05 01:13:44 -05:00
|
|
|
bandit {toxinidir}/tox_poetry_installer/ \
|
|
|
|
--recursive \
|
|
|
|
--quiet
|
|
|
|
bandit {toxinidir}/tests/ \
|
|
|
|
--recursive \
|
|
|
|
--quiet \
|
|
|
|
--skip B101
|