mirror of
https://github.com/home-assistant/core.git
synced 2026-09-25 07:51:46 -05:00
Split the PVOutput user flow init from its data (#180652)
This commit is contained in:
@@ -104,9 +104,15 @@ async def test_connection_error(hass: HomeAssistant, mock_pvoutput: MagicMock) -
|
||||
mock_pvoutput.system.side_effect = PVOutputConnectionError
|
||||
|
||||
result = await hass.config_entries.flow.async_init(
|
||||
DOMAIN,
|
||||
context={"source": SOURCE_USER},
|
||||
data={
|
||||
DOMAIN, context={"source": SOURCE_USER}
|
||||
)
|
||||
|
||||
assert result.get("type") is FlowResultType.FORM
|
||||
assert result.get("step_id") == "user"
|
||||
|
||||
result = await hass.config_entries.flow.async_configure(
|
||||
result["flow_id"],
|
||||
user_input={
|
||||
CONF_SYSTEM_ID: 12345,
|
||||
CONF_API_KEY: "tadaaa",
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user