Skip to content

Commit ff8ba58

Browse files
committed
lint: add type annotation
Signed-off-by: Mike Fiedler <[email protected]>
1 parent ba04e22 commit ff8ba58

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

tests/test_numfig_only.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,16 @@
11
"""Test numfig with only directive."""
22

33
from __future__ import annotations
4+
from typing import TYPE_CHECKING
45

56
import pytest
67

8+
if TYPE_CHECKING:
9+
from sphinx.testing.util import SphinxTestApp
10+
711

812
@pytest.mark.sphinx('html', testroot='numfig-only', confoverrides={'numfig': True})
9-
def test_numfig_with_only_directive_html(app, status, warning):
13+
def test_numfig_with_only_directive_html(app: SphinxTestApp) -> None:
1014
"""Test that figure numbers are assigned correctly with only directive in HTML."""
1115
app.build()
1216

@@ -24,7 +28,7 @@ def test_numfig_with_only_directive_html(app, status, warning):
2428

2529

2630
@pytest.mark.sphinx('latex', testroot='numfig-only', confoverrides={'numfig': True})
27-
def test_numfig_with_only_directive_latex(app, status, warning):
31+
def test_numfig_with_only_directive_latex(app: SphinxTestApp) -> None:
2832
"""Test that figure numbers are assigned correctly with only directive in LaTeX.
2933
3034
Note: This test verifies that figure numbering works correctly with the only directive.

0 commit comments

Comments
 (0)