From 2f6fcb5801561ccef77a1ea9087ae0bf8bf96b48 Mon Sep 17 00:00:00 2001 From: tronikos Date: Wed, 11 Jun 2025 09:35:26 -0700 Subject: [PATCH] Rename Amazon Devices to Alexa Devices (#146362) Co-authored-by: Simone Chemelli Co-authored-by: Joostlek --- .strict-typing | 2 +- CODEOWNERS | 4 ++-- homeassistant/brands/amazon.json | 2 +- .../{amazon_devices => alexa_devices}/__init__.py | 4 ++-- .../binary_sensor.py | 4 ++-- .../{amazon_devices => alexa_devices}/config_flow.py | 4 ++-- .../{amazon_devices => alexa_devices}/const.py | 4 ++-- .../{amazon_devices => alexa_devices}/coordinator.py | 4 ++-- .../{amazon_devices => alexa_devices}/diagnostics.py | 2 +- .../{amazon_devices => alexa_devices}/entity.py | 4 ++-- .../{amazon_devices => alexa_devices}/icons.json | 0 .../{amazon_devices => alexa_devices}/manifest.json | 6 +++--- .../{amazon_devices => alexa_devices}/notify.py | 4 ++-- .../quality_scale.yaml | 0 .../{amazon_devices => alexa_devices}/strings.json | 12 ++++++------ .../{amazon_devices => alexa_devices}/switch.py | 4 ++-- homeassistant/generated/config_flows.py | 2 +- homeassistant/generated/integrations.json | 4 ++-- mypy.ini | 4 ++-- requirements_all.txt | 2 +- requirements_test_all.txt | 2 +- .../{amazon_devices => alexa_devices}/__init__.py | 2 +- .../{amazon_devices => alexa_devices}/conftest.py | 12 ++++++------ .../{amazon_devices => alexa_devices}/const.py | 2 +- .../snapshots/test_binary_sensor.ambr | 4 ++-- .../snapshots/test_diagnostics.ambr | 2 +- .../snapshots/test_init.ambr | 2 +- .../snapshots/test_notify.ambr | 4 ++-- .../snapshots/test_switch.ambr | 2 +- .../test_binary_sensor.py | 6 +++--- .../test_config_flow.py | 4 ++-- .../test_diagnostics.py | 4 ++-- .../{amazon_devices => alexa_devices}/test_init.py | 4 ++-- .../{amazon_devices => alexa_devices}/test_notify.py | 6 +++--- .../{amazon_devices => alexa_devices}/test_switch.py | 6 +++--- 35 files changed, 67 insertions(+), 67 deletions(-) rename homeassistant/components/{amazon_devices => alexa_devices}/__init__.py (91%) rename homeassistant/components/{amazon_devices => alexa_devices}/binary_sensor.py (93%) rename homeassistant/components/{amazon_devices => alexa_devices}/config_flow.py (95%) rename homeassistant/components/{amazon_devices => alexa_devices}/const.py (60%) rename homeassistant/components/{amazon_devices => alexa_devices}/coordinator.py (95%) rename homeassistant/components/{amazon_devices => alexa_devices}/diagnostics.py (97%) rename homeassistant/components/{amazon_devices => alexa_devices}/entity.py (95%) rename homeassistant/components/{amazon_devices => alexa_devices}/icons.json (100%) rename homeassistant/components/{amazon_devices => alexa_devices}/manifest.json (79%) rename homeassistant/components/{amazon_devices => alexa_devices}/notify.py (94%) rename homeassistant/components/{amazon_devices => alexa_devices}/quality_scale.yaml (100%) rename homeassistant/components/{amazon_devices => alexa_devices}/strings.json (75%) rename homeassistant/components/{amazon_devices => alexa_devices}/switch.py (95%) rename tests/components/{amazon_devices => alexa_devices}/__init__.py (88%) rename tests/components/{amazon_devices => alexa_devices}/conftest.py (84%) rename tests/components/{amazon_devices => alexa_devices}/const.py (82%) rename tests/components/{amazon_devices => alexa_devices}/snapshots/test_binary_sensor.ambr (97%) rename tests/components/{amazon_devices => alexa_devices}/snapshots/test_diagnostics.ambr (98%) rename tests/components/{amazon_devices => alexa_devices}/snapshots/test_init.ambr (96%) rename tests/components/{amazon_devices => alexa_devices}/snapshots/test_notify.ambr (97%) rename tests/components/{amazon_devices => alexa_devices}/snapshots/test_switch.ambr (97%) rename tests/components/{amazon_devices => alexa_devices}/test_binary_sensor.py (92%) rename tests/components/{amazon_devices => alexa_devices}/test_config_flow.py (96%) rename tests/components/{amazon_devices => alexa_devices}/test_diagnostics.py (93%) rename tests/components/{amazon_devices => alexa_devices}/test_init.py (87%) rename tests/components/{amazon_devices => alexa_devices}/test_notify.py (92%) rename tests/components/{amazon_devices => alexa_devices}/test_switch.py (94%) diff --git a/.strict-typing b/.strict-typing index 4febfd68486..b34cbfa5fca 100644 --- a/.strict-typing +++ b/.strict-typing @@ -65,8 +65,8 @@ homeassistant.components.aladdin_connect.* homeassistant.components.alarm_control_panel.* homeassistant.components.alert.* homeassistant.components.alexa.* +homeassistant.components.alexa_devices.* homeassistant.components.alpha_vantage.* -homeassistant.components.amazon_devices.* homeassistant.components.amazon_polly.* homeassistant.components.amberelectric.* homeassistant.components.ambient_network.* diff --git a/CODEOWNERS b/CODEOWNERS index 3f3ce07ce84..b447c878128 100644 --- a/CODEOWNERS +++ b/CODEOWNERS @@ -89,8 +89,8 @@ build.json @home-assistant/supervisor /tests/components/alert/ @home-assistant/core @frenck /homeassistant/components/alexa/ @home-assistant/cloud @ochlocracy @jbouwh /tests/components/alexa/ @home-assistant/cloud @ochlocracy @jbouwh -/homeassistant/components/amazon_devices/ @chemelli74 -/tests/components/amazon_devices/ @chemelli74 +/homeassistant/components/alexa_devices/ @chemelli74 +/tests/components/alexa_devices/ @chemelli74 /homeassistant/components/amazon_polly/ @jschlyter /homeassistant/components/amberelectric/ @madpilot /tests/components/amberelectric/ @madpilot diff --git a/homeassistant/brands/amazon.json b/homeassistant/brands/amazon.json index d2e25468388..126b69c848d 100644 --- a/homeassistant/brands/amazon.json +++ b/homeassistant/brands/amazon.json @@ -3,7 +3,7 @@ "name": "Amazon", "integrations": [ "alexa", - "amazon_devices", + "alexa_devices", "amazon_polly", "aws", "aws_s3", diff --git a/homeassistant/components/amazon_devices/__init__.py b/homeassistant/components/alexa_devices/__init__.py similarity index 91% rename from homeassistant/components/amazon_devices/__init__.py rename to homeassistant/components/alexa_devices/__init__.py index 1db41d335ef..7a4139a65da 100644 --- a/homeassistant/components/amazon_devices/__init__.py +++ b/homeassistant/components/alexa_devices/__init__.py @@ -1,4 +1,4 @@ -"""Amazon Devices integration.""" +"""Alexa Devices integration.""" from homeassistant.const import Platform from homeassistant.core import HomeAssistant @@ -13,7 +13,7 @@ PLATFORMS = [ async def async_setup_entry(hass: HomeAssistant, entry: AmazonConfigEntry) -> bool: - """Set up Amazon Devices platform.""" + """Set up Alexa Devices platform.""" coordinator = AmazonDevicesCoordinator(hass, entry) diff --git a/homeassistant/components/amazon_devices/binary_sensor.py b/homeassistant/components/alexa_devices/binary_sensor.py similarity index 93% rename from homeassistant/components/amazon_devices/binary_sensor.py rename to homeassistant/components/alexa_devices/binary_sensor.py index ab1fadc7548..16cf73aee9f 100644 --- a/homeassistant/components/amazon_devices/binary_sensor.py +++ b/homeassistant/components/alexa_devices/binary_sensor.py @@ -26,7 +26,7 @@ PARALLEL_UPDATES = 0 @dataclass(frozen=True, kw_only=True) class AmazonBinarySensorEntityDescription(BinarySensorEntityDescription): - """Amazon Devices binary sensor entity description.""" + """Alexa Devices binary sensor entity description.""" is_on_fn: Callable[[AmazonDevice], bool] @@ -52,7 +52,7 @@ async def async_setup_entry( entry: AmazonConfigEntry, async_add_entities: AddConfigEntryEntitiesCallback, ) -> None: - """Set up Amazon Devices binary sensors based on a config entry.""" + """Set up Alexa Devices binary sensors based on a config entry.""" coordinator = entry.runtime_data diff --git a/homeassistant/components/amazon_devices/config_flow.py b/homeassistant/components/alexa_devices/config_flow.py similarity index 95% rename from homeassistant/components/amazon_devices/config_flow.py rename to homeassistant/components/alexa_devices/config_flow.py index d0c3d067cee..5add7ceb711 100644 --- a/homeassistant/components/amazon_devices/config_flow.py +++ b/homeassistant/components/alexa_devices/config_flow.py @@ -1,4 +1,4 @@ -"""Config flow for Amazon Devices integration.""" +"""Config flow for Alexa Devices integration.""" from __future__ import annotations @@ -17,7 +17,7 @@ from .const import CONF_LOGIN_DATA, DOMAIN class AmazonDevicesConfigFlow(ConfigFlow, domain=DOMAIN): - """Handle a config flow for Amazon Devices.""" + """Handle a config flow for Alexa Devices.""" async def async_step_user( self, user_input: dict[str, Any] | None = None diff --git a/homeassistant/components/amazon_devices/const.py b/homeassistant/components/alexa_devices/const.py similarity index 60% rename from homeassistant/components/amazon_devices/const.py rename to homeassistant/components/alexa_devices/const.py index b8cf2c264b1..ca0290a10bc 100644 --- a/homeassistant/components/amazon_devices/const.py +++ b/homeassistant/components/alexa_devices/const.py @@ -1,8 +1,8 @@ -"""Amazon Devices constants.""" +"""Alexa Devices constants.""" import logging _LOGGER = logging.getLogger(__package__) -DOMAIN = "amazon_devices" +DOMAIN = "alexa_devices" CONF_LOGIN_DATA = "login_data" diff --git a/homeassistant/components/amazon_devices/coordinator.py b/homeassistant/components/alexa_devices/coordinator.py similarity index 95% rename from homeassistant/components/amazon_devices/coordinator.py rename to homeassistant/components/alexa_devices/coordinator.py index 48e31cb3f94..8e58441d46c 100644 --- a/homeassistant/components/amazon_devices/coordinator.py +++ b/homeassistant/components/alexa_devices/coordinator.py @@ -1,4 +1,4 @@ -"""Support for Amazon Devices.""" +"""Support for Alexa Devices.""" from datetime import timedelta @@ -23,7 +23,7 @@ type AmazonConfigEntry = ConfigEntry[AmazonDevicesCoordinator] class AmazonDevicesCoordinator(DataUpdateCoordinator[dict[str, AmazonDevice]]): - """Base coordinator for Amazon Devices.""" + """Base coordinator for Alexa Devices.""" config_entry: AmazonConfigEntry diff --git a/homeassistant/components/amazon_devices/diagnostics.py b/homeassistant/components/alexa_devices/diagnostics.py similarity index 97% rename from homeassistant/components/amazon_devices/diagnostics.py rename to homeassistant/components/alexa_devices/diagnostics.py index e9a0773cd3f..0c4cb794416 100644 --- a/homeassistant/components/amazon_devices/diagnostics.py +++ b/homeassistant/components/alexa_devices/diagnostics.py @@ -1,4 +1,4 @@ -"""Diagnostics support for Amazon Devices integration.""" +"""Diagnostics support for Alexa Devices integration.""" from __future__ import annotations diff --git a/homeassistant/components/amazon_devices/entity.py b/homeassistant/components/alexa_devices/entity.py similarity index 95% rename from homeassistant/components/amazon_devices/entity.py rename to homeassistant/components/alexa_devices/entity.py index 962e2f55ae6..f539079602f 100644 --- a/homeassistant/components/amazon_devices/entity.py +++ b/homeassistant/components/alexa_devices/entity.py @@ -1,4 +1,4 @@ -"""Defines a base Amazon Devices entity.""" +"""Defines a base Alexa Devices entity.""" from aioamazondevices.api import AmazonDevice from aioamazondevices.const import SPEAKER_GROUP_MODEL @@ -12,7 +12,7 @@ from .coordinator import AmazonDevicesCoordinator class AmazonEntity(CoordinatorEntity[AmazonDevicesCoordinator]): - """Defines a base Amazon Devices entity.""" + """Defines a base Alexa Devices entity.""" _attr_has_entity_name = True diff --git a/homeassistant/components/amazon_devices/icons.json b/homeassistant/components/alexa_devices/icons.json similarity index 100% rename from homeassistant/components/amazon_devices/icons.json rename to homeassistant/components/alexa_devices/icons.json diff --git a/homeassistant/components/amazon_devices/manifest.json b/homeassistant/components/alexa_devices/manifest.json similarity index 79% rename from homeassistant/components/amazon_devices/manifest.json rename to homeassistant/components/alexa_devices/manifest.json index f63893c1598..2a9e88cfd85 100644 --- a/homeassistant/components/amazon_devices/manifest.json +++ b/homeassistant/components/alexa_devices/manifest.json @@ -1,9 +1,9 @@ { - "domain": "amazon_devices", - "name": "Amazon Devices", + "domain": "alexa_devices", + "name": "Alexa Devices", "codeowners": ["@chemelli74"], "config_flow": true, - "documentation": "https://www.home-assistant.io/integrations/amazon_devices", + "documentation": "https://www.home-assistant.io/integrations/alexa_devices", "integration_type": "hub", "iot_class": "cloud_polling", "loggers": ["aioamazondevices"], diff --git a/homeassistant/components/amazon_devices/notify.py b/homeassistant/components/alexa_devices/notify.py similarity index 94% rename from homeassistant/components/amazon_devices/notify.py rename to homeassistant/components/alexa_devices/notify.py index 3762a7a3264..ff0cd4e59ea 100644 --- a/homeassistant/components/amazon_devices/notify.py +++ b/homeassistant/components/alexa_devices/notify.py @@ -20,7 +20,7 @@ PARALLEL_UPDATES = 1 @dataclass(frozen=True, kw_only=True) class AmazonNotifyEntityDescription(NotifyEntityDescription): - """Amazon Devices notify entity description.""" + """Alexa Devices notify entity description.""" method: Callable[[AmazonEchoApi, AmazonDevice, str], Awaitable[None]] subkey: str @@ -49,7 +49,7 @@ async def async_setup_entry( entry: AmazonConfigEntry, async_add_entities: AddConfigEntryEntitiesCallback, ) -> None: - """Set up Amazon Devices notification entity based on a config entry.""" + """Set up Alexa Devices notification entity based on a config entry.""" coordinator = entry.runtime_data diff --git a/homeassistant/components/amazon_devices/quality_scale.yaml b/homeassistant/components/alexa_devices/quality_scale.yaml similarity index 100% rename from homeassistant/components/amazon_devices/quality_scale.yaml rename to homeassistant/components/alexa_devices/quality_scale.yaml diff --git a/homeassistant/components/amazon_devices/strings.json b/homeassistant/components/alexa_devices/strings.json similarity index 75% rename from homeassistant/components/amazon_devices/strings.json rename to homeassistant/components/alexa_devices/strings.json index 47e6234cd9c..9d615b248ed 100644 --- a/homeassistant/components/amazon_devices/strings.json +++ b/homeassistant/components/alexa_devices/strings.json @@ -12,16 +12,16 @@ "step": { "user": { "data": { - "country": "[%key:component::amazon_devices::common::data_country%]", + "country": "[%key:component::alexa_devices::common::data_country%]", "username": "[%key:common::config_flow::data::username%]", "password": "[%key:common::config_flow::data::password%]", - "code": "[%key:component::amazon_devices::common::data_description_code%]" + "code": "[%key:component::alexa_devices::common::data_description_code%]" }, "data_description": { - "country": "[%key:component::amazon_devices::common::data_description_country%]", - "username": "[%key:component::amazon_devices::common::data_description_username%]", - "password": "[%key:component::amazon_devices::common::data_description_password%]", - "code": "[%key:component::amazon_devices::common::data_description_code%]" + "country": "[%key:component::alexa_devices::common::data_description_country%]", + "username": "[%key:component::alexa_devices::common::data_description_username%]", + "password": "[%key:component::alexa_devices::common::data_description_password%]", + "code": "[%key:component::alexa_devices::common::data_description_code%]" } } }, diff --git a/homeassistant/components/amazon_devices/switch.py b/homeassistant/components/alexa_devices/switch.py similarity index 95% rename from homeassistant/components/amazon_devices/switch.py rename to homeassistant/components/alexa_devices/switch.py index 428ef3e3b45..b8f78134feb 100644 --- a/homeassistant/components/amazon_devices/switch.py +++ b/homeassistant/components/alexa_devices/switch.py @@ -20,7 +20,7 @@ PARALLEL_UPDATES = 1 @dataclass(frozen=True, kw_only=True) class AmazonSwitchEntityDescription(SwitchEntityDescription): - """Amazon Devices switch entity description.""" + """Alexa Devices switch entity description.""" is_on_fn: Callable[[AmazonDevice], bool] subkey: str @@ -43,7 +43,7 @@ async def async_setup_entry( entry: AmazonConfigEntry, async_add_entities: AddConfigEntryEntitiesCallback, ) -> None: - """Set up Amazon Devices switches based on a config entry.""" + """Set up Alexa Devices switches based on a config entry.""" coordinator = entry.runtime_data diff --git a/homeassistant/generated/config_flows.py b/homeassistant/generated/config_flows.py index 86f45c44fdc..119830b6111 100644 --- a/homeassistant/generated/config_flows.py +++ b/homeassistant/generated/config_flows.py @@ -47,7 +47,7 @@ FLOWS = { "airzone", "airzone_cloud", "alarmdecoder", - "amazon_devices", + "alexa_devices", "amberelectric", "ambient_network", "ambient_station", diff --git a/homeassistant/generated/integrations.json b/homeassistant/generated/integrations.json index dc46ddc6e16..ca527d117f1 100644 --- a/homeassistant/generated/integrations.json +++ b/homeassistant/generated/integrations.json @@ -207,11 +207,11 @@ "amazon": { "name": "Amazon", "integrations": { - "amazon_devices": { + "alexa_devices": { "integration_type": "hub", "config_flow": true, "iot_class": "cloud_polling", - "name": "Amazon Devices" + "name": "Alexa Devices" }, "amazon_polly": { "integration_type": "hub", diff --git a/mypy.ini b/mypy.ini index da76e4ae2cd..1fdab75663e 100644 --- a/mypy.ini +++ b/mypy.ini @@ -405,7 +405,7 @@ disallow_untyped_defs = true warn_return_any = true warn_unreachable = true -[mypy-homeassistant.components.alpha_vantage.*] +[mypy-homeassistant.components.alexa_devices.*] check_untyped_defs = true disallow_incomplete_defs = true disallow_subclassing_any = true @@ -415,7 +415,7 @@ disallow_untyped_defs = true warn_return_any = true warn_unreachable = true -[mypy-homeassistant.components.amazon_devices.*] +[mypy-homeassistant.components.alpha_vantage.*] check_untyped_defs = true disallow_incomplete_defs = true disallow_subclassing_any = true diff --git a/requirements_all.txt b/requirements_all.txt index c6deba07bcb..e18d8242071 100644 --- a/requirements_all.txt +++ b/requirements_all.txt @@ -181,7 +181,7 @@ aioairzone-cloud==0.6.12 # homeassistant.components.airzone aioairzone==1.0.0 -# homeassistant.components.amazon_devices +# homeassistant.components.alexa_devices aioamazondevices==3.0.6 # homeassistant.components.ambient_network diff --git a/requirements_test_all.txt b/requirements_test_all.txt index 7c38046a2a2..217ce5d97a0 100644 --- a/requirements_test_all.txt +++ b/requirements_test_all.txt @@ -169,7 +169,7 @@ aioairzone-cloud==0.6.12 # homeassistant.components.airzone aioairzone==1.0.0 -# homeassistant.components.amazon_devices +# homeassistant.components.alexa_devices aioamazondevices==3.0.6 # homeassistant.components.ambient_network diff --git a/tests/components/amazon_devices/__init__.py b/tests/components/alexa_devices/__init__.py similarity index 88% rename from tests/components/amazon_devices/__init__.py rename to tests/components/alexa_devices/__init__.py index 47ee520b124..24348248e0c 100644 --- a/tests/components/amazon_devices/__init__.py +++ b/tests/components/alexa_devices/__init__.py @@ -1,4 +1,4 @@ -"""Tests for the Amazon Devices integration.""" +"""Tests for the Alexa Devices integration.""" from homeassistant.core import HomeAssistant diff --git a/tests/components/amazon_devices/conftest.py b/tests/components/alexa_devices/conftest.py similarity index 84% rename from tests/components/amazon_devices/conftest.py rename to tests/components/alexa_devices/conftest.py index f0ee29d44e5..4ce2eb743ea 100644 --- a/tests/components/amazon_devices/conftest.py +++ b/tests/components/alexa_devices/conftest.py @@ -1,4 +1,4 @@ -"""Amazon Devices tests configuration.""" +"""Alexa Devices tests configuration.""" from collections.abc import Generator from unittest.mock import AsyncMock, patch @@ -7,7 +7,7 @@ from aioamazondevices.api import AmazonDevice from aioamazondevices.const import DEVICE_TYPE_TO_MODEL import pytest -from homeassistant.components.amazon_devices.const import CONF_LOGIN_DATA, DOMAIN +from homeassistant.components.alexa_devices.const import CONF_LOGIN_DATA, DOMAIN from homeassistant.const import CONF_COUNTRY, CONF_PASSWORD, CONF_USERNAME from .const import TEST_COUNTRY, TEST_PASSWORD, TEST_SERIAL_NUMBER, TEST_USERNAME @@ -19,7 +19,7 @@ from tests.common import MockConfigEntry def mock_setup_entry() -> Generator[AsyncMock]: """Override async_setup_entry.""" with patch( - "homeassistant.components.amazon_devices.async_setup_entry", + "homeassistant.components.alexa_devices.async_setup_entry", return_value=True, ) as mock_setup_entry: yield mock_setup_entry @@ -27,14 +27,14 @@ def mock_setup_entry() -> Generator[AsyncMock]: @pytest.fixture def mock_amazon_devices_client() -> Generator[AsyncMock]: - """Mock an Amazon Devices client.""" + """Mock an Alexa Devices client.""" with ( patch( - "homeassistant.components.amazon_devices.coordinator.AmazonEchoApi", + "homeassistant.components.alexa_devices.coordinator.AmazonEchoApi", autospec=True, ) as mock_client, patch( - "homeassistant.components.amazon_devices.config_flow.AmazonEchoApi", + "homeassistant.components.alexa_devices.config_flow.AmazonEchoApi", new=mock_client, ), ): diff --git a/tests/components/amazon_devices/const.py b/tests/components/alexa_devices/const.py similarity index 82% rename from tests/components/amazon_devices/const.py rename to tests/components/alexa_devices/const.py index a2600ba98a6..8a2f5b6b158 100644 --- a/tests/components/amazon_devices/const.py +++ b/tests/components/alexa_devices/const.py @@ -1,4 +1,4 @@ -"""Amazon Devices tests const.""" +"""Alexa Devices tests const.""" TEST_CODE = "023123" TEST_COUNTRY = "IT" diff --git a/tests/components/amazon_devices/snapshots/test_binary_sensor.ambr b/tests/components/alexa_devices/snapshots/test_binary_sensor.ambr similarity index 97% rename from tests/components/amazon_devices/snapshots/test_binary_sensor.ambr rename to tests/components/alexa_devices/snapshots/test_binary_sensor.ambr index e914541d19c..16f9eeaedae 100644 --- a/tests/components/amazon_devices/snapshots/test_binary_sensor.ambr +++ b/tests/components/alexa_devices/snapshots/test_binary_sensor.ambr @@ -25,7 +25,7 @@ 'original_device_class': None, 'original_icon': None, 'original_name': 'Bluetooth', - 'platform': 'amazon_devices', + 'platform': 'alexa_devices', 'previous_unique_id': None, 'suggested_object_id': None, 'supported_features': 0, @@ -73,7 +73,7 @@ 'original_device_class': , 'original_icon': None, 'original_name': 'Connectivity', - 'platform': 'amazon_devices', + 'platform': 'alexa_devices', 'previous_unique_id': None, 'suggested_object_id': None, 'supported_features': 0, diff --git a/tests/components/amazon_devices/snapshots/test_diagnostics.ambr b/tests/components/alexa_devices/snapshots/test_diagnostics.ambr similarity index 98% rename from tests/components/amazon_devices/snapshots/test_diagnostics.ambr rename to tests/components/alexa_devices/snapshots/test_diagnostics.ambr index 0b5164418aa..95798fca817 100644 --- a/tests/components/amazon_devices/snapshots/test_diagnostics.ambr +++ b/tests/components/alexa_devices/snapshots/test_diagnostics.ambr @@ -57,7 +57,7 @@ 'disabled_by': None, 'discovery_keys': dict({ }), - 'domain': 'amazon_devices', + 'domain': 'alexa_devices', 'minor_version': 1, 'options': dict({ }), diff --git a/tests/components/amazon_devices/snapshots/test_init.ambr b/tests/components/alexa_devices/snapshots/test_init.ambr similarity index 96% rename from tests/components/amazon_devices/snapshots/test_init.ambr rename to tests/components/alexa_devices/snapshots/test_init.ambr index be0a5894eea..e0460c4c173 100644 --- a/tests/components/amazon_devices/snapshots/test_init.ambr +++ b/tests/components/alexa_devices/snapshots/test_init.ambr @@ -13,7 +13,7 @@ 'id': , 'identifiers': set({ tuple( - 'amazon_devices', + 'alexa_devices', 'echo_test_serial_number', ), }), diff --git a/tests/components/amazon_devices/snapshots/test_notify.ambr b/tests/components/alexa_devices/snapshots/test_notify.ambr similarity index 97% rename from tests/components/amazon_devices/snapshots/test_notify.ambr rename to tests/components/alexa_devices/snapshots/test_notify.ambr index a47bf7a63ae..64776c14420 100644 --- a/tests/components/amazon_devices/snapshots/test_notify.ambr +++ b/tests/components/alexa_devices/snapshots/test_notify.ambr @@ -25,7 +25,7 @@ 'original_device_class': None, 'original_icon': None, 'original_name': 'Announce', - 'platform': 'amazon_devices', + 'platform': 'alexa_devices', 'previous_unique_id': None, 'suggested_object_id': None, 'supported_features': 0, @@ -74,7 +74,7 @@ 'original_device_class': None, 'original_icon': None, 'original_name': 'Speak', - 'platform': 'amazon_devices', + 'platform': 'alexa_devices', 'previous_unique_id': None, 'suggested_object_id': None, 'supported_features': 0, diff --git a/tests/components/amazon_devices/snapshots/test_switch.ambr b/tests/components/alexa_devices/snapshots/test_switch.ambr similarity index 97% rename from tests/components/amazon_devices/snapshots/test_switch.ambr rename to tests/components/alexa_devices/snapshots/test_switch.ambr index 8a2ce8d529a..c622cc67ea7 100644 --- a/tests/components/amazon_devices/snapshots/test_switch.ambr +++ b/tests/components/alexa_devices/snapshots/test_switch.ambr @@ -25,7 +25,7 @@ 'original_device_class': None, 'original_icon': None, 'original_name': 'Do not disturb', - 'platform': 'amazon_devices', + 'platform': 'alexa_devices', 'previous_unique_id': None, 'suggested_object_id': None, 'supported_features': 0, diff --git a/tests/components/amazon_devices/test_binary_sensor.py b/tests/components/alexa_devices/test_binary_sensor.py similarity index 92% rename from tests/components/amazon_devices/test_binary_sensor.py rename to tests/components/alexa_devices/test_binary_sensor.py index b31d85e06aa..a2e38b3459b 100644 --- a/tests/components/amazon_devices/test_binary_sensor.py +++ b/tests/components/alexa_devices/test_binary_sensor.py @@ -1,4 +1,4 @@ -"""Tests for the Amazon Devices binary sensor platform.""" +"""Tests for the Alexa Devices binary sensor platform.""" from unittest.mock import AsyncMock, patch @@ -11,7 +11,7 @@ from freezegun.api import FrozenDateTimeFactory import pytest from syrupy.assertion import SnapshotAssertion -from homeassistant.components.amazon_devices.coordinator import SCAN_INTERVAL +from homeassistant.components.alexa_devices.coordinator import SCAN_INTERVAL from homeassistant.const import STATE_ON, STATE_UNAVAILABLE, Platform from homeassistant.core import HomeAssistant from homeassistant.helpers import entity_registry as er @@ -31,7 +31,7 @@ async def test_all_entities( ) -> None: """Test all entities.""" with patch( - "homeassistant.components.amazon_devices.PLATFORMS", [Platform.BINARY_SENSOR] + "homeassistant.components.alexa_devices.PLATFORMS", [Platform.BINARY_SENSOR] ): await setup_integration(hass, mock_config_entry) diff --git a/tests/components/amazon_devices/test_config_flow.py b/tests/components/alexa_devices/test_config_flow.py similarity index 96% rename from tests/components/amazon_devices/test_config_flow.py rename to tests/components/alexa_devices/test_config_flow.py index ce1ac44d102..9bf174c5955 100644 --- a/tests/components/amazon_devices/test_config_flow.py +++ b/tests/components/alexa_devices/test_config_flow.py @@ -1,11 +1,11 @@ -"""Tests for the Amazon Devices config flow.""" +"""Tests for the Alexa Devices config flow.""" from unittest.mock import AsyncMock from aioamazondevices.exceptions import CannotAuthenticate, CannotConnect import pytest -from homeassistant.components.amazon_devices.const import CONF_LOGIN_DATA, DOMAIN +from homeassistant.components.alexa_devices.const import CONF_LOGIN_DATA, DOMAIN from homeassistant.config_entries import SOURCE_USER from homeassistant.const import CONF_CODE, CONF_COUNTRY, CONF_PASSWORD, CONF_USERNAME from homeassistant.core import HomeAssistant diff --git a/tests/components/amazon_devices/test_diagnostics.py b/tests/components/alexa_devices/test_diagnostics.py similarity index 93% rename from tests/components/amazon_devices/test_diagnostics.py rename to tests/components/alexa_devices/test_diagnostics.py index e548702650b..3c18d432543 100644 --- a/tests/components/amazon_devices/test_diagnostics.py +++ b/tests/components/alexa_devices/test_diagnostics.py @@ -1,4 +1,4 @@ -"""Tests for Amazon Devices diagnostics platform.""" +"""Tests for Alexa Devices diagnostics platform.""" from __future__ import annotations @@ -7,7 +7,7 @@ from unittest.mock import AsyncMock from syrupy.assertion import SnapshotAssertion from syrupy.filters import props -from homeassistant.components.amazon_devices.const import DOMAIN +from homeassistant.components.alexa_devices.const import DOMAIN from homeassistant.core import HomeAssistant from homeassistant.helpers import device_registry as dr diff --git a/tests/components/amazon_devices/test_init.py b/tests/components/alexa_devices/test_init.py similarity index 87% rename from tests/components/amazon_devices/test_init.py rename to tests/components/alexa_devices/test_init.py index 489952dbd4c..3100cfe5fa9 100644 --- a/tests/components/amazon_devices/test_init.py +++ b/tests/components/alexa_devices/test_init.py @@ -1,10 +1,10 @@ -"""Tests for the Amazon Devices integration.""" +"""Tests for the Alexa Devices integration.""" from unittest.mock import AsyncMock from syrupy.assertion import SnapshotAssertion -from homeassistant.components.amazon_devices.const import DOMAIN +from homeassistant.components.alexa_devices.const import DOMAIN from homeassistant.core import HomeAssistant from homeassistant.helpers import device_registry as dr diff --git a/tests/components/amazon_devices/test_notify.py b/tests/components/alexa_devices/test_notify.py similarity index 92% rename from tests/components/amazon_devices/test_notify.py rename to tests/components/alexa_devices/test_notify.py index b486380fd07..6067874e370 100644 --- a/tests/components/amazon_devices/test_notify.py +++ b/tests/components/alexa_devices/test_notify.py @@ -1,4 +1,4 @@ -"""Tests for the Amazon Devices notify platform.""" +"""Tests for the Alexa Devices notify platform.""" from unittest.mock import AsyncMock, patch @@ -6,7 +6,7 @@ from freezegun.api import FrozenDateTimeFactory import pytest from syrupy.assertion import SnapshotAssertion -from homeassistant.components.amazon_devices.coordinator import SCAN_INTERVAL +from homeassistant.components.alexa_devices.coordinator import SCAN_INTERVAL from homeassistant.components.notify import ( ATTR_MESSAGE, DOMAIN as NOTIFY_DOMAIN, @@ -32,7 +32,7 @@ async def test_all_entities( entity_registry: er.EntityRegistry, ) -> None: """Test all entities.""" - with patch("homeassistant.components.amazon_devices.PLATFORMS", [Platform.NOTIFY]): + with patch("homeassistant.components.alexa_devices.PLATFORMS", [Platform.NOTIFY]): await setup_integration(hass, mock_config_entry) await snapshot_platform(hass, entity_registry, snapshot, mock_config_entry.entry_id) diff --git a/tests/components/amazon_devices/test_switch.py b/tests/components/alexa_devices/test_switch.py similarity index 94% rename from tests/components/amazon_devices/test_switch.py rename to tests/components/alexa_devices/test_switch.py index 24af96db280..26a18fb731a 100644 --- a/tests/components/amazon_devices/test_switch.py +++ b/tests/components/alexa_devices/test_switch.py @@ -1,4 +1,4 @@ -"""Tests for the Amazon Devices switch platform.""" +"""Tests for the Alexa Devices switch platform.""" from unittest.mock import AsyncMock, patch @@ -6,7 +6,7 @@ from freezegun.api import FrozenDateTimeFactory import pytest from syrupy.assertion import SnapshotAssertion -from homeassistant.components.amazon_devices.coordinator import SCAN_INTERVAL +from homeassistant.components.alexa_devices.coordinator import SCAN_INTERVAL from homeassistant.components.switch import ( DOMAIN as SWITCH_DOMAIN, SERVICE_TURN_OFF, @@ -37,7 +37,7 @@ async def test_all_entities( entity_registry: er.EntityRegistry, ) -> None: """Test all entities.""" - with patch("homeassistant.components.amazon_devices.PLATFORMS", [Platform.SWITCH]): + with patch("homeassistant.components.alexa_devices.PLATFORMS", [Platform.SWITCH]): await setup_integration(hass, mock_config_entry) await snapshot_platform(hass, entity_registry, snapshot, mock_config_entry.entry_id)