diff --git a/.flake8 b/.flake8 new file mode 100644 index 00000000..98825526 --- /dev/null +++ b/.flake8 @@ -0,0 +1,6 @@ +[flake8] +max-line-length = 120 +ignore = W503,W504 + +[pycodestyle] +max_line_length = 120 diff --git a/MANIFEST.in b/MANIFEST.in index f8d43152..5eec5f6a 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -1,4 +1,3 @@ -include LICENSE include README.rst include CHANGES.md include tox.ini diff --git a/pyproject.toml b/pyproject.toml index 590e0b11..18ba6e4a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,5 +1,89 @@ [build-system] -requires = ["setuptools>=30.3.0", - "setuptools_scm", - "wheel"] -build-backend = 'setuptools.build_meta' +requires = [ + "setuptools>=80", + "setuptools-scm[simple]>=8", +] +build-backend = "setuptools.build_meta" + +[project] +name = "pytest-mpl" +authors = [ + { name = "Thomas Robitaille", email = "thomas.robitaille@gmail.com" }, +] +license = "BSD-2-Clause" +license-files = [ + "LICENSE", +] +classifiers = [ + "Development Status :: 5 - Production/Stable", + "Framework :: Pytest", + "Intended Audience :: Developers", + "Topic :: Software Development :: Testing", + "Topic :: Scientific/Engineering :: Visualization", + "Programming Language :: Python", + "Programming Language :: Python :: 3", + "Operating System :: OS Independent", +] +description = "pytest plugin to help with testing figures output from Matplotlib" +requires-python = ">=3.9" +dependencies = [ + "pytest>=5.4.0", + "matplotlib>=3.3.3", + "packaging>=22.0.0", + "Jinja2>=2.10.2", + "Pillow>=8.1.1", +] +dynamic = [ + "version", +] + +[project.readme] +file = "README.rst" +content-type = "text/x-rst" + +[project.urls] +Homepage = "https://github.com/matplotlib/pytest-mpl" + +[project.entry-points.pytest11] +pytest_mpl = "pytest_mpl.plugin" + +[project.optional-dependencies] +test = [ + "pytest-cov>=6.0.0", +] +docs = [ + "sphinx>=7.0.0", + "mpl_sphinx_theme>=3.9.0", + "sphinx_design>=0.6.0", + "matplotlib==3.9.*", +] + +[tool.setuptools] +zip-safe = true +include-package-data = true + +[tool.setuptools.packages.find] +namespaces = false + +[tool.pytest.ini_options] +testpaths = [ + "tests", +] +norecursedirs = [ + "tests/subtests/subtest", +] +filterwarnings = [ + "error", + "ignore:distutils Version classes are deprecated", + "ignore:the imp module is deprecated in favour of importlib", + "ignore:The NumPy module was reloaded", +] + +[tool.isort] +balanced_wrapping = true +length_sort = false +length_sort_sections = [ + "stdlib", +] +line_length = 100 + diff --git a/setup.cfg b/setup.cfg deleted file mode 100644 index 2d6642e3..00000000 --- a/setup.cfg +++ /dev/null @@ -1,68 +0,0 @@ -[metadata] -license_file = LICENSE -name = pytest-mpl -url = https://github.com/matplotlib/pytest-mpl -author = Thomas Robitaille -author_email = thomas.robitaille@gmail.com -classifiers = - Development Status :: 4 - Beta - Framework :: Pytest - Intended Audience :: Developers - Topic :: Software Development :: Testing - Topic :: Scientific/Engineering :: Visualization - Programming Language :: Python - Programming Language :: Python :: 3 - Operating System :: OS Independent - License :: OSI Approved :: BSD License -license = BSD -description = pytest plugin to help with testing figures output from Matplotlib -long_description = file: README.rst -long_description_content_type = text/x-rst - -[options] -zip_safe = True -packages = find: -include_package_data = True -python_requires = >=3.9 -install_requires = - pytest - matplotlib - importlib_resources;python_version<'3.8' - packaging - Jinja2 - Pillow - -[options.entry_points] -pytest11 = - pytest_mpl = pytest_mpl.plugin - -[options.extras_require] -test = - pytest-cov -docs = - sphinx - mpl_sphinx_theme>=3.9.0 - sphinx_design - matplotlib==3.9.* - -[tool:pytest] -testpaths = tests -norecursedirs = tests/subtests/subtest -filterwarnings = - error - ignore:distutils Version classes are deprecated - ignore:the imp module is deprecated in favour of importlib - ignore:The NumPy module was reloaded - -[flake8] -max-line-length = 120 -ignore = W503,W504 - -[pycodestyle] -max_line_length = 120 - -[isort] -balanced_wrapping = True -length_sort = False -length_sort_sections = stdlib -line_length = 100 diff --git a/setup.py b/setup.py deleted file mode 100644 index 92354ee1..00000000 --- a/setup.py +++ /dev/null @@ -1,5 +0,0 @@ -#!/usr/bin/env python - -from setuptools import setup - -setup(use_scm_version=True)