Remove some more usage of run_in_executor (#8352)

* Remove usage of run_in_executor

* Lint
This commit is contained in:
Paulus Schoutsen authored and Pascal Vizeli committed 2017-07-06 14:08:32 +02:00
1 parent d655c0e358
commit 143044f8f1
3 files changed
+29 -54

No files matched your search

+2 -4
View File
@@ -83,15 +83,13 @@ def test_trigger_sensor_value_changed(hass, mock_openzwave):
assert not device.is_on
value.data = True
yield from hass.loop.run_in_executor(None, value_changed, value)
yield from hass.async_block_till_done()
yield from hass.async_add_job(value_changed, value)
assert device.invalidate_after is None
device.hass = hass
value.data = True
yield from hass.loop.run_in_executor(None, value_changed, value)
yield from hass.async_block_till_done()
yield from hass.async_add_job(value_changed, value)
assert device.is_on
test_time = device.invalidate_after - datetime.timedelta(seconds=1)