diff --git a/pyproject.toml b/pyproject.toml index 32fb0dd..a787384 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,5 +1,5 @@ [build-system] -requires = ["setuptools>=38.3.0", "wheel"] +requires = ["setuptools>=64.0.0"] build-backend = "setuptools.build_meta" [project] @@ -75,6 +75,23 @@ extend-exclude = ''' )/ ''' +# coverage configuration +[tool.coverage.run] +branch = true +relative_files = true +parallel = true +source = [ + "tests", + "wrapt", +] + +[tool.coverage.paths] +src = [ + "src/", + ".tox/*/lib/*/site-packages/", + ".tox/pypy*/site-packages/", +] + # pytest configuration [tool.pytest.ini_options] testpaths = ["tests"] diff --git a/setup.cfg b/setup.cfg deleted file mode 100644 index 62ec0f8..0000000 --- a/setup.cfg +++ /dev/null @@ -1,96 +0,0 @@ -# --- Project configuration ------------------------------------------------- - -[metadata] -name = wrapt -version = attr: wrapt.__version__ -readme = "RELEASE.rst" -author = Graham Dumpleton -author_email = Graham.Dumpleton@gmail.com -url = https://github.com/GrahamDumpleton/wrapt -description = Module for decorators, wrappers and monkey patching. -long_description = file: RELEASE.rst -long_description_content_type = text/x-rst -platform = any -keywords = wrapper, proxy, decorator -classifiers = - Development Status :: 5 - Production/Stable - Programming Language :: Python :: 3 - Programming Language :: Python :: 3.9 - Programming Language :: Python :: 3.10 - Programming Language :: Python :: 3.11 - Programming Language :: Python :: 3.12 - Programming Language :: Python :: 3.13 - Programming Language :: Python :: 3.14 - Programming Language :: Python :: Implementation :: CPython - Programming Language :: Python :: Implementation :: PyPy -project_urls = - Bug Tracker = https://github.com/GrahamDumpleton/wrapt/issues/ - Changelog = https://wrapt.readthedocs.io/en/latest/changes.html - Documentation = https://wrapt.readthedocs.io/ - -[options] -zip_safe = false -python_requires = >= 3.9 -packages = find: -package_dir = - =src -test_suite = tests - -[options.packages.find] -where=src - -[bdist_wheel] -universal = false - -# --- Test and coverage configuration ------------------------------------------ - -[coverage:run] -branch = true -relative_files = true -parallel = true -source = - tests - wrapt - -[coverage:paths] -src = - src/ - .tox/*/lib/*/site-packages/ - .tox/pypy*/site-packages/ - -[tool:pytest] -testpaths = ["tests"] -addopts = ["-v"] -norecursedirs = [".tox", ".venv", "venv", "build", "dist"] - -# --- Tox automation configuration --------------------------------------------- - -[tox:tox] -envlist = - py{39,310,311,312,313,314} - py{39,310,311,312,313,314}-{without,install,disable}-extensions, - pypy-without-extensions - -[gh-actions] -python = - 3.9: py39, py39-without-extensions, py39-install-extensions, py39-disable-extensions - 3.10: py310, py310-without-extensions, py310-install-extensions, py310-disable-extensions - 3.11: py311, py311-without-extensions, py311-install-extensions, py311-disable-extensions - 3.12: py312, py312-without-extensions, py312-install-extensions, py312-disable-extensions - 3.13: py313, py313-without-extensions, py313-install-extensions, py313-disable-extensions - 3.14: py314, py314-without-extensions, py314-install-extensions, py314-disable-extensions - pypy-3.9: pypy-without-extensions - pypy-3.10: pypy-without-extensions - -[testenv] -deps = - coverage - pytest -install_command = - python -m pip install --no-binary coverage {opts} {packages} -commands = - python -m coverage run --rcfile {toxinidir}/setup.cfg -m pytest -v {posargs} {toxinidir}/tests -setenv = - without-extensions: WRAPT_INSTALL_EXTENSIONS = false - install-extensions,disable-extensions: WRAPT_INSTALL_EXTENSIONS = true - disable-extensions: WRAPT_DISABLE_EXTENSIONS = true diff --git a/tox.ini b/tox.ini new file mode 100644 index 0000000..33df451 --- /dev/null +++ b/tox.ini @@ -0,0 +1,28 @@ +[tox] +envlist = + py{39,310,311,312,313,314} + py{39,310,311,312,313,314}-{without,install,disable}-extensions, + pypy-without-extensions + +[testenv] +deps = + coverage + pytest +install_command = python -m pip install --no-binary coverage {opts} {packages} +setenv = + without-extensions: WRAPT_INSTALL_EXTENSIONS = false + install-extensions,disable-extensions: WRAPT_INSTALL_EXTENSIONS = true + disable-extensions: WRAPT_DISABLE_EXTENSIONS = true +commands = + python -m coverage run --rcfile {toxinidir}/pyproject.toml -m pytest -v {posargs} {toxinidir}/tests + +[gh-actions] +python = + 3.9: py39, py39-without-extensions, py39-install-extensions, py39-disable-extensions + 3.10: py310, py310-without-extensions, py310-install-extensions, py310-disable-extensions + 3.11: py311, py311-without-extensions, py311-install-extensions, py311-disable-extensions + 3.12: py312, py312-without-extensions, py312-install-extensions, py312-disable-extensions + 3.13: py313, py313-without-extensions, py313-install-extensions, py313-disable-extensions + 3.14: py314, py314-without-extensions, py314-install-extensions, py314-disable-extensions + pypy-3.9: pypy-without-extensions + pypy-3.10: pypy-without-extensions