mirror of https://github.com/cowrie/cowrie.git
101 lines
2.2 KiB
INI
101 lines
2.2 KiB
INI
[tox]
|
|
skipsdist = True
|
|
envlist = lint,docs,typing,py39,py310,py311,py312,py313,pypy39,pypy310
|
|
deps = -r{toxinidir}/requirements.txt
|
|
skip_missing_interpreters = True
|
|
|
|
[gh-actions]
|
|
python =
|
|
3.9: py39
|
|
3.10: py310, lint, docs, typing, pypi
|
|
3.11: py311
|
|
3.12: py312
|
|
3.13: py313
|
|
pypy-3.9: pypy39
|
|
pypy-3.10: pypy310
|
|
|
|
[testenv]
|
|
setenv =
|
|
PYTHONPATH = {toxinidir}/src
|
|
deps =
|
|
-r{toxinidir}/requirements.txt
|
|
# libvirt-python==5.5.0
|
|
|
|
commands =
|
|
python -m unittest discover src --verbose
|
|
|
|
|
|
[testenv:pypi]
|
|
deps =
|
|
-r{toxinidir}/requirements.txt
|
|
-r{toxinidir}/requirements-dev.txt
|
|
allowlist_externals =
|
|
twine
|
|
commands =
|
|
python -m build
|
|
twine check dist/*
|
|
# - twine upload --verbose --repository testpypi dist/*\n
|
|
# python -m pip install -i https://test.pypi.org/simple/ cowrie
|
|
|
|
|
|
[testenv:lint]
|
|
deps =
|
|
-r{toxinidir}/requirements.txt
|
|
-r{toxinidir}/requirements-dev.txt
|
|
allowlist_externals =
|
|
yamllint
|
|
commands =
|
|
ruff check {toxinidir}/src
|
|
- yamllint {toxinidir}
|
|
- pyright
|
|
- pylint {toxinidir}/src
|
|
basepython = python3.10
|
|
|
|
|
|
[testenv:docs]
|
|
setenv =
|
|
PYTHONPATH = {toxinidir}/src
|
|
changedir = docs
|
|
deps =
|
|
-r{toxinidir}/requirements.txt
|
|
-r{toxinidir}/requirements-dev.txt
|
|
commands =
|
|
sphinx-build -W -b html -d {envtmpdir}/doctrees . {envtmpdir}/html
|
|
basepython = python3.10
|
|
|
|
|
|
[testenv:typing]
|
|
description = run static type checkers
|
|
|
|
deps =
|
|
-r{toxinidir}/requirements.txt
|
|
-r{toxinidir}/requirements-dev.txt
|
|
|
|
commands =
|
|
mypy \
|
|
--cache-dir="{toxworkdir}/mypy_cache" \
|
|
--config-file="{toxinidir}/pyproject.toml" \
|
|
{tty:--pretty:} \
|
|
{posargs:src}
|
|
- mypyc \
|
|
--cache-dir="{toxworkdir}/mypyc_cache" \
|
|
--config-file="{toxinidir}/pyproject.toml" \
|
|
{tty:--pretty:} \
|
|
{posargs:src}
|
|
- pytype -d import-error --keep-going --jobs auto {posargs:src}
|
|
- pyre --noninteractive analyze
|
|
- pyright {posargs:src}
|
|
basepython = python3.10
|
|
|
|
[testenv:coverage-report]
|
|
deps = coverage
|
|
skip_install = true
|
|
commands =
|
|
coverage combine
|
|
coverage report
|
|
|
|
[coverage:run]
|
|
relative_files = True
|
|
source = src/
|
|
branch = True
|