Skip to content

Commit 8784a78

Browse files
Remove mypy overrides for tests/test_util/test_util_docutils.py (sphinx-doc#13770)
1 parent 087d77c commit 8784a78

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

pyproject.toml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -280,8 +280,6 @@ module = [
280280
"tests.test_theming.test_theming",
281281
# tests/test_transforms
282282
"tests.test_transforms.test_transforms_post_transforms_images",
283-
# tests/test_util
284-
"tests.test_util.test_util_docutils",
285283
# tests/test_writers
286284
"tests.test_writers.test_docutilsconf",
287285
]

tests/test_util/test_util_docutils.py

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@
1717
)
1818

1919
if TYPE_CHECKING:
20+
from pathlib import Path
21+
2022
from sphinx.builders import Builder
2123
from sphinx.testing.util import SphinxTestApp
2224

@@ -41,7 +43,7 @@ class custom_node(nodes.Element):
4143
assert not hasattr(nodes.SparseNodeVisitor, 'depart_custom_node')
4244

4345

44-
def test_SphinxFileOutput(tmp_path):
46+
def test_SphinxFileOutput(tmp_path: Path) -> None:
4547
content = 'Hello Sphinx World'
4648

4749
# write test.txt at first
@@ -79,16 +81,16 @@ def __init__(self, document: nodes.document, builder: Builder):
7981
self.called: list[str] = []
8082
super().__init__(document, builder)
8183

82-
def visit_document(self, node):
84+
def visit_document(self, node: nodes.document) -> None:
8385
pass
8486

85-
def depart_document(self, node):
87+
def depart_document(self, node: nodes.document) -> None:
8688
pass
8789

88-
def visit_inline(self, node):
90+
def visit_inline(self, node: nodes.inline) -> None:
8991
self.called.append('visit_inline')
9092

91-
def depart_inline(self, node):
93+
def depart_inline(self, node: nodes.inline) -> None:
9294
self.called.append('depart_inline')
9395

9496
document = new_document('')

0 commit comments

Comments
 (0)