Remove `pragma: no cover` when not raising (#86706)
parent
468457eff4
commit
25c451832b
|
@ -85,7 +85,7 @@ def _dispatch_bleak_callback(
|
|||
"""Dispatch the callback."""
|
||||
if not callback:
|
||||
# Callback destroyed right before being called, ignore
|
||||
return # pragma: no cover
|
||||
return
|
||||
|
||||
if (uuids := filters.get(FILTER_UUIDS)) and not uuids.intersection(
|
||||
advertisement_data.service_uuids
|
||||
|
|
|
@ -60,7 +60,7 @@ class BroadlinkDevice:
|
|||
@property
|
||||
def available(self):
|
||||
"""Return True if the device is available."""
|
||||
if self.update_manager is None: # pragma: no cover
|
||||
if self.update_manager is None:
|
||||
return False
|
||||
return self.update_manager.available
|
||||
|
||||
|
|
|
@ -99,6 +99,6 @@ class DelugeFlowHandler(ConfigFlow, domain=DOMAIN):
|
|||
return "cannot_connect"
|
||||
except Exception as ex: # pylint:disable=broad-except
|
||||
if type(ex).__name__ == "BadLoginError":
|
||||
return "invalid_auth" # pragma: no cover
|
||||
return "invalid_auth"
|
||||
return "unknown"
|
||||
return None
|
||||
|
|
|
@ -118,7 +118,7 @@ class LitterRobotCleaner(LitterRobotEntity[LitterRobot], StateVacuumEntity):
|
|||
if time_str is None:
|
||||
return None
|
||||
|
||||
if (parsed_time := dt_util.parse_time(time_str)) is None: # pragma: no cover
|
||||
if (parsed_time := dt_util.parse_time(time_str)) is None:
|
||||
return None
|
||||
|
||||
return (
|
||||
|
|
Loading…
Reference in New Issue