1
0
mirror of https://github.com/home-assistant/core.git synced 2025-12-24 12:59:34 +00:00

Add missing timeout to command_line platforms: cover, notify, switch (#38497)

* Add missing timeout to command_line platforms: cover, notify, switch

* add timeout test for notify
This commit is contained in:
J. Nick Koston
2020-08-04 17:00:02 -10:00
committed by GitHub
parent dddcb8e299
commit 7b728b17f7
11 changed files with 132 additions and 67 deletions

View File

@@ -27,6 +27,7 @@ def rs(hass):
"command_stop",
"command_state",
None,
15,
)
@@ -45,7 +46,7 @@ def test_query_state_value(rs):
assert "foo bar" == result
assert mock_run.call_count == 1
assert mock_run.call_args == mock.call(
"runme", shell=True, # nosec # shell by design
"runme", shell=True, timeout=15 # nosec # shell by design
)