1
0
mirror of https://github.com/home-assistant/core.git synced 2025-12-24 12:59:34 +00:00

Fix Hue service being removed on entry reload (#48663)

This commit is contained in:
Paulus Schoutsen
2021-04-13 09:31:23 -07:00
committed by GitHub
parent 05aeff5591
commit 28347e19c5
6 changed files with 92 additions and 88 deletions

View File

@@ -27,7 +27,7 @@ async def test_setup_with_no_config(hass):
assert len(hass.config_entries.flow.async_progress()) == 0
# No configs stored
assert hass.data[hue.DOMAIN] == {}
assert hue.DOMAIN not in hass.data
async def test_unload_entry(hass, mock_bridge_setup):
@@ -41,7 +41,7 @@ async def test_unload_entry(hass, mock_bridge_setup):
mock_bridge_setup.async_reset = AsyncMock(return_value=True)
assert await hue.async_unload_entry(hass, entry)
assert len(mock_bridge_setup.async_reset.mock_calls) == 1
assert hass.data[hue.DOMAIN] == {}
assert hue.DOMAIN not in hass.data
async def test_setting_unique_id(hass, mock_bridge_setup):