diff --git a/homeassistant/components/deconz/manifest.json b/homeassistant/components/deconz/manifest.json index 2cba87f74d6..6a47864375e 100644 --- a/homeassistant/components/deconz/manifest.json +++ b/homeassistant/components/deconz/manifest.json @@ -3,7 +3,7 @@ "name": "deCONZ", "config_flow": true, "documentation": "https://www.home-assistant.io/integrations/deconz", - "requirements": ["pydeconz==72"], + "requirements": ["pydeconz==73"], "ssdp": [ { "manufacturer": "Royal Philips Electronics" diff --git a/requirements_all.txt b/requirements_all.txt index 0faab26721f..aa17999d7f1 100644 --- a/requirements_all.txt +++ b/requirements_all.txt @@ -1295,7 +1295,7 @@ pydaikin==2.3.1 pydanfossair==0.1.0 # homeassistant.components.deconz -pydeconz==72 +pydeconz==73 # homeassistant.components.delijn pydelijn==0.6.1 diff --git a/requirements_test_all.txt b/requirements_test_all.txt index 5519f7f3858..37fe829b0f1 100644 --- a/requirements_test_all.txt +++ b/requirements_test_all.txt @@ -625,7 +625,7 @@ pycountry==19.8.18 pydaikin==2.3.1 # homeassistant.components.deconz -pydeconz==72 +pydeconz==73 # homeassistant.components.dexcom pydexcom==0.2.0 diff --git a/tests/components/deconz/test_light.py b/tests/components/deconz/test_light.py index d070bd5b420..4e9f6b3d512 100644 --- a/tests/components/deconz/test_light.py +++ b/tests/components/deconz/test_light.py @@ -67,6 +67,15 @@ LIGHTS = { "type": "On and Off light", "uniqueid": "00:00:00:00:00:00:00:03-00", }, + "5": { + "ctmax": 1000, + "ctmin": 0, + "id": "Tunable white light with bad maxmin values id", + "name": "Tunable white light with bad maxmin values", + "state": {"on": True, "colormode": "ct", "ct": 2500, "reachable": True}, + "type": "Tunable white light", + "uniqueid": "00:00:00:00:00:00:00:04-00", + }, } @@ -101,7 +110,7 @@ async def test_lights_and_groups(hass): assert "light.on_off_switch" not in gateway.deconz_ids assert "light.on_off_light" in gateway.deconz_ids - assert len(hass.states.async_all()) == 5 + assert len(hass.states.async_all()) == 6 rgb_light = hass.states.get("light.rgb_light") assert rgb_light.state == "on" @@ -117,6 +126,15 @@ async def test_lights_and_groups(hass): assert tunable_white_light.attributes["min_mireds"] == 155 assert tunable_white_light.attributes["supported_features"] == 2 + tunable_white_light_bad_maxmin = hass.states.get( + "light.tunable_white_light_with_bad_maxmin_values" + ) + assert tunable_white_light_bad_maxmin.state == "on" + assert tunable_white_light_bad_maxmin.attributes["color_temp"] == 2500 + assert tunable_white_light_bad_maxmin.attributes["max_mireds"] == 650 + assert tunable_white_light_bad_maxmin.attributes["min_mireds"] == 140 + assert tunable_white_light_bad_maxmin.attributes["supported_features"] == 2 + on_off_light = hass.states.get("light.on_off_light") assert on_off_light.state == "on" assert on_off_light.attributes["supported_features"] == 0 @@ -256,7 +274,7 @@ async def test_disable_light_groups(hass): assert "light.empty_group" not in gateway.deconz_ids assert "light.on_off_switch" not in gateway.deconz_ids # 3 entities - assert len(hass.states.async_all()) == 4 + assert len(hass.states.async_all()) == 5 rgb_light = hass.states.get("light.rgb_light") assert rgb_light is not None @@ -281,7 +299,7 @@ async def test_disable_light_groups(hass): assert "light.empty_group" not in gateway.deconz_ids assert "light.on_off_switch" not in gateway.deconz_ids # 3 entities - assert len(hass.states.async_all()) == 5 + assert len(hass.states.async_all()) == 6 hass.config_entries.async_update_entry( gateway.config_entry, options={deconz.gateway.CONF_ALLOW_DECONZ_GROUPS: False} @@ -294,4 +312,4 @@ async def test_disable_light_groups(hass): assert "light.empty_group" not in gateway.deconz_ids assert "light.on_off_switch" not in gateway.deconz_ids # 3 entities - assert len(hass.states.async_all()) == 4 + assert len(hass.states.async_all()) == 5