Add brightness_step to light.turn_on (#31452)
* Clean up light turn on service * Add brightness_step to turn_on schema * Fix import * Fix imports 2 * Fix RFLink test
This commit is contained in:
1 parent
e970177eeb
commit
c85a7934ed
7 files changed
+115
-73
No files matched your search
@@ -298,18 +298,16 @@ async def test_signal_repetitions_cancelling(hass, monkeypatch):
|
||||
DOMAIN, SERVICE_TURN_OFF, {ATTR_ENTITY_ID: DOMAIN + ".test"}
|
||||
)
|
||||
|
||||
hass.async_create_task(
|
||||
hass.services.async_call(
|
||||
DOMAIN, SERVICE_TURN_ON, {ATTR_ENTITY_ID: DOMAIN + ".test"}
|
||||
)
|
||||
await hass.services.async_call(
|
||||
DOMAIN, SERVICE_TURN_ON, {ATTR_ENTITY_ID: DOMAIN + ".test"}, blocking=True
|
||||
)
|
||||
|
||||
await hass.async_block_till_done()
|
||||
|
||||
assert protocol.send_command_ack.call_args_list[0][0][1] == "off"
|
||||
assert protocol.send_command_ack.call_args_list[1][0][1] == "on"
|
||||
assert protocol.send_command_ack.call_args_list[2][0][1] == "on"
|
||||
assert protocol.send_command_ack.call_args_list[3][0][1] == "on"
|
||||
assert [call[0][1] for call in protocol.send_command_ack.call_args_list] == [
|
||||
"off",
|
||||
"on",
|
||||
"on",
|
||||
"on",
|
||||
]
|
||||
|
||||
|
||||
async def test_type_toggle(hass, monkeypatch):
|
||||
|
||||
Reference in new issue
Block a user