Skip to content
Snippets Groups Projects
tox.ini 1.13 KiB
Newer Older
envlist = py3,flake8, check-manifest, yamllint, black
  {envpython} -m pytest {posargs}

[pytest]
python_files = *test_*.py
testpaths = test
addopts = -r fEs

[testenv:flake8]
basepython = python3
skip_install = true
deps =
  flake8
commands = flake8

[flake8]
basepython = python3
ignore = W503, E203, E731, E231
max-line-length = 100
exclude = doc/*,.tox/*,./test/data/*

[testenv:check-manifest]
skip_install = true
deps =
  check-manifest
commands =
  {envpython} -m check_manifest {toxinidir}

[testenv:pypi-publish]
basepython = python3
skip_install = true
allowlist_externals = rm
deps =
  twine
passenv =
  TWINE_USERNAME
  TWINE_PASSWORD
commands =
  rm -rf build dist .egg .egg-info
  python3 setup.py sdist bdist_wheel
  twine check dist/*
  twine upload --skip-existing dist/*
[testenv:yamllint]
skip_install = true
deps = yamllint
commands =
  yamllint .

[testenv:black]
basepython = python3
skip_install = true
deps =
  black >= 22.12
commands = black --check .

[testenv:black-run]
basepython = python3
skip_install = true
deps =
  black >= 22.12