Skip to content

Commit

Permalink
chore: Exclude code from coverage where necessary
Browse files Browse the repository at this point in the history
  • Loading branch information
AnonymouX47 committed Jun 2, 2024
1 parent a534a14 commit 9a66880
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/term_image/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@

# Follows https://semver.org/spec/v2.0.0.html
__version__ = ".".join(map(str, version_info[:3]))
if version_info[3:]:
if version_info[3:]: # pragma: no cover
__version__ += "-" + ".".join(map(str, version_info[3:]))

DEFAULT_QUERY_TIMEOUT: Final[float] = utils._query_timeout
Expand Down
3 changes: 2 additions & 1 deletion src/term_image/renderable/_renderable.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,8 @@

try:
import termios
except ImportError:
# Even if it's possible to simulate this in the tests, what's the point?
except ImportError: # pragma: no cover
OS_IS_UNIX = False
else:
OS_IS_UNIX = True
Expand Down
2 changes: 1 addition & 1 deletion src/term_image/widget/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

try:
import urwid
except ImportError:
except ImportError: # pragma: no cover
pass
else:
from ._urwid import UrwidImage, UrwidImageCanvas, UrwidImageScreen
Expand Down

0 comments on commit 9a66880

Please sign in to comment.