Update litejet and zwave tests to use async_add_executor_job (#41927)
* Update litejet and zwave tests to use async_add_executor_job * await
This commit is contained in:
1 parent
0a192947ed
commit
6f113e981b
3 files changed
+29
-21
No files matched your search
@@ -73,7 +73,7 @@ async def simulate_press(hass, mock_lj, number):
|
||||
return_value=mock_lj.start_time + mock_lj.last_delta,
|
||||
):
|
||||
if callback is not None:
|
||||
await hass.async_add_job(callback)
|
||||
await hass.async_add_executor_job(callback)
|
||||
await hass.async_block_till_done()
|
||||
|
||||
|
||||
@@ -86,7 +86,7 @@ async def simulate_release(hass, mock_lj, number):
|
||||
return_value=mock_lj.start_time + mock_lj.last_delta,
|
||||
):
|
||||
if callback is not None:
|
||||
await hass.async_add_job(callback)
|
||||
await hass.async_add_executor_job(callback)
|
||||
await hass.async_block_till_done()
|
||||
|
||||
|
||||
|
||||
Reference in new issue
Block a user