Skip to content

Commit

Permalink
Migrated to native TOML configuration for Tox
Browse files Browse the repository at this point in the history
(cherry picked from commit 0614b4f)
  • Loading branch information
agronholm committed Oct 13, 2024
1 parent 6bebf18 commit 4cb89a5
Showing 1 changed file with 23 additions and 30 deletions.
53 changes: 23 additions & 30 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -126,34 +126,27 @@ relative_files = true
show_missing = true

[tool.tox]
legacy_tox_ini = """
[tox]
envlist = pre-commit, py38, py39, py310, py311, py312, py313, pypy3
env_list = ["pre-commit", "py38", "py39", "py310", "py311", "py312", "py313", "pypy3"]
skip_missing_interpreters = true
minversion = 4.0.0
[testenv]
depends = pre-commit
package = editable
commands = coverage run -m pytest {posargs}
extras = test
[testenv:pypy3]
commands = pytest {posargs}
[testenv:pre-commit]
depends =
basepython = python3
package = skip
deps = pre-commit
commands = pre-commit run --all-files
[testenv:pyright]
deps = pyright
commands = pyright --verifytypes anyio
[testenv:docs]
depends =
extras = doc
commands = sphinx-build -W docs build/sphinx
"""

[tool.tox.env_run_base]
depends = ["pre-commit"]
package = "editable"
commands = [["coverage", "run", "-m", "pytest", { replace = "posargs", extend = true }]]
extras = ["test"]

[tool.tox.env.pypy3]
commands = [["pytest", { replace = "posargs", extend = true }]]

[tool.tox.env.pre-commit]
commands = [["pre-commit", "run", "--all-files"]]
package = "skip"

[tool.tox.env.pyright]
deps = ["pyright"]
commands = [["pyright", "--verifytypes", "anyio"]]

[tool.tox.env.docs]
depends = []
extras = ["doc"]
commands = [["sphinx-build", "-W", "docs", "build/sphinx"]]

0 comments on commit 4cb89a5

Please sign in to comment.