Commit Graph

54 Commits

Author SHA1 Message Date
Abílio Costa
e8a534be9c Add missing method mock to Reolink chime test (#147447) 2025-06-24 20:06:54 +02:00
Abílio Costa
fe4ff4f835 Use non-autospec mock for Reolink switch tests (#147441) 2025-06-24 19:19:41 +02:00
starkillerOG
2862f76fca Add support for Reolink Floodlight PoE/WiFi (#146778)
* Add support for Floodlight PoE/WiFi

* Adjust test

* Add test
2025-06-23 20:43:01 +02:00
Abílio Costa
f90a740429 Use non-autospec mock for Reolink's binary_sensor, camera and diag tests (#147095) 2025-06-19 08:03:48 +02:00
Abílio Costa
9adf493acd Use non-autospec mock for Reolink's init tests (#146991) 2025-06-18 17:58:50 +01:00
Abílio Costa
6f3ceb83c2 Use non-autospec mock for Reolink's button tests (#146969) 2025-06-16 21:14:02 +02:00
starkillerOG
680b70aa29 Reolink add diagnostics for baichuan (#146667)
* Add baichuan diagnostics

* adjust tests
2025-06-12 19:26:37 +02:00
starkillerOG
e46e7f5a81 Bump reolink-aio to 0.14.0 (#146566) 2025-06-11 23:52:31 +02:00
starkillerOG
cf1cbc6d75 Add Reolink recording packing time (#142847) 2025-04-14 22:22:21 +02:00
starkillerOG
40fd7cf852 Select correct Reolink device uid (#142864)
* Select correct device_uid

* Fix styling

* restructure

* Add test

* Update test_util.py

* Add explanation string
2025-04-14 20:12:34 +02:00
starkillerOG
840613f43d Add mac to Reolink IPC cam device info (#140822)
* Add mac to Reolink IPC cams

* Add test

* check mac none
2025-03-26 00:31:01 +01:00
starkillerOG
334359871d Add Reolink home hub scene select entity (#140823) 2025-03-19 14:34:49 +01:00
starkillerOG
f8ab4d0238 Fix warnings in Reolink tests (#140878) 2025-03-18 16:47:33 +01:00
starkillerOG
4564d2537b Fix flakey reolink test (#140877) 2025-03-18 17:38:34 +02:00
starkillerOG
18bd8b561a Add Reolink smart ai binary sensors (#140408)
* Add Crossline smart AI binary sensor

* Add intrusion, lingering, forgotten item, item taken detection

* Use unique_index instead of location for unique_id

* Add test

* Apply suggestions from code review

Co-authored-by: Abílio Costa <abmantis@users.noreply.github.com>

* Name changes

* Update homeassistant/components/reolink/binary_sensor.py

Co-authored-by: Abílio Costa <abmantis@users.noreply.github.com>

* Use smart_type instead of key

* Use occupancy translation instead of gas (point to the same thing).

* Revert "Use occupancy translation instead of gas (point to the same thing)."

This reverts commit 9caf796585.

* fix styling

---------

Co-authored-by: Abílio Costa <abmantis@users.noreply.github.com>
2025-03-17 14:49:13 +00:00
starkillerOG
b5fa3e74c0 Add option to specify Reolink Basic Service Port (#137603)
* Allow changing the baichuan port

* styling

* Add description

* Add tests

* Review feedback

* capital letters

Co-authored-by: Robert Resch <robert@resch.dev>

---------

Co-authored-by: Robert Resch <robert@resch.dev>
2025-03-16 19:51:06 +01:00
starkillerOG
9502dbee56 Add more diagnostic info to Reolink (#139436)
* Add diagnostic info

* Bump reolink-aio to 0.12.1

* Add tests
2025-02-27 19:39:01 +02:00
starkillerOG
92dd18a9be Ensure Reolink can start when privacy mode is enabled (#136514)
* Allow startup when privacy mode is enabled

* Add tests

* remove duplicate privacy_mode

* fix tests

* Apply suggestions from code review

Co-authored-by: Robert Resch <robert@resch.dev>

* Store in subfolder and cleanup when removed

* Add tests and fixes

* fix styling

* rename CONF_PRIVACY to CONF_SUPPORTS_PRIVACY_MODE

* use helper store

---------

Co-authored-by: Robert Resch <robert@resch.dev>
2025-01-31 13:48:47 -05:00
starkillerOG
17e12e6671 Prevent errors when Reolink privacy mode is turned on (#136506) 2025-01-26 22:44:15 +01:00
starkillerOG
76f065ce44 Fix Reolink firmware updates by uploading directly (#127007) 2024-11-15 10:41:23 +01:00
starkillerOG
a6189106e1 Reolink add TCP push event connection as primary method (#129490) 2024-10-30 14:34:32 +01:00
starkillerOG
85ae66d276 Reolink auto add new cameras/chimes (#126268) 2024-10-03 16:51:27 +02:00
starkillerOG
0f4c50e83c Mark Reolink camera entities as unavailable when camera is offline (#127127)
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2024-09-30 19:00:37 +02:00
starkillerOG
1395baef01 Remove Reolink Home Hub main level switches (#126697)
Co-authored-by: Robert Resch <robert@resch.dev>
2024-09-25 21:52:26 +02:00
starkillerOG
8ef7cae36d Speedup Reolink tests by using scope="module" (#125215)
* use scope="module"

* Instead of side_effect = None, use reset_mock(side_efffect=True)

* fix tests
2024-09-23 12:50:40 +02:00
starkillerOG
4b111008df Add 100% coverage of Reolink button platform (#124380)
* Add 100% button coverage

* review comments

* fix

* Use SERVICE_PRESS constant

* Use DOMAIN instead of const.DOMAIN

* styling

* User entity_registry_enabled_by_default fixture

* fixes

* Split out ptz_move test

* use SERVICE_PTZ_MOVE constant
2024-09-04 12:16:57 +02:00
starkillerOG
c4cfff4b3f Add 100% coverage of Reolink update platform (#124521)
* Add 100% update test coverage

* Add assertion
2024-09-03 22:50:00 +02:00
starkillerOG
a5bacf5652 Add 100% coverage of Reolink switch platform (#124482)
* Add 100% switch test coverage

* use DOMAIN instead of const.DOMAIN

* Split tests and use parametrize

* Revert "Split tests and use parametrize"

This reverts commit 50d2184ce6.

* fixes
2024-08-30 14:39:12 +02:00
starkillerOG
6589216ed3 Add 100% coverage of Reolink camera platform (#124381)
* Add 100% camera test coverage

* review comments

* use DOMAIN instead of const.DOMAIN

* use entity_registry_enabled_by_default fixture

* fixes
2024-08-30 14:34:49 +02:00
starkillerOG
0093276e93 Reolink add 100% coverage of binary_sensor platfrom (#123862)
* Implement 100% coverage of binary_sensor

* fix styling

* Apply suggestions from code review

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>

* use get().state instead of is_state

* Remove unneeded "is True"

* Remove unneeded "is True"

* reset the mock and use assert_not_called

* use freezer

* fix styling

* fix styling

---------

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
2024-08-16 12:46:51 +02:00
starkillerOG
2343f5e40f Reolink Chime online status and ability to remove (#123301)
* Add chime available

* allow removing a Reolink chime

* Allow removal if doorbell itself removed

* fix tests

* Add tests

* fix styling
2024-08-08 19:28:46 +02:00
starkillerOG
32cd54b1e3 Fix flaky Reolink tests (#122451) 2024-07-23 08:35:02 -05:00
Marc Mueller
f11b316dac Import Generator from collections.abc (4) (#120917) 2024-07-01 11:54:42 +02:00
starkillerOG
1b88448914 Do not wait for Reolink firmware check (#120377) 2024-06-26 09:34:45 +02:00
starkillerOG
8b4a5042bb Use UID instead of MAC or channel for unique_ID in Reolink (#119744) 2024-06-21 20:27:30 +02:00
starkillerOG
3a672642ea Reolink extend diagnostic data (#119745)
* Add diagnostic info

* fix

* change order

* update tests
2024-06-16 14:02:10 +02:00
starkillerOG
b8851f2f3c Cleanup Reolink firmware update entity (#119239) 2024-06-13 21:27:30 +02:00
Marc Mueller
837ee7c4fb Import Generator from typing_extensions (4) (#118992) 2024-06-06 17:41:37 +02:00
starkillerOG
8723441227 Add Reolink serial number to device info of IPC camera (#118834)
* Add UID to dev info

* Add camera_uid to test
2024-06-04 21:37:40 -04:00
epenet
c6e0e93680 Cleanup mock_get_source_ip from tests (#118459) 2024-05-30 09:37:01 +02: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
7d6251ca08 Add empty line after module docstring [tests q-s] (#112711) 2024-03-08 14:47:22 +01:00
J. Nick Koston
4627e8b1fc Fix formatting of mac addresses from dhcp discovery mocking in reolink (#110594)
dhcp returns addresses in lowercase without :
2024-02-14 21:39:30 +01:00
Joost Lekkerkerker
a82410d5e9 Deduplicate constants E-Z (#105657) 2023-12-13 17:05:37 +01:00
starkillerOG
9fa163c107 Reolink cleanup when CAM disconnected from NVR (#103888)
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2023-11-30 01:50:37 +01:00
starkillerOG
6b138a276a Add diagnostics platform to Reolink (#104378) 2023-11-23 12:55:21 +01:00
starkillerOG
a3c0f36592 Add Reolink serial number (#104383)
* Add Reolink serial number

* fix tests
2023-11-22 22:54:48 +01:00
starkillerOG
aea15ee20c Reolink add media browser for playback of recordings (#103407) 2023-11-21 23:43:56 +01:00
starkillerOG
9f6eef7cca Fix Reolink DHCP IP update (#103654) 2023-11-10 09:27:33 +01:00
starkillerOG
92cf6ed2a0 Reolink 100% test coverage (#94763) 2023-08-15 09:50:17 -05:00