hass-core/tests/components/demo
Raman Gupta 0f076610fd
Add siren platform (#48309)
* Add siren platform

* add more supported flags and an ability to set siren duration

* tone can be int or string

* fix typing

* fix typehinting

* fix typehints

* implement a proposed approach based on discussion

* Address comments

* fix tests

* Small fix

* Update homeassistant/components/demo/siren.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/components/demo/siren.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/components/demo/siren.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/components/demo/siren.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/components/demo/siren.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* typing

* use class attributes

* fix naming

* remove device from service description

* Filter out params from turn on service

* fix tests

* fix bugs and tests

* add test

* Combine is_on test with turn on/off/toggle service tests

* Update homeassistant/components/siren/__init__.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* fix filtering of turn_on attributes

* none check

* remove services and attributes for volume level, default duration, and default tone

* Update homeassistant/components/siren/__init__.py

Co-authored-by: Franck Nijhof <frenck@frenck.nl>

* Update homeassistant/components/siren/__init__.py

Co-authored-by: Franck Nijhof <frenck@frenck.nl>

* Update homeassistant/components/siren/__init__.py

Co-authored-by: Franck Nijhof <frenck@frenck.nl>

* import final

* Update homeassistant/components/siren/__init__.py

Co-authored-by: Franck Nijhof <frenck@frenck.nl>

* Fix typing and used TypedDict for service parameters

* remove is_on function

* remove class name redundancy

* remove extra service descriptions

* switch to positive_int

* fix schema for tone

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2021-07-11 16:51:11 -04:00
..
__init__.py Move components to folders (#20774) 2019-02-05 19:31:15 -08:00
conftest.py Add Blueprint foundation to Scripts (#48621) 2021-04-27 15:15:38 -07:00
test_calendar.py Consolidate more platforms (#22308) 2019-03-23 20:22:35 -07:00
test_camera.py Drop asynctest (#44746) 2021-01-01 22:31:56 +01:00
test_climate.py Yoda assertion style removed is (#48142) 2021-03-20 13:55:10 +01:00
test_cover.py Do async_setup_platform in background (#36244) 2020-05-31 22:18:30 -07:00
test_fan.py Implement percentage step sizes for fans (#46512) 2021-02-18 21:05:09 -10:00
test_geo_location.py Drop asynctest (#44746) 2021-01-01 22:31:56 +01:00
test_humidifier.py Clean up constants (#46948) 2021-03-02 12:52:00 +01:00
test_init.py Use contextlib.suppress where possible (#48189) 2021-03-23 14:36:43 +01:00
test_light.py Add color_mode to demo light (#49694) 2021-04-29 10:45:17 +02:00
test_lock.py Do async_setup_platform in background (#36244) 2020-05-31 22:18:30 -07:00
test_media_player.py Add stop for demo players (#50485) 2021-05-12 10:26:12 +02:00
test_notify.py Use async_capture_events to avoid running in executor (#47111) 2021-02-26 13:28:52 -08:00
test_number.py Add new number entity integration (#42735) 2020-12-02 13:50:48 +01:00
test_remote.py Rewrite demo unittest tests to pytest style test functions (#41845) 2020-10-19 23:29:44 +02:00
test_select.py Add Select entity component platform (#51849) 2021-06-18 11:51:55 +02:00
test_siren.py Add siren platform (#48309) 2021-07-11 16:51:11 -04:00
test_stt.py Do async_setup_platform in background (#36244) 2020-05-31 22:18:30 -07:00
test_switch.py Demo: remove deprecated switch entity properties (#52424) 2021-07-02 17:50:57 +02:00
test_vacuum.py Do async_setup_platform in background (#36244) 2020-05-31 22:18:30 -07:00
test_water_heater.py Do async_setup_platform in background (#36244) 2020-05-31 22:18:30 -07:00