merkle-tree-stream/tox.ini

69 lines
1.4 KiB
INI
Raw Normal View History

2019-07-08 09:40:40 +00:00
[tox]
envlist =
2019-10-06 14:11:27 +00:00
{py36,py37}
2019-07-08 09:40:40 +00:00
lint
sort
format
type
docs
changelog
metadata-release
skip_missing_interpreters = True
isolated_build = True
[testenv]
description = run the unit tests
deps =
pytest
pytest-cov
pytest-mock
2019-10-06 14:12:49 +00:00
commands = pytest test/ --cov={toxinidir}/merkle_tree_stream/ --no-cov-on-fail {posargs}
2019-07-08 09:40:40 +00:00
[testenv:lint]
description = lint the source
skipdist = True
2019-10-06 14:12:49 +00:00
deps = flake8
commands = flake8 {posargs} merkle_tree_stream/ test/
2019-07-08 09:40:40 +00:00
[testenv:sort]
description = sort the source
skipdist = True
2019-10-06 14:12:49 +00:00
deps = isort
commands = isort {posargs:-rc -c} -sp setup.cfg merkle_tree_stream/ test/
2019-07-08 09:40:40 +00:00
[testenv:format]
description = format the source
skipdist = True
2019-10-06 14:12:49 +00:00
deps = black
commands = black {posargs:--check} merkle_tree_stream/ test/
2019-07-08 09:40:40 +00:00
[testenv:type]
description = type check the source
skipdist = True
2019-10-06 14:12:49 +00:00
deps = mypy
commands = mypy merkle_tree_stream/ test/
2019-07-08 09:40:40 +00:00
[testenv:docs]
description = build the documentation
skipdist = True
2019-10-06 14:12:49 +00:00
extras = docs
commands = python -m setup build_sphinx
2019-07-08 09:40:40 +00:00
[testenv:changelog]
description = draft the changelog
skipdist = True
2019-10-06 14:12:49 +00:00
extras = changelog
commands = towncrier --draft
2019-07-08 09:40:40 +00:00
[testenv:metadata-release]
description = validate the package metadata
2019-10-06 14:12:49 +00:00
deps = twine
commands = twine check {toxworkdir}/dist/*
2019-07-08 09:40:40 +00:00
[testenv:release]
description = make a release
2019-10-06 14:12:49 +00:00
deps = {[testenv:metadata-release]deps}
2019-07-08 09:40:40 +00:00
commands =
python -m setup sdist bdist_wheel
twine upload {toxworkdir}/dist/*