Commit Graph

53 Commits (79c602f59c0db4f0515515457bc7a282e433fb4a)

Author SHA1 Message Date
Andre Lengwenus 759fe54132
Fix transition config storage in LCN light and scene platform (#127847) 2024-10-25 16:25:41 +02:00
epenet 25aea140be
Cleanup unnecessary reconfigure_confirm from config flows (#128086) 2024-10-14 12:57:15 +02:00
G Johansson 666e8e133e
Cover state is enum (#127144)
* Change light state to use enum

* Adjust cover tests

* Update cover

* Fix covers

* Some tests

* More tests

* Fix tests

* Fix
2024-10-08 18:39:04 +02:00
Andre Lengwenus 017ba509a6
Add device_class for LCN sensors (#127921)
* Add device_class for lcn sensor

* Rename device_class mapping dictionary
2024-10-08 14:24:48 +02:00
epenet 9873371413
Use start_reconfigure_flow in config flow tests (#127191)
* Use start_reconfigure_flow in config flow tests

* Adjust fritz
2024-10-02 10:01:15 +02:00
epenet 9d557f47b7
Use reconfigure_confirm in lcn config flow (#127217) 2024-10-01 14:29:31 +02:00
G Johansson c6a1b9fc39
Change Climate set temp action for incorrect feature will raise (#126692)
* Change Climate set temp action for incorrect feature will raise

* Fix some tests

* Fix review comments

* Fix tesla_fleet

* Fix tests

* Fix review comment
2024-09-25 21:16:14 +02:00
Andre Lengwenus 5685ba7f55
Make acknowledge requests from LCN modules optional (#125765)
* Add acknowledge flag to config_entry

* Add acknowledge option to lcn configuration

* Fix tests

* Bump pypck to 0.7.23

* Add entry fixture for config_entry version 1.1 to test migration

* Add data_description to strings.json

* Create versioned config_entry in tests
2024-09-14 09:21:15 +02:00
epenet 0c178d858f
Fix incorrect import in lcn tests (#125877) 2024-09-13 10:12:38 +02:00
Andre Lengwenus 5e1b4b2d23
Clean up tests for LCN (#125493)
* Remove patches on 3rd party module level

* Cleanup test_init

* Cleanup platform tests

* Cleanup test_services

* Cleanup test_websockets

* Cleanup test_device_trigger

* Cleanup test_events

* Remove unused fixture
2024-09-08 09:20:57 +02:00
Andre Lengwenus 20639b0f02
Add tests for LCN climate and scene platform (#124466)
* Add tests for LCN climate and scene platform

* Add type hints

* Add snapshots for test_climate

* Add snapshots for test_scene

* Replace await_called assertion with snapshots

* Remove snapshots for simple status changes

* Test platform setup using snapshot_platform

* Fix type hints

* Patch homeassistant.components.lcn context instead of pypck module

* Fix side effects caused by patching PchkConnectionManager in lcn platform context
2024-09-06 17:56:46 +02:00
Andre Lengwenus 187a38c91f
Add tests for LCN actions / services (#125391)
* Add tests for services/actions

* Add snapshots for services/actions

* Use constants for service names and parameters

* Remove snapshot names
2024-09-06 09:51:11 +02:00
epenet 403db6277f
Improve type hints in lcn tests (#124415) 2024-08-22 14:50:45 +02:00
Andre Lengwenus c276cfc371
Add custom panel for LCN configuration (#108664)
* Add LCN panel using lcn-frontend module

* Move panel from sidebar to integration configuration

* Change OptionFlow to reconfigure step

* Change OptionFlow to reconfigure step

* Remove deprecation warning

* Fix docstring

* Add tests for lcn websockets

* Remove deepcopy

* Bump lcn-frontend to 0.1.3

* Add tests for lcn websockets

* Remove websocket command lcn/hosts

* Websocket scan tests cover modules not stored in config_entry

* Add comment to mock of hass.http

* Add a decorater to ensure the config_entry exists and return it

* Use entry_id instead of host_id

* Bump lcn-frontend to 0.1.5

* Use auto_id for websocket client send_json

* Create issues on yaml import errors

* Remove low level key deprecation warnings

* Method renaming

* Change issue id in issue creation

* Update tests for issue creation
2024-08-21 11:33:47 +02:00
epenet 5608301178
Add missing return type in test __init__ methods (#123932)
* Add missing return type in test __init__ methods

* Adjust
2024-08-14 16:48:52 +02:00
epenet b0d1d7bdb2
Improve type hints in lcn tests (#123648) 2024-08-12 21:53:32 +02:00
epenet ce54ca9c8e
Use service_calls fixture in lcn tests (#120931) 2024-07-01 17:27:32 +02:00
epenet fb1b0058ee
Fix consider-using-tuple pylint warnings in component tests (#119464)
* Fix consider-using-tuple pylint warnings in component tests

* Apply su

Co-authored-by: Michael <35783820+mib1185@users.noreply.github.com>

---------

Co-authored-by: Michael <35783820+mib1185@users.noreply.github.com>
2024-06-12 15:50:27 +02:00
epenet 7e62061b9a
Improve typing for `calls` fixture in tests (a-l) (#118349)
* Improve typing for `calls` fixture in tests (a-l)

* More

* More
2024-05-29 09:06:48 +02:00
Sid 0d66d298ec
Enable Ruff RET504 (#114528)
* Enable Ruff RET504

* fix test

* Use noqa instead of cast

* fix sonos RET504

---------

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2024-04-06 11:07:37 +02:00
epenet 0b01326f9f
Use is in ConfigEntryState enum comparison in tests (A-M) (#114925) 2024-04-05 17:16:55 +02:00
Joost Lekkerkerker 5d500cb74b
Use is in enum comparison in config flow tests K-O (#114672) 2024-04-02 11:21:42 -10:00
Joost Lekkerkerker 6bb4e7d62c
Bump ruff to 0.3.4 (#112690)
Co-authored-by: Sid <27780930+autinerd@users.noreply.github.com>
Co-authored-by: Marc Mueller <30130371+cdce8p@users.noreply.github.com>
Co-authored-by: J. Nick Koston <nick@koston.org>
2024-03-26 00:02:16 +01:00
Marc Mueller 32f3f46542
Add empty line after module docstring (2) [tests.components] (#112737) 2024-03-08 19:16:21 +01:00
Marc Mueller 1722e23df8
Add empty line after module docstring [tests l-p] (#112710) 2024-03-08 14:55:15 +01:00
Jan-Philipp Benecke 0eafc8f2cd
Update k-l* tests to use entity & device registry fixtures (#103929) 2023-11-13 20:02:33 +01:00
Erik Montnemery 7539cf25be
Don't require passing identifiers to DeviceRegistry.async_get_device (#96479)
* Require keyword arguments to DeviceRegistry.async_get_device

* Update tests

* Update tests

* Don't enforce keyword arguments
2023-07-13 13:39:25 -04:00
Erik Montnemery fd822bce56
Replace assert_lists_same with pytest_unordered in integrations h-m (#94901) 2023-06-20 20:16:25 +02:00
epenet c51bde9a26
Fail CI on lingering tasks (#88905) 2023-03-07 11:35:48 +01:00
Franck Nijhof ed79265843
Enable Ruff PT006 (#88165)
* Enable Ruff PT006

* Adjust existing cases

* Fix tests

* Remove unneeded parentheses
2023-02-15 14:09:50 +01:00
epenet ea11a30a35
Add type hints to integration tests (part 13) (#87998) 2023-02-13 14:38:37 +01:00
epenet f75ac17554
Add type hints to integration tests (j-m) (#87704) 2023-02-08 19:06:59 +01:00
Michael e35ab75c0b
Replace the usage of unit constants by enumerations in Tests [h-l] (#85934) 2023-01-15 14:52:55 +01:00
Marc Mueller 63d519c1a8
Spelling updates (#82867) 2022-11-28 16:51:43 +01:00
Franck Nijhof 7cd68381f1
Search/replace RESULT_TYPE_* by FlowResultType enum (#74642) 2022-07-07 19:57:36 +03:00
Andre Lengwenus b7b8feda0f
Add tests for LCN sensor and binary_sensor platforms (#67263) 2022-06-28 21:59:19 -07:00
Andre Lengwenus 389f1f4eda
Add lcn_codelock event and corresponding device trigger (#73022) 2022-06-28 14:01:18 -07:00
Andre Lengwenus ead6e7da1f
Purge entity and device registries when importing lcn from configuration.yaml (#54266)
* Identify LCN orphans in entity registry and device registry and remove them

* Fix typing issues

* Revert "Fix typing issues"

This reverts commit eccd067b3b5f23135e6c8a79d25f7f2cbc2d0ae9.

* Fix removal of devices which do not belong to given config_entry

* Use helper for getting entities for config_entry

* Rename variable
2022-05-22 18:59:44 +02:00
Franck Nijhof 69cc6ab5f1
Clean up accessing entity_registry.async_get_registry helper via hass (#72005) 2022-05-17 16:40:45 +02:00
epenet 67b411d2b2
Use light enums in lcn (#70796) 2022-04-26 15:30:34 +03:00
Erik Montnemery 5e50a8abd5
Mark device triggers from hidden or auxiliary entities as secondary (#70335)
* Mark device triggers from hidden or auxiliary entities as secondary

* Update tests
2022-04-21 08:01:32 +02:00
Erik Montnemery e8852e0f30
Migrate lcn light to color_mode (#69419) 2022-04-07 14:49:12 +02:00
Andre Lengwenus 684f01f466
Add tests for LCN cover platform (#64832) 2022-02-25 10:22:48 +01:00
Andre Lengwenus d5ec2fe842
Add tests for LCN light platform (#64741) 2022-01-23 07:45:22 -10:00
Andre Lengwenus 19e3c08c56
Add tests for LCN switch platform (#52590) 2022-01-22 10:41:25 -10:00
Ville Skyttä c5e6489475
Use DeviceAutomationType in tests/components/[h-l]* (#62441) 2021-12-20 22:18:53 +01:00
Andre Lengwenus 38cb477e7b
Cleanup tests for lcn events and device triggers (#61719)
* Return PchkConnectionManager instance from init_integration

* Removed ip and port from LCN host model identifer

* Fix syntax error

* Convert init_integration to a fixture

* Rename device model for host

* Instantiate MockPchkConnectionManager with arguments from tests

* Invert logic for testing devices
2021-12-19 10:38:33 +01:00
Andre Lengwenus 74d5cbd3a9
Add events and device triggers to LCN (#58745) 2021-12-10 19:02:17 -10:00
Paulus Schoutsen 31153ac155
Move fixtures part 1 (#58902) 2021-11-01 20:47:05 -07:00
Andre Lengwenus b34eb53914
Register LCN devices in device registry (#53143) 2021-10-27 14:29:28 -07:00