Prevent errors when Reolink privacy mode is turned on (#136506)

This commit is contained in:
starkillerOG
2025-01-26 22:44:15 +01:00
committed by GitHub
parent 3e0f6562c7
commit 17e12e6671
5 changed files with 179 additions and 14 deletions

View File

@@ -126,6 +126,7 @@ def reolink_connect_class() -> Generator[MagicMock]:
host_mock.baichuan = create_autospec(Baichuan)
# Disable tcp push by default for tests
host_mock.baichuan.events_active = False
host_mock.baichuan.privacy_mode.return_value = False
host_mock.baichuan.subscribe_events.side_effect = ReolinkError("Test error")
yield host_mock_class