mirror of
https://github.com/home-assistant/core.git
synced 2025-04-23 08:47:57 +00:00
Address issues from late review in fibaro config flow tests (#72553)
This commit is contained in:
parent
33784446f6
commit
f82ec4d233
@ -53,7 +53,12 @@ async def test_config_flow_user_initiated_success(hass):
|
||||
|
||||
login_mock = Mock()
|
||||
login_mock.get.return_value = Mock(status=True)
|
||||
with patch("fiblary3.client.v4.client.Client.login", login_mock, create=True):
|
||||
with patch(
|
||||
"fiblary3.client.v4.client.Client.login", login_mock, create=True
|
||||
), patch(
|
||||
"homeassistant.components.fibaro.async_setup_entry",
|
||||
return_value=True,
|
||||
):
|
||||
result = await hass.config_entries.flow.async_configure(
|
||||
result["flow_id"],
|
||||
{
|
||||
@ -182,7 +187,12 @@ async def test_config_flow_import(hass):
|
||||
"""Test for importing config from configuration.yaml."""
|
||||
login_mock = Mock()
|
||||
login_mock.get.return_value = Mock(status=True)
|
||||
with patch("fiblary3.client.v4.client.Client.login", login_mock, create=True):
|
||||
with patch(
|
||||
"fiblary3.client.v4.client.Client.login", login_mock, create=True
|
||||
), patch(
|
||||
"homeassistant.components.fibaro.async_setup_entry",
|
||||
return_value=True,
|
||||
):
|
||||
result = await hass.config_entries.flow.async_init(
|
||||
DOMAIN,
|
||||
context={"source": config_entries.SOURCE_IMPORT},
|
||||
|
Loading…
x
Reference in New Issue
Block a user