Skip to content

Commit

Permalink
Correct return type of climate entity feature
Browse files Browse the repository at this point in the history
  • Loading branch information
PeteRager committed Feb 7, 2025
1 parent ea71cdb commit 4a7a8a8
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions custom_components/lennoxs30/climate.py
Original file line number Diff line number Diff line change
Expand Up @@ -195,10 +195,10 @@ def is_single_setpoint_active(self) -> bool:
return True

@property
def supported_features(self):
def supported_features(self) -> ClimateEntityFeature:
"""Return the list of supported features."""
if self.is_zone_disabled:
return 0
return ClimateEntityFeature(0)

mask = SUPPORT_FLAGS

Expand Down
2 changes: 1 addition & 1 deletion tests/test_climate.py
Original file line number Diff line number Diff line change
Expand Up @@ -752,7 +752,7 @@ async def test_climate_supported_features(hass, manager_mz: Manager):
assert feat != 0
system.zoningMode = LENNOX_ZONING_MODE_CENTRAL
feat = c1.supported_features
assert feat == 0
assert feat == ClimateEntityFeature(0)
feat = c.supported_features
assert feat != 0

Expand Down

0 comments on commit 4a7a8a8

Please sign in to comment.