Migrate isort, mypy, and pytest config into pyproject.toml

This commit is contained in:
Christian Clauss
2022-09-16 18:26:55 +02:00
parent 62b57b9d19
commit 8043eca304
2 changed files with 47 additions and 43 deletions
+46
View File
@@ -29,6 +29,52 @@ exclude = '''
)
'''
[tool.isort]
atomic = true
lines_after_imports = 2
lines_between_types = 1
multi_line_output = 5
line_length = 80
known_first_party = [
"pipenv",
"tests",
]
[tool.mypy]
ignore_missing_imports = true
follow_imports = "skip"
html_report = "mypyhtml"
python_version = "3.7"
mypy_path = "typeshed/pyi:typeshed/imports"
[tool.pytest.ini_options]
addopts = "-ra"
plugins = "xdist"
testpaths = ["tests"]
# Add vendor and patched in addition to the default list of ignored dirs
# Additionally, ignore tasks, news, test subdirectories and peeps directory
norecursedirs = [
".*", "build",
"dist",
"CVS",
"_darcs",
"{arch}",
"*.egg",
"vendor",
"patched",
"news",
"tasks",
"docs",
"tests/test_artifacts",
"tests/pytest-pypi",
"tests/pypi",
"peeps",
]
filterwarnings = [
"ignore::DeprecationWarning",
"ignore::PendingDeprecationWarning",
]
[tool.towncrier]
package = "pipenv"
filename = "CHANGELOG.rst"
+1 -43
View File
@@ -3,6 +3,7 @@ long_description = file: README.md
license = MIT
license_files = LICENSE
# Currently flake8 does not support pyproject.toml
[flake8]
extend-exclude =
docs/,
@@ -26,49 +27,6 @@ ignore =
# W503: line break before binary operator
E402,E501,W503,E203
[isort]
atomic=true
lines_after_imports=2
lines_between_types=1
multi_line_output=5
line_length=80
known_first_party =
pipenv
tests
[mypy]
ignore_missing_imports=true
follow_imports=skip
html_report=mypyhtml
python_version=3.7
mypy_path=typeshed/pyi:typeshed/imports
[tool:pytest]
addopts = -ra
plugins = xdist
testpaths = tests
; Add vendor and patched in addition to the default list of ignored dirs
; Additionally, ignore tasks, news, test subdirectories and peeps directory
norecursedirs =
.* build
dist
CVS
_darcs
{arch}
*.egg
vendor
patched
news
tasks
docs
tests/test_artifacts
tests/pytest-pypi
tests/pypi
peeps
filterwarnings =
ignore::DeprecationWarning
ignore::PendingDeprecationWarning
[coverage:run]
parallel = true