Commit graph

38 commits

Author SHA1 Message Date
Artem Draft
c14a2dd912
Add active_child_template to universal media player (#88816)
* Add active_children_template in universal

* handle multiple updates

* edit docstring

* Rename parameter to active_child_template
2023-06-28 16:36:18 +02:00
Erik Montnemery
0126cfa9d9
Allow exposing any entity to the default conversation agent (#92398)
* Allow exposing any entity to the default conversation agent

* Tweak

* Fix race, update tests

* Update tests
2023-05-03 09:45:54 -04:00
epenet
a0f725dfcb
Add type hints to tests (#89497) 2023-03-10 12:06:50 +01:00
epenet
9762b684c2
Adjust entity registry access in tests (3) (#88964) 2023-03-01 16:04:40 +01:00
Artem Draft
f18c0bf626
Pass assumed_state property in universal media player (#87846)
Pass assumed_state property in universal media player
2023-02-25 07:43:58 +01:00
Artem Draft
6474297d1f
Browse media support in universal media player (#85668)
Allow forward and override browse media in universal media player
2023-02-23 09:17:46 +01:00
epenet
9a5f88f55f
Add type hints to integration tests (part 23) (#88235) 2023-02-17 16:40:46 +01:00
epenet
278050a73f
Add type hints to integration tests (t-z) (#87707) 2023-02-08 19:10:53 +01:00
epenet
0d696b84b2
Cleanup root component imports in tests (#78893) 2022-09-21 06:57:41 -10:00
holysoles
c3b2e03ce8
Support unique_id for Universal Media Player (#77461)
* support unique id

* tests for unique_id

* use unique_id attribute
2022-09-09 11:50:39 +02:00
Joakim Plate
083e902dc0
Ignore unknown states in universal media player (#77388)
Ignore unknown states
2022-08-31 19:53:14 +02:00
Chris Browet
596f60bdb5
Universal media player: ordered states (#68036) 2022-06-28 22:03:56 -07:00
Franck Nijhof
8f4caf4141
Clean up accessing event helpers via hass (#72011) 2022-05-17 19:36:29 +02:00
epenet
75eec850c1
Use EntityFeature enum in components (u**) (#69462) 2022-04-06 21:35:15 -10:00
Paulus Schoutsen
7f2f135e13
Convert last media player tests to async (#64572) 2022-01-20 13:05:33 -08:00
Paulus Schoutsen
31153ac155
Move fixtures part 1 (#58902) 2021-11-01 20:47:05 -07:00
Graham Rogers
4f96f05a75
Improve Universal media player toggle default behavior (#49395)
Before it could not be overridden and the default behavior meant nothing was called when all children were off, so it could not be used to turn on the media player. The new default behavior is to delegate to `turn_on` and `turn_off` instead, which is more likely to be the expected behavior.
2021-08-02 15:10:56 +02:00
Artem Draft
d29e812033
New overrides in universal media player (#48611)
* Update media_player.py

fix missing overrides in universal

* Update media_player.py

Black

* add tests and allow overrides for missing services

* switch sync to async

* Update tests/components/universal/test_media_player.py

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

* setup component after modifying config

* switch test to sync

* fix black

* fix test

* rework tests, disable override media_seek

Co-authored-by: raman325 <7243222+raman325@users.noreply.github.com>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-05-11 23:44:26 +02:00
Franck Nijhof
08870690a6
Fix a collection of tests with missing asserts (#48127)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-03-20 17:23:55 +01:00
Franck Nijhof
5a2b5fe7c5
Yoda assertion style removed is (#48142) 2021-03-20 13:55:10 +01:00
Franck Nijhof
fb849b81b5
Rewrite of not a == b occurances (#48132) 2021-03-20 01:27:04 +01:00
Raman Gupta
cfdaadf5d9
Allow users to set device class for universal media player (#46550) 2021-02-14 17:05:23 -10:00
Raman Gupta
a3b733f1ec
Add additional supported feature support to universal media player (#44711)
* add additional supported feature support to universal media player

* add missing services
2021-02-14 19:35:14 -05:00
Franck Nijhof
65cf2fcb6f
Drop asynctest (#44746) 2021-01-01 22:31:56 +01:00
J. Nick Koston
44952a94cf
Add missing conext preservation to bayesian and universal (#40178)
We already do this for template sensors, but it was
missing for bayesian and universal
2020-09-17 16:47:23 +02:00
Paulus Schoutsen
6de02fc1b9
Fix some more usages of asynctest (#39570) 2020-09-02 14:53:07 +02:00
Franck Nijhof
1c2ebdf307
Upgrade black to 20.8b1 (#39287) 2020-08-27 13:56:20 +02:00
J. Nick Koston
810df38f0d
Add the ability to reload light/cover groups from yaml (#39250)
* Add the ability to reload light/cover groups from yaml

Update previous usage to reduce code duplication.

* Fix conflict from rebase
2020-08-25 18:13:43 -05:00
J. Nick Koston
90842fcb84
Support reloading the universal platform (#39248) 2020-08-26 00:25:15 +02:00
J. Nick Koston
9baf3ff706
Update universal media_player to use async_track_template_result (#39054)
* Update universal media_player to use async_track_template_result

* Review comments and add missing test cover
2020-08-22 18:12:53 -05:00
Paulus Schoutsen
c33edbe5bb
Use TestCase.addCleanup (#36560) 2020-06-08 12:26:40 -07:00
Erik Montnemery
62bc02fdda
Rename MediaPlayerDevice to MediaPlayerEntity (#34592) 2020-04-25 18:00:57 +02:00
springstan
157f972d72
Use f-strings in integrations starting with "H" - "L" (#32265)
* Use f-strings in integrations starting with "H"

* Use f-strings in integrations starting with "I"

* Use f-strings in integrations starting with "J"

* Use f-strings in integrations starting with "K"

* Use f-strings in integrations starting with "L"

* Fix lint error

* Use join instead of f-string in homekit_controller

* Use local variables with f-strings

* Fix lint error

* Escape the characters in f-string

* Sort imports with isort in homeworks light

* Fix pylint error

* Fix broken tests

* Fix broken tests v2
2020-02-28 12:39:29 +01:00
Bas Nijholt
e37443f10c Sort imports according to PEP8 for components starting with "U" (#29779)
* use isort to sort imports for components starting with 'u'

* add 'pylint: disable=import-error' to the right place
2019-12-09 19:07:32 +01:00
Michaël Arnauts
cc346e57e6 Cast the volume_level of a universal media_player to a float (#29045)
* Make sure to cast the volume_level of a universal media_player to a float

* Fix test that expects the wrong bahaviour

* Catch exception instead of checking for None
2019-11-25 18:01:24 -08:00
Pascal Vizeli
c1851a2d94
Cleanup coroutine threadsafe (#27080)
* Cleanup coroutine threadsafe

* fix lint

* Fix typing

* Fix tests

* Fix black
2019-10-01 16:59:06 +02:00
Paulus Schoutsen
4de97abc3a Black 2019-07-31 12:25:30 -07:00
Penny Wood
f195ecca4b Consolidate all platforms that have tests (#22109)
* Moved climate components with tests into platform dirs.

* Updated tests from climate component.

* Moved binary_sensor components with tests into platform dirs.

* Updated tests from binary_sensor component.

* Moved calendar components with tests into platform dirs.

* Updated tests from calendar component.

* Moved camera components with tests into platform dirs.

* Updated tests from camera component.

* Moved cover components with tests into platform dirs.

* Updated tests from cover component.

* Moved device_tracker components with tests into platform dirs.

* Updated tests from device_tracker component.

* Moved fan components with tests into platform dirs.

* Updated tests from fan component.

* Moved geo_location components with tests into platform dirs.

* Updated tests from geo_location component.

* Moved image_processing components with tests into platform dirs.

* Updated tests from image_processing component.

* Moved light components with tests into platform dirs.

* Updated tests from light component.

* Moved lock components with tests into platform dirs.

* Moved media_player components with tests into platform dirs.

* Updated tests from media_player component.

* Moved scene components with tests into platform dirs.

* Moved sensor components with tests into platform dirs.

* Updated tests from sensor component.

* Moved switch components with tests into platform dirs.

* Updated tests from sensor component.

* Moved vacuum components with tests into platform dirs.

* Updated tests from vacuum component.

* Moved weather components with tests into platform dirs.

* Fixed __init__.py files

* Fixes for stuff moved as part of this branch.

* Fix stuff needed to merge with balloob's branch.

* Formatting issues.

* Missing __init__.py files.

* Fix-ups

* Fixup

* Regenerated requirements.

* Linting errors fixed.

* Fixed more broken tests.

* Missing init files.

* Fix broken tests.

* More broken tests

* There seems to be a thread race condition.
I suspect the logger stuff is running in another thread, which means waiting until the aio loop is done is missing the log messages.
Used sleep instead because that allows the logger thread to run. I think the api_streams sensor might not be thread safe.

* Disabled tests, will remove sensor in #22147

* Updated coverage and codeowners.
2019-03-18 23:07:39 -07:00