Skip to content

Commit 492c9f0

Browse files
committed
test: Refactor parameter names in added docstring tests
1 parent a6edf27 commit 492c9f0

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

tests/test_docstrings/test_sphinx.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -245,8 +245,8 @@ def test_parse__param_field_type_field__param_section_with_type(parse_sphinx: Pa
245245
docstring = f"""
246246
Docstring with line continuation.
247247
248-
:param foo: {SOME_TEXT}
249-
:type foo: {type_}
248+
:param {SOME_NAME}: {SOME_TEXT}
249+
:type {SOME_NAME}: {type_}
250250
"""
251251

252252
sections, _ = parse_sphinx(docstring)
@@ -272,8 +272,8 @@ def test_parse__param_field_type_field__param_section_with_type_with_parent(
272272
docstring = f"""
273273
Docstring with line continuation.
274274
275-
:param foo: {SOME_TEXT}
276-
:type foo: {type_}
275+
:param {SOME_NAME}: {SOME_TEXT}
276+
:type {SOME_NAME}: {type_}
277277
"""
278278
parent_fn = Function("func", parameters=Parameters(Parameter("foo")))
279279
sections, _ = parse_sphinx(docstring, parent=parent_fn)
@@ -321,8 +321,8 @@ def test_parse__param_field_type_field_first__param_section_with_type_with_paren
321321
docstring = f"""
322322
Docstring with line continuation.
323323
324-
:type foo: str
325-
:param foo: {SOME_TEXT}
324+
:type {SOME_NAME}: str
325+
:param {SOME_NAME}: {SOME_TEXT}
326326
"""
327327
parent_fn = Function("func", parameters=Parameters(Parameter("foo")))
328328
sections, _ = parse_sphinx(docstring, parent=parent_fn)
@@ -390,8 +390,8 @@ def test_parse__param_field_type_field_or_none__param_section_with_optional_with
390390
docstring = f"""
391391
Docstring with line continuation.
392392
393-
:param foo: {SOME_TEXT}
394-
:type foo: {union}
393+
:param {SOME_NAME}: {SOME_TEXT}
394+
:type {SOME_NAME}: {union}
395395
"""
396396

397397
parent_fn = Function("func", parameters=Parameters(Parameter("foo")))

0 commit comments

Comments
 (0)