-
Notifications
You must be signed in to change notification settings - Fork 15
/
Copy pathpyproject.toml
124 lines (111 loc) · 3.09 KB
/
pyproject.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[tool.hatch.build.targets.sdist]
# limit which files are included in the sdist (.tar.gz) asset,
# see https://github.com/pydantic/pydantic/pull/4542
include = ["/README.md", "/Makefile", "/pytest_examples", "/tests"]
[project]
name = "pytest-examples"
version = "0.0.15"
description = "Pytest plugin for testing examples in docstrings and markdown files."
authors = [
]
license = "MIT"
readme = "README.md"
classifiers = [
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: Python :: 3.8",
"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",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Operating System :: Unix",
"Operating System :: POSIX :: Linux",
"Environment :: Console",
"Environment :: MacOS X",
"Framework :: Pytest",
"Topic :: Software Development :: Libraries :: Python Modules",
]
requires-python = ">=3.8"
dependencies = [
"pytest>=7",
"black>=23",
"ruff>=0.5.0",
]
[project.entry-points.pytest11]
examples = "pytest_examples"
[project.urls]
repository = "https://github.com/pydantic/pytest-examples"
[dependency-groups]
dev = [
"coverage[toml]>=7.6.1",
"pytest-pretty>=1.2.0",
]
lint = [
"pre-commit>=3.5.0",
"pyright>=1.1.389",
"ruff>=0.7.4",
]
[tool.pytest.ini_options]
testpaths = ["tests", "example"]
filterwarnings = "error"
xfail_strict = true
[tool.ruff]
line-length = 120
target-version = "py39"
include = [
"pytest_examples/**/*.py",
"tests/**/*.py",
"examples/**/*.py",
]
exclude = ["tests/cases_update/*.py"]
[tool.ruff.lint]
extend-select = [
"Q",
"RUF100",
"C90",
"UP",
"I",
"D",
]
flake8-quotes = { inline-quotes = "single", multiline-quotes = "double" }
isort = { combine-as-imports = true, known-first-party = ["pytest_examples"] }
mccabe = { max-complexity = 15 }
ignore = [
"D100", # ignore missing docstring in module
"D101", # ignore missing docstring in public class
"D102", # ignore missing docstring in public method
"D103", # ignore missing docstring in public function
"D104", # ignore missing docstring in public package
"D105", # ignore missing docstring in magic methods
"D107", # ignore missing docstring in __init__ methods
]
[tool.ruff.lint.pydocstyle]
convention = "google"
[tool.ruff.format]
docstring-code-format = true
quote-style = "single"
[tool.coverage.run]
source = ["pytest_examples"]
branch = true
[tool.coverage.report]
precision = 2
exclude_lines = [
"pragma: no cover",
"raise NotImplementedError",
"if TYPE_CHECKING:",
"@overload",
]
[tool.pyright]
#typeCheckingMode = "strict"
reportUnnecessaryTypeIgnoreComment = true
reportMissingTypeStubs = false
include = ["pytest_examples"]
venvPath = ".venv"