323 Commits

Author SHA1 Message Date
epenet
0bc572787a
Add check for valid error code in translation checks in flows (#128445) 2024-10-16 19:03:24 +02:00
epenet
3ba3fbf4a5
Add tests/components/conftest.py to core files (#128425) 2024-10-15 10:34:54 +02:00
epenet
c87a2ca335
Add default reconfigure reason in update_reload_and_abort (#127756)
* Add default reconfigure reason in async_update_reload_and_abort

* Simplify

* Fix test

* Add sample usage

* Remove multi-line ternary
2024-10-07 09:02:58 +02:00
Erik Montnemery
7ec911c4df
Correct typing in rediscovery tests (#127777) 2024-10-07 08:42:04 +02:00
epenet
e705ca83b2
Use reconfigure helpers in config tests (#127534)
Use async_update_reload_and_abort in config test
2024-10-06 16:06:55 +02:00
Erik Montnemery
c5b4892596
Adjust BaseEditConfigView.__init__ (#126729) 2024-09-27 19:08:12 +02:00
Joost Lekkerkerker
a1906b434f
Change trigger platform key to trigger (#124357)
* fix

* Fix

* Fix

* Update homeassistant/helpers/config_validation.py

Co-authored-by: Erik Montnemery <erik@montnemery.com>

* Fix

* Fix

* Fix

* Fix

* Add more tests

* Fix

* Fix tests

* Add tests

* Let's see what the CI does

* It fails on the code that tested the thing ofc

* It fails on the code that tested the thing ofc

* Revert test thingy

* Now the test works again, lovely

* Another one

* Fix websocket thingy

* Only copy when needed

* Improve comment

* Remove test

* Fix docstring

* I think this now also work since this transforms trigger to platform

* Add comment

* Update homeassistant/helpers/config_validation.py

Co-authored-by: Erik Montnemery <erik@montnemery.com>

* Update homeassistant/helpers/config_validation.py

Co-authored-by: Erik Montnemery <erik@montnemery.com>

* Update homeassistant/helpers/config_validation.py

Co-authored-by: Erik Montnemery <erik@montnemery.com>

* Check for mapping

* Add test

* Update homeassistant/helpers/config_validation.py

Co-authored-by: Erik Montnemery <erik@montnemery.com>

* Update test to also test for trigger keys

---------

Co-authored-by: Erik Montnemery <erik@montnemery.com>
2024-09-25 14:19:58 +02:00
Franck Nijhof
9dfabc3fb7
Adjust automation to plural triggers/conditions/actions keys (#123823)
* Adjust automation to plural triggers/conditions/actions keys

* Fix some tests

* Adjust websocket tests

* Fix search tests

* Convert blueprint and blueprint inputs to modern schema

* Pass schema when creating Blueprint object

* Update tests

* Adjust websocket api

---------

Co-authored-by: Joostlek <joostlek@outlook.com>
Co-authored-by: Erik <erik@montnemery.com>
2024-09-24 20:03:23 +02:00
Erik Montnemery
d82bff1bc2
Index config entry discovery_keys by discovery domain (#126563)
* Index config entry discovery_keys by discovery domain

* Add new signal

* Update tests

* Update homeassistant/config_entries.py

Co-authored-by: J. Nick Koston <nick@koston.org>

* Fix imports

---------

Co-authored-by: J. Nick Koston <nick@koston.org>
2024-09-23 21:48:11 +02:00
Erik Montnemery
b2982c18bb
Reinitialize zeroconf discovery flow on unignore (#125753)
* Reinitialize zeroconf discovery flow on unignore

* Adjust tests

* Improve comments

* Fix logic for updating discovery keys

* Add tests

* Use mock_config_flow helper in new config_entries test

* Add discovery_keys attribute to ConfigEntry

* Update zeroconf rediscovery

* Change type of ConfigEntry.discovery_keys

* Update tests

* Fix DiscoveryKey.from_json_dict and add tests

* Fix test

---------

Co-authored-by: J. Nick Koston <nick@koston.org>
2024-09-23 16:49:21 +02:00
Paul Bottein
b471a6e519
Add has_entity_name to entity display dict and fix name (#125832)
* Add has_entity_name to entity display dict and fix name

* Fix tests
2024-09-19 11:35:44 +02:00
Alberto Montes
5d2f8319b1
Update string formatting to use f-string on tests (#125986)
* Update string formatting to use f-string on tests

* Update test_package.py

Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>

* Update statement given feedback

---------

Co-authored-by: epenet <6771947+epenet@users.noreply.github.com>
2024-09-19 10:32:38 +02:00
epenet
975363b660
Add missing hass type hint in component tests (c) (#124067) 2024-08-18 15:35:31 +02:00
Robert Resch
ad50136dbd
Add created_at/modified_at to config entries (#122456) 2024-07-29 22:08:46 +02:00
Robert Resch
545514c5cd
Add created_at/modified_at to category registry (#122454) 2024-07-23 14:39:38 +02:00
Robert Resch
0d765a27c9
Add created_at/modified_at to entity registry (#122444) 2024-07-23 13:12:29 +02:00
Robert Resch
4c853803f1
Add created_at/modified_at to device registry (#122369) 2024-07-22 19:15:23 +02:00
Robert Resch
243a68fb1f
Frontend wants a timestamp for the created_at/modified_at attributes (#122377) 2024-07-22 14:10:16 +02:00
Marc Mueller
a6068dcdf2
Update import locations in tests (#122216) 2024-07-20 11:16:04 +02:00
Stefan Agner
7b5b6c7b85
Tolerate integration removed device (#120722) 2024-07-19 19:00:31 +02:00
Robert Resch
35f84f32d6
Add created_at/modified_at for area registry (#122014) 2024-07-17 09:54:06 +02:00
Joost Lekkerkerker
f8ba4d41ba
Add support for adding model_id in device info (#121989) 2024-07-16 15:12:25 +02:00
Robert Resch
a0b604f98c
Improve add user error messages (#120909) 2024-07-01 18:27:40 +02:00
Marc Mueller
2f0dd6f704
Import Generator from collections.abc (2) (#120915) 2024-07-01 11:58:49 +02:00
Erik Montnemery
9bbeb5d608
Add primary_config_entry attribute to device registry entries (#119959)
Co-authored-by: Franck Nijhof <git@frenck.dev>
Co-authored-by: Robert Resch <robert@resch.dev>
2024-06-26 12:26:24 +02:00
Robert Resch
641507a45a
Add change username endpoint (#109057) 2024-06-24 18:51:19 +02:00
epenet
8bad421a04
Improve type hints in config tests (#120346) 2024-06-24 18:36:57 +02:00
Paulus Schoutsen
eb89ce47ea
Inline primary integration (#119860) 2024-06-18 08:08:08 +02:00
Paulus Schoutsen
836abe68c7
Track primary integration (#119741)
* Track primary integration

* Update snapshots

* More snapshots updated

* Uno mas

* Update snapshot
2024-06-16 13:26:06 -04:00
Erik Montnemery
7e61ec96e7
Make the radius of the home zone configurable (#119385) 2024-06-15 13:22:01 +02:00
epenet
c70cfbb535
Fix arguments-renamed pylint warning in tests (#119473) 2024-06-12 12:25:29 +02:00
epenet
bdf69c2e5b
Remove deprecated imports in config tests (#119393) 2024-06-11 16:11:10 +02:00
Erik Montnemery
f9cf7598da
Fix missing checks in core config test (#119387) 2024-06-11 14:13:12 +02:00
epenet
c896458fcf
Fix namespace-import pylint warning in components (#119299) 2024-06-10 15:55:08 +02:00
epenet
fbaba3753b
Fix root-import pylint warning in components (#119294)
* Fix root-import pylint warning in components

* Adjust

* Adjust
2024-06-10 15:14:49 +02:00
epenet
907297cd1a
Improve type hints in config tests (#119055) 2024-06-07 11:40:03 +02:00
epenet
c7e065c413
Move enable_custom_integrations fixture to decorator (#118844) 2024-06-05 09:20:08 +02:00
epenet
092cdcfe91
Improve type hints in tests (a-h) (#118379) 2024-05-30 08:46:18 +02:00
epenet
461ac1e0bc
Add ClientSessionGenerator type hints in tests (#118377) 2024-05-29 14:49:14 +02:00
Marc Mueller
dd22ee3dac
Improve annotation styling (#118032) 2024-05-24 15:05:53 +02:00
Erik Montnemery
5c1f6aeb60
Use mock_config_flow helper in config tests (#117245) 2024-05-11 14:09:00 -04:00
Erik Montnemery
3bea124d84
Sort asserts in config config_entries tests (#117244) 2024-05-11 17:38:07 +02:00
J. Nick Koston
6cf1c5c1f2
Hold a lock to prevent concurrent setup of config entries (#116482) 2024-04-30 18:47:12 -05:00
epenet
48b1678075
Add test helper to remove device (#116234)
* Add test helper to remove device

* Rename

* Fix signature
2024-04-28 18:50:15 +02:00
Erik Montnemery
7cd0fe3c5f
Don't reload other automations when saving an automation (#80254)
* Only reload modified automation

* Correct check for existing automation

* Add tests

* Remove the new service, improve ReloadServiceHelper

* Revert unneeded changes

* Update tests

* Address review comments

* Improve test coverage

* Address review comments

* Tweak reloader code + add a targetted test

* Apply suggestions from code review

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

* Explain the tests + add more variations

* Fix copy-paste mistake in test

* Rephrase explanation of expected test outcome

---------

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2024-04-16 15:58:57 +02:00
epenet
24f83c5890
Use is in FlowResultType enum comparison in tests (#114917)
* Use is in FlowResultType enum comparison in tests

* Adjust auth

* Adjust systemmonitor

* Once more

* Add comment
2024-04-05 10:40:14 +02:00
G Johansson
fc4d960d17
Add translation support to Config Entry errors (#106305)
* Config Entry error translation

* split key and placeholders

* Fix config entries tests

* translation optional

* Mods
2024-03-28 10:52:21 +01:00
Franck Nijhof
c247534731
Default floor level to None (and allow unsetting it) (#114249) 2024-03-26 18:58:25 +01: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
efc54971d3
Update empty line formatting after module docstring (#114040) 2024-03-23 00:27:57 +01:00