Use single_instance_allowed for webhook config flows (#40965)

This commit is contained in:
springstan authored and GitHub committed 2020-10-01 20:44:13 +02:00
1 parent 17c6838b7f
commit c7ebfdb403
23 files changed
+27 -25

No files matched your search

@@ -83,4 +83,4 @@ async def test_integration_already_configured(hass):
)
assert result["type"] == data_entry_flow.RESULT_TYPE_ABORT
assert result["reason"] == "one_instance_allowed"
assert result["reason"] == "single_instance_allowed"
@@ -111,12 +111,12 @@ async def test_abort_if_already_setup(hass):
# Should fail, already setup (import)
result = await flow.async_step_import({})
assert result["type"] == data_entry_flow.RESULT_TYPE_ABORT
assert result["reason"] == "one_instance_allowed"
assert result["reason"] == "single_instance_allowed"
# Should fail, already setup (flow)
result = await flow.async_step_user({})
assert result["type"] == data_entry_flow.RESULT_TYPE_ABORT
assert result["reason"] == "one_instance_allowed"
assert result["reason"] == "single_instance_allowed"
async def test_user_not_supports_encryption(hass, not_supports_encryption):
+1 -1
View File
@@ -51,4 +51,4 @@ async def test_one_instance_allowed(hass):
DOMAIN, context={"source": config_entries.SOURCE_USER}
)
assert result["type"] == "abort"
assert result["reason"] == "one_instance_allowed"
assert result["reason"] == "single_instance_allowed"
@@ -135,4 +135,4 @@ async def test_integration_already_configured(hass):
speedtestdotnet.DOMAIN, context={"source": "user"}
)
assert result["type"] == data_entry_flow.RESULT_TYPE_ABORT
assert result["reason"] == "one_instance_allowed"
assert result["reason"] == "single_instance_allowed"