Add supported_features to cover component (#6082)
This commit is contained in:
1 parent
3cb1a5dd89
commit
5f095b5126
4 files changed
+58
-4
No files matched your search
@@ -24,6 +24,17 @@ class TestCoverDemo(unittest.TestCase):
|
||||
"""Stop down everything that was started."""
|
||||
self.hass.stop()
|
||||
|
||||
def test_supported_features(self):
|
||||
"""Test cover supported features."""
|
||||
state = self.hass.states.get('cover.garage_door')
|
||||
self.assertEqual(3, state.attributes.get('supported_features'))
|
||||
state = self.hass.states.get('cover.kitchen_window')
|
||||
self.assertEqual(11, state.attributes.get('supported_features'))
|
||||
state = self.hass.states.get('cover.hall_window')
|
||||
self.assertEqual(15, state.attributes.get('supported_features'))
|
||||
state = self.hass.states.get('cover.living_room_window')
|
||||
self.assertEqual(255, state.attributes.get('supported_features'))
|
||||
|
||||
def test_close_cover(self):
|
||||
"""Test closing the cover."""
|
||||
state = self.hass.states.get(ENTITY_COVER)
|
||||
|
||||
Reference in new issue
Block a user