Skip to content

Commit 6372f01

Browse files
committed
Update coverage ignores.
1 parent 8103ecf commit 6372f01

File tree

5 files changed

+13
-9
lines changed

5 files changed

+13
-9
lines changed

domdf_python_tools/compat.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,9 @@
3737

3838
__all__ = ["importlib_resources"]
3939

40-
if sys.version_info < (3, 7):
40+
if sys.version_info < (3, 7): # pragma: no cover (>=py37)
4141
# 3rd party
4242
import importlib_resources
43-
else:
43+
else: # pragma: no cover (<py37)
4444
# stdlib
4545
import importlib.resources as importlib_resources

domdf_python_tools/import_tools.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ def discover(
6262
match_func: Optional[Callable[[Any], bool]] = ...,
6363
exclude_side_effects: Literal[True] = ...,
6464
) -> List[Type[Any]]:
65-
...
65+
... # pragma: no cover
6666

6767

6868
@overload
@@ -71,7 +71,7 @@ def discover(
7171
match_func: Optional[Callable[[Any], bool]] = ...,
7272
exclude_side_effects: Literal[False] = ...,
7373
) -> List[Any]:
74-
...
74+
... # pragma: no cover
7575

7676

7777
def discover(

domdf_python_tools/pretty_print.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,11 +38,14 @@
3838
from io import StringIO
3939
from typing import IO, Any, Callable, Iterator, MutableMapping, Optional, Tuple
4040

41-
try:
41+
try: # pragma: no cover
42+
4243
# 3rd party
4344
from pprint36 import PrettyPrinter
4445
from pprint36._pprint import _safe_key # type: ignore
46+
4547
except ImportError:
48+
4649
# stdlib
4750
from pprint import PrettyPrinter, _safe_key # type: ignore
4851

domdf_python_tools/typing.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -50,18 +50,16 @@
5050
# this package
5151
import domdf_python_tools
5252

53-
if typing.TYPE_CHECKING or domdf_python_tools.__docs:
53+
if typing.TYPE_CHECKING or domdf_python_tools.__docs: # pragma: no cover
5454
# 3rd party
55-
from pandas import Series, DataFrame # type: ignore
55+
from pandas import DataFrame, Series # type: ignore
5656

5757
Series.__module__ = "pandas"
5858
DataFrame.__module__ = "pandas"
5959

60-
6160
#: .. versionadded:: 1.0.0
6261
FrameOrSeries = typing.TypeVar("FrameOrSeries", "Series", "DataFrame")
6362

64-
6563
__all__ = [
6664
"PathLike",
6765
"AnyNumber",

domdf_python_tools/utils.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,9 @@
9393
# 3rd party
9494
from pandas import DataFrame, Series # type: ignore
9595

96+
Series.__module__ = "pandas"
97+
DataFrame.__module__ = "pandas"
98+
9699
__all__ = [
97100
"pyversion",
98101
"SPACE_PLACEHOLDER",

0 commit comments

Comments
 (0)