mirror of
https://github.com/home-assistant/core.git
synced 2025-09-06 13:21:33 +02:00
Also test unique ID in config flow test for APCUPSD (#150362)
This commit is contained in:
@@ -13,7 +13,6 @@ rules:
|
||||
Consider looking into making a `mock_setup_entry` fixture that just automatically do this.
|
||||
`test_config_flow_cannot_connect`: Needs to end in CREATE_ENTRY to test that its able to recover.
|
||||
`test_config_flow_duplicate`: this test should be split in 2, one for testing duplicate host/port and one for duplicate serial number.
|
||||
`test_flow_works`: Should also test unique id.
|
||||
config-flow: done
|
||||
dependency-transparency: done
|
||||
docs-actions:
|
||||
|
@@ -123,6 +123,7 @@ async def test_flow_works(hass: HomeAssistant) -> None:
|
||||
assert result["type"] is FlowResultType.CREATE_ENTRY
|
||||
assert result["title"] == MOCK_STATUS["UPSNAME"]
|
||||
assert result["data"] == CONF_DATA
|
||||
assert result["result"].unique_id == MOCK_STATUS["SERIALNO"]
|
||||
|
||||
mock_setup.assert_called_once()
|
||||
|
||||
|
Reference in New Issue
Block a user