forked from elchupanebrej/pytest-bdd-ng
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
331 lines (317 loc) · 10.4 KB
/
pyproject.toml
File metadata and controls
331 lines (317 loc) · 10.4 KB
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
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
[build-system]
build-backend = "setuptools.build_meta"
requires = ["setuptools", "wheel"]
[project]
authors = [
{name = "Oleg Pidsadnyi", email = "oleg.pidsadnyi@gmail.com"},
{name = "Anatoly Bubenkov", email = "bubenkoff@gmail.com"},
{name = "Adam Coddington", email = "me@adamcoddington.net"},
{name = "Albert-Jan Nijburg", email = "albertjan@curit.com"},
{name = "Alessio Bogon", email = "youtux@gmail.com"},
{name = "Andrey Makhnach", email = "andrey.makhnach@gmail.com"},
{name = "Aron Curzon", email = "curzona@gmail.com"},
{name = "Dmitrijs Milajevs", email = "dimazest@gmail.com"},
{name = "Dmitry Kolyagin", email = "pauk-slon@users.noreply.github.com"},
{name = "Florian Bruhin", email = "me@the-compiler.org"},
{name = "Floris Bruynooghe", email = "flub@devork.be"},
{name = "Harro van der Klauw", email = "hvdklauw@gmail.com"},
{name = "Hugo van Kemenade", email = "hugovk@users.noreply.github.com"},
{name = "Konstantin Goloveshko", email = "kostya.goloveshko@gmail.com"},
{name = "Laurence Rowe", email = "l@lrowe.co.uk"},
{name = "Leonardo Santagada", email = "santagada@github.com"},
{name = "Milosz Sliwinski", email = "sliwinski.milosz@gmail.com"},
{name = "Michiel Holtkamp", email = "github@elfstone.nl"},
{name = "Robin Pedersen", email = "ropez@github.com"},
{name = "Sergey Kraynev", email = "sergejyit@gmail.com"}
]
classifiers = [
"Development Status :: 4 - Beta",
"Framework :: Pytest",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Operating System :: POSIX",
"Operating System :: Microsoft :: Windows",
"Operating System :: MacOS :: MacOS X",
"Topic :: Software Development :: Testing",
"Topic :: Software Development :: Libraries",
"Topic :: Utilities",
"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"
]
dependencies = [
"aiohttp",
"attrs",
"certifi",
"chevron",
"ci-environment",
"cucumber-expressions",
"cucumber-messages",
"cucumber-tag-expressions",
"decopatch",
"docopt-ng",
"filelock",
"gherkin-official>=33",
"importlib-metadata;python_version<'3.10.0'",
"importlib-resources",
"makefun",
"Mako",
"ordered_set",
"packaging",
"parse",
"parse_type>=0.6.0",
"pathvalidate",
"py",
"pydantic>=2.0.3",
"pytest>=6.0",
"StrEnum;python_version<'3.11.0'",
"typing-extensions;python_version<'3.11.0'"
]
description = "BDD for pytest"
license = {file = "LICENSE.rst"}
maintainers = [
{name = "Konstantin Goloveshko", email = "kostya.goloveshko@gmail.com"}
]
name = "pytest-bdd-ng"
readme = {file = "README.rst", content-type = "text/x-rst"}
requires-python = ">=3.9"
version = "2.3.1"
[project.entry-points.pytest11]
"pytest-bdd-allure-logger" = "pytest_bdd.plugin.allure_logger.entrypoint"
"pytest-bdd-code-generator" = "pytest_bdd.plugin.code_generator.entrypoint"
"pytest-bdd-cucumber-json" = "pytest_bdd.plugin.cucumber_json.entrypoint"
"pytest-bdd-gherkin-message-reporter" = "pytest_bdd.plugin.gherkin_message_reporter.entrypoint"
"pytest-bdd-gherkin-scenario-reporter" = "pytest_bdd.plugin.scenario_reporter.entrypoint"
"pytest-bdd-gherkin-terminal-reporter" = "pytest_bdd.plugin.gherkin_terminal_reporter.entrypoint"
"pytest-bdd-scenario-runner" = "pytest_bdd.plugin.scenario_runner.entrypoint"
"pytest-bdd-scenario-test-collector" = "pytest_bdd.plugin.scenario_test_collector.entrypoint"
"pytest-bdd-struct-bdd" = "pytest_bdd.plugin.struct_bdd.entrypoint"
[project.optional-dependencies]
allure = [
"allure-python-commons",
"allure-pytest"
]
doc-gen = [
'docopt-ng',
'pandoc',
'panflute',
'pathlib2',
'pypandoc'
]
full = [
"pytest-bdd-ng[allure]",
"pytest-bdd-ng[doc-gen]",
"pytest-bdd-ng[struct-bdd]",
"pytest-bdd-ng[test]",
"pytest-bdd-ng[testtypes]"
]
struct-bdd = [
"hjson",
"json5",
"pyhocon",
'tomli;python_version<"3.11.0"',
"PyYAML",
"types-PyYAML"
]
test = [
"allure-python-commons-test",
"execnet",
"packaging",
"PyHamcrest",
"pytest-httpserver",
"python-coveralls",
"pytest-bdd-ng[doc-gen];python_version>='3.13.0'",
"ruff"
]
testenv = [
"tox~=4.0",
"codecov"
]
testtypes = [
"mypy",
"types-certifi",
"types-chevron",
"types-docopt",
"types-pathlib2",
"types-setuptools"
]
[project.scripts]
bdd_tree_to_rst = "pytest_bdd.script.bdd_tree_to_rst:main"
[project.urls]
Documentation = "https://pytest-bdd-ng.readthedocs.io/en/default/"
Repository = "https://github.com/elchupanebrej/pytest-bdd-ng"
[tool.mypy]
files = "src/pytest_bdd/**/*.py"
install_types = true
non_interactive = true
plugins = [
"pydantic.mypy"
]
show_error_codes = true
warn_return_any = true
warn_unused_configs = true
[[tool.mypy.overrides]]
ignore_missing_imports = true
module = [
"allure_commons.*",
"allure_pytest.*",
"attr.*",
"ci_environment.*",
"cucumber_expressions.*",
"cucumber_tag_expressions.*",
"decopatch.*",
"execnet.*",
"gherkin.*",
"hjson",
"json5",
"makefun",
"mako.*",
"ordered_set",
"parse",
"parse_type.*",
"pluggy.*",
"_pytest.*",
"pyhocon",
"pytest.*",
"yaml.*"
]
[tool.ruff]
# Exclude a variety of commonly ignored directories.
exclude = [
".eggs",
".git",
".git-rewrite",
".mypy_cache",
".ruff_cache",
".tox",
".venv",
"__pypackages__",
"build",
"dist",
"venv"
]
# Same as Black.
line-length = 120
# Assume Python 3.9+
target-version = "py39"
[tool.ruff.format]
# Like Black, indent with spaces, rather than tabs.
indent-style = "space"
# Like Black, automatically detect the appropriate line ending.
line-ending = "auto"
# Like Black, use double quotes for strings.
quote-style = "double"
# Like Black, respect magic trailing commas.
skip-magic-trailing-comma = false
[tool.ruff.lint]
# Allow unused variables when underscore-prefixed.
dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$"
# Allow fix for all enabled rules (when `--fix`) is provided.
fixable = ["ALL"]
ignore = [
# Linter-Formatter interference
"W191", # tab-indentation
"E111", # indentation-with-invalid-multiple
"E114", # indentation-with-invalid-multiple-comment
"E117", # over-indented
"D206", # docstring-tab-indentation
"D300", # triple-single-quotes
"Q000", # bad-quotes-inline-string
"Q001", # bad-quotes-multiline-string
"Q002", # bad-quotes-docstring
"Q003", # avoidable-escaped-quote
"COM812", # missing-trailing-comma
"COM819", # prohibited-trailing-comma
"ISC002", # multi-line-implicit-string-concatenation
"E501", # line too long, handled by formatter
# / Linter-Formatter interference
"TC006", # https://youtrack.jetbrains.com/issue/PY-46326/Pycharm-does-not-recognize-imports-used-for-typing.cast-when-they-are-incased-in-a-string-and-removing-them-when-optimizing]
"CPY001" # flake8-copyright: Copyright headers
]
preview = true
select = [
"A", # flake8-builtins: Built-in names shadowed
# TODO "ANN", # flake8-annotations: Annotations
"ARG", # flake8-unused-arguments: Unused function arguments
"ASYNC", # flake8-async: Asyncio
"B", # flake8-bugbear: Likely bugs and design problems
"BLE", # blind-except: Blind excepts
"C4", # flake8-comprehensions: Comprehension optimizations
"C90", # flake8-c90: C90 style issues
"COM", # flake8-commas: Comma issues
"CPY", # flake8-copyright: Copyright headers
# TODO "D", # pydocstyle: Docstring conventions
"DTZ", # flake8-datetimez: Datetime issues
# TODO "DOC", # pydoclint: Docstring linting
"E", # pycodestyle errors: Style guide enforcement
"EXE", # flake8-executable: Executable scripts
"EM", # flake8-errmsg: Error message consistency
"ERA", # eradicate: Remove commented-out code
"F", # Pyflakes: Logical errors, undefined names
"FA", # flake8-future-annotations: Future annotations
"FBT", # flake8-boolean-trap: Boolean trap
# TODO "FIX", # flake8-fixme: Fixme comments
"FLY", # flynt: String formatting modernization
"FURB", # refurb: Code modernization
"G", # flake8-logging-format: Logging format issues
"I", # isort: Import sorting
"ICN", # flake8-import-conventions: Import conventions
"INT", # flake8-gettext: Gettext usage
"INP", # flake8-no-pep420: PEP 420 namespace packages
"ISC", # flake8-implicit-str-concat: Implicit string concatenation
"LOG", # flake8-logging: Logging issues
"N", # pep8-naming: Naming conventions
"PERF", # perflint: Performance issues
"PGH", # pygrep-hooks: Pre-commit hooks
"PIE", # flake8-pie: Miscellaneous checks
# TODO "PL", # pylint: Linting
"PT", # flake8-pytest-style: Pytest style
"PTH", # flake8-use-pathlib: Use pathlib
"PYI", # flake8-pyi: Pyi file checks
"RET", # flake8-return: Return statement checks
"RSE", # flake8-raise: Raise statement checks
"RUF", # ruff: Ruff-specific checks
"S", # bandit: Security issues
"SIM", # flake8-simplify: Simplifiable code
# TODO "SLF", # flake8-self: Private member access
"SLOT", # flake8-slots: Slots usage
"T10", # flake8-debugger: Debugger usage
"T20", # flake8-print: Print statement usage
"TC", # flake8-type-checking: Type checking
# TODO "TD", # flake8-todos: TODO comments
"TID", # flake8-tidy-imports: Import restrictions
"TRY", # tryceratops: Try/except issues
"YTT", # flake8-2020: Outdated sys.version checks
"W", # pycodestyle warnings: Style guide warnings
"UP", # pyupgrade: Modernize syntax for newer Python versions
"Q" # flake8-quotes: String quote consistency
]
unfixable = []
[tool.ruff.lint.isort]
# Like isort, sort imports using a single line after the import block.
force-single-line = false
# Like isort, separate sections with a blank line.
section-order = [
"future",
"standard-library",
"third-party",
"first-party",
"local-folder"
]
[tool.ruff.lint.mccabe]
# Flag errors (`C901`) whenever the complexity level exceeds.
max-complexity = 10 # TODO target is 6
[tool.ruff.lint.per-file-ignores]
"__init__.py" = ["F401"]
"docs/conf.py" = ["ERA001"]
"docs/tutorial/tests/*" = ["S101", "S506"]
"src/pytest_bdd/compatibility/allure.py" = ["ERA001"] # TODO re-implement Allure plugin
"src/pytest_bdd/plugin/allure_logger/entrypoint.py" = ["ERA001"] # TODO re-implement Allure plugin
"src/pytest_bdd/util/toolz_test.py" = ["S301"]
"tests/*" = ["D103", "EM101", "PLR0913", "PLR0914", "PLR0915", "PLR0917", "S101", "S506"]
[tool.ruff.lint.pyupgrade]
# Preserve types, even if a file imports `from __future__ import annotations`.
keep-runtime-typing = true