Detect Early Access versions of UniFi Protect and Warn User (#81758)
This commit is contained in:
parent
8252d7f3b5
commit
bfd2eb50b2
13 changed files with 368 additions and 59 deletions
|
@ -72,7 +72,9 @@ async def test_setup_multiple(
|
|||
nvr.id
|
||||
ufp.api.get_nvr = AsyncMock(return_value=nvr)
|
||||
|
||||
with patch("homeassistant.components.unifiprotect.ProtectApiClient") as mock_api:
|
||||
with patch(
|
||||
"homeassistant.components.unifiprotect.utils.ProtectApiClient"
|
||||
) as mock_api:
|
||||
mock_config = MockConfigEntry(
|
||||
domain=DOMAIN,
|
||||
data={
|
||||
|
@ -194,7 +196,7 @@ async def test_setup_starts_discovery(
|
|||
):
|
||||
"""Test setting up will start discovery."""
|
||||
with _patch_discovery(), patch(
|
||||
"homeassistant.components.unifiprotect.ProtectApiClient"
|
||||
"homeassistant.components.unifiprotect.utils.ProtectApiClient"
|
||||
) as mock_api:
|
||||
ufp_config_entry.add_to_hass(hass)
|
||||
mock_api.return_value = ufp_client
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue