mirror of
https://github.com/home-assistant/core.git
synced 2026-09-24 15:31:52 -05:00
Send the transition with the WLED segment change (#180471)
This commit is contained in:
@@ -299,7 +299,6 @@ class WLEDSegmentLight(WLEDEntity, LightEntity):
|
||||
|
||||
if ATTR_TRANSITION in data:
|
||||
main_data[ATTR_TRANSITION] = data[ATTR_TRANSITION]
|
||||
del data[ATTR_TRANSITION]
|
||||
|
||||
await self.coordinator.wled.segment(**data)
|
||||
await self.coordinator.wled.master(**main_data)
|
||||
|
||||
@@ -277,7 +277,9 @@ async def test_single_segment_behavior(
|
||||
)
|
||||
assert mock_wled.segment.call_count == 1
|
||||
assert mock_wled.master.call_count == 2
|
||||
mock_wled.segment.assert_called_with(on=True, segment_id=0, brightness=255)
|
||||
mock_wled.segment.assert_called_with(
|
||||
on=True, segment_id=0, brightness=255, transition=50
|
||||
)
|
||||
mock_wled.master.assert_called_with(on=True, transition=50, brightness=42)
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user