Address review comment on myuplink tests (#132819)

pull/132779/head^2
Åke Strandberg 2024-12-10 12:58:42 +01:00 committed by GitHub
parent 71d7e14032
commit 46d4081ec6
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 6 additions and 1 deletions

View File

@ -69,11 +69,16 @@ async def test_full_flow(
with patch(
f"homeassistant.components.{DOMAIN}.async_setup_entry", return_value=True
) as mock_setup:
await hass.config_entries.flow.async_configure(result["flow_id"])
result = await hass.config_entries.flow.async_configure(result["flow_id"])
await hass.async_block_till_done()
assert len(hass.config_entries.async_entries(DOMAIN)) == 1
assert len(mock_setup.mock_calls) == 1
assert result["data"]["auth_implementation"] == DOMAIN
assert result["data"]["token"]["refresh_token"] == "mock-refresh-token"
assert result["result"].unique_id == UNIQUE_ID
@pytest.mark.usefixtures("current_request_with_host")
@pytest.mark.parametrize(