diff --git a/homeassistant/components/ecovacs/manifest.json b/homeassistant/components/ecovacs/manifest.json index 819f1db2f69..61bd425b139 100644 --- a/homeassistant/components/ecovacs/manifest.json +++ b/homeassistant/components/ecovacs/manifest.json @@ -6,5 +6,5 @@ "documentation": "https://www.home-assistant.io/integrations/ecovacs", "iot_class": "cloud_push", "loggers": ["sleekxmppfs", "sucks", "deebot_client"], - "requirements": ["py-sucks==0.9.9", "deebot-client==5.1.1"] + "requirements": ["py-sucks==0.9.9", "deebot-client==5.2.1"] } diff --git a/requirements_all.txt b/requirements_all.txt index b2c4414f20e..345ad934475 100644 --- a/requirements_all.txt +++ b/requirements_all.txt @@ -696,7 +696,7 @@ debugpy==1.8.1 # decora==0.6 # homeassistant.components.ecovacs -deebot-client==5.1.1 +deebot-client==5.2.1 # homeassistant.components.ihc # homeassistant.components.namecheapdns diff --git a/requirements_test_all.txt b/requirements_test_all.txt index 049a89ee4d9..45164010ac0 100644 --- a/requirements_test_all.txt +++ b/requirements_test_all.txt @@ -571,7 +571,7 @@ dbus-fast==2.21.1 debugpy==1.8.1 # homeassistant.components.ecovacs -deebot-client==5.1.1 +deebot-client==5.2.1 # homeassistant.components.ihc # homeassistant.components.namecheapdns diff --git a/tests/components/ecovacs/conftest.py b/tests/components/ecovacs/conftest.py index d0f0668cc8c..31d7246e6bc 100644 --- a/tests/components/ecovacs/conftest.py +++ b/tests/components/ecovacs/conftest.py @@ -3,7 +3,7 @@ from collections.abc import Generator from typing import Any from unittest.mock import AsyncMock, Mock, patch -from deebot_client.const import PATH_API_APPSVR_APP +from deebot_client import const from deebot_client.device import Device from deebot_client.exceptions import ApiError from deebot_client.models import Credentials @@ -75,9 +75,13 @@ def mock_authenticator(device_fixture: str) -> Generator[Mock, None, None]: query_params: dict[str, Any] | None = None, headers: dict[str, Any] | None = None, ) -> dict[str, Any]: - if path == PATH_API_APPSVR_APP: - return {"code": 0, "devices": devices, "errno": "0"} - raise ApiError("Path not mocked: {path}") + match path: + case const.PATH_API_APPSVR_APP: + return {"code": 0, "devices": devices, "errno": "0"} + case const.PATH_API_USERS_USER: + return {"todo": "result", "result": "ok", "devices": devices} + case _: + raise ApiError("Path not mocked: {path}") authenticator.post_authenticated.side_effect = post_authenticated yield authenticator