Ensure config entry operations are always holding the lock (#117214)

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
This commit is contained in:
J. Nick Koston 2024-05-12 08:20:08 +09:00 committed by GitHub
parent f55fcca0bb
commit 481de8cdc9
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
25 changed files with 256 additions and 84 deletions

View file

@ -70,7 +70,7 @@ async def test_async_remove_entry(hass: HomeAssistant) -> None:
assert hkid in hass.data[ENTITY_MAP].storage_data
# Remove it via config entry and number of pairings should go down
await helper.config_entry.async_remove(hass)
await hass.config_entries.async_remove(helper.config_entry.entry_id)
assert len(controller.pairings) == 0
assert hkid not in hass.data[ENTITY_MAP].storage_data