Add support for supportedOperations to Alexa.PlaybackController (#28212)
* Added support for supportedOperations to Alexa.PlaybackController * Added support for supportedOperations to Alexa.PlaybackController
This commit is contained in:
1 parent
f2d6cc7329
commit
da8a476142
2 files changed
+40
-1
No files matched your search
@@ -726,7 +726,7 @@ async def test_media_player(hass):
|
||||
assert appliance["displayCategories"][0] == "TV"
|
||||
assert appliance["friendlyName"] == "Test media player"
|
||||
|
||||
assert_endpoint_capabilities(
|
||||
capabilities = assert_endpoint_capabilities(
|
||||
appliance,
|
||||
"Alexa.InputController",
|
||||
"Alexa.PowerController",
|
||||
@@ -737,6 +737,13 @@ async def test_media_player(hass):
|
||||
"Alexa.ChannelController",
|
||||
)
|
||||
|
||||
playback_capability = get_capability(capabilities, "Alexa.PlaybackController")
|
||||
assert playback_capability is not None
|
||||
supported_operations = playback_capability["supportedOperations"]
|
||||
operations = ["Play", "Pause", "Stop", "Next", "Previous"]
|
||||
for operation in operations:
|
||||
assert operation in supported_operations
|
||||
|
||||
await assert_power_controller_works(
|
||||
"media_player#test", "media_player.turn_on", "media_player.turn_off", hass
|
||||
)
|
||||
|
||||
Reference in new issue
Block a user