# config file for tox [tox] envlist = py3{7,8,9,10,11,12,13},ruff,mypy,cformat,docs requires = # this is needed for compatibility with Python 3.7 pip<24.1 virtualenv<20.27 [testenv:ruff] basepython = python3.13 deps = ruff>=0.8,<0.9 commands = ruff check setup.py pg pgdb tests [testenv:mypy] basepython = python3.13 deps = mypy>=1.13,<1.14 commands = mypy pg pgdb tests [testenv:cformat] basepython = python3.13 allowlist_externals = sh commands = sh -c "! (clang-format --style=file -n ext/*.c 2>&1 | tee /dev/tty | grep format-violations)" [testenv:docs] basepython = python3.13 deps = sphinx>=8,<9 commands = sphinx-build -b html -nEW docs docs/_build/html [testenv:build] basepython = python3.13 deps = setuptools>=68 wheel>=0.42,<1 build>=1,<2 commands = python -m build -s -n -C strict -C memory-size [testenv:coverage] basepython = python3.13 deps = coverage>=7,<8 commands = coverage run -m unittest discover -v coverage html [testenv] passenv = PG* PYGRESQL_* deps = setuptools>=68 commands = python setup.py clean --all build_ext --force --inplace --strict --memory-size python -m unittest {posargs:discover -v}