mirror of
https://github.com/home-assistant/core.git
synced 2025-12-25 05:26:47 +00:00
Fix ESPHome nodes being auto-added without user confirmation (#21444)
This commit is contained in:
committed by
Paulus Schoutsen
parent
ab73b725e1
commit
29187795a8
@@ -203,6 +203,11 @@ async def test_discovery_initiation(hass, mock_client):
|
||||
MockDeviceInfo(False, "test8266"))
|
||||
|
||||
result = await flow.async_step_discovery(user_input=service_info)
|
||||
assert result['type'] == 'form'
|
||||
assert result['step_id'] == 'discovery_confirm'
|
||||
assert result['description_placeholders']['name'] == 'test8266'
|
||||
|
||||
result = await flow.async_step_discovery_confirm(user_input={})
|
||||
assert result['type'] == 'create_entry'
|
||||
assert result['title'] == 'test8266'
|
||||
assert result['data']['host'] == 'test8266.local'
|
||||
|
||||
Reference in New Issue
Block a user