Skip to content

Commit ba27f9e

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent 344a723 commit ba27f9e

File tree

1 file changed

+16
-3
lines changed

1 file changed

+16
-3
lines changed

src/_pytest/config/argparsing.py

Lines changed: 16 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ def addini(
192192
* ``paths``: a list of :class:`pathlib.Path`, separated as in a shell
193193
* ``pathlist``: a list of ``py.path``, separated as in a shell
194194
* ``int``: an integer
195-
* ``float``: a floating-point number
195+
* ``float``: a floating-point number
196196
197197
For ``paths`` and ``pathlist`` types, they are considered relative to the ini-file.
198198
In case the execution is happening without an ini-file defined,
@@ -211,7 +211,17 @@ def addini(
211211
The value of ini-variables can be retrieved via a call to
212212
:py:func:`config.getini(name) <pytest.Config.getini>`.
213213
"""
214-
assert type in (None, "string", "paths", "pathlist", "args", "linelist", "bool", "int", "float")
214+
assert type in (
215+
None,
216+
"string",
217+
"paths",
218+
"pathlist",
219+
"args",
220+
"linelist",
221+
"bool",
222+
"int",
223+
"float",
224+
)
215225
if default is NOT_SET:
216226
default = get_ini_default_for_type(type)
217227

@@ -220,7 +230,10 @@ def addini(
220230

221231

222232
def get_ini_default_for_type(
223-
type: Literal["string", "paths", "pathlist", "args", "linelist", "bool", "int", "float"] | None,
233+
type: Literal[
234+
"string", "paths", "pathlist", "args", "linelist", "bool", "int", "float"
235+
]
236+
| None,
224237
) -> Any:
225238
"""
226239
Used by addini to get the default value for a given ini-option type, when

0 commit comments

Comments
 (0)