Fix Non-thread-safe operation in wemo tests (#62418)

This commit is contained in:
Eric Severance
2021-12-20 10:56:56 -08:00
committed by GitHub
parent 168fefad88
commit 2dfd4c49da

View File

@@ -53,7 +53,7 @@ async def _async_multiple_call_helper(hass, pywemo_device, call1, call2):
return return
nonlocal call_count nonlocal call_count
call_count += 1 call_count += 1
hass.add_job(waiting.set) hass.loop.call_soon_threadsafe(waiting.set)
event.wait() event.wait()
# Danger! Do not use a Mock side_effect here. The test will deadlock. When # Danger! Do not use a Mock side_effect here. The test will deadlock. When