From c71bab263899e74403a190e14fc2822cae73f010 Mon Sep 17 00:00:00 2001 From: Johnny Willemsen Date: Mon, 14 Oct 2024 10:03:01 +0200 Subject: [PATCH 1/3] Add a test json with minimal data from the onecta app, extended some helpers to handle the missing data * tests/fixtures/minimal_data.json: Added. * custom_components/daikin_onecta/climate.py: * custom_components/daikin_onecta/sensor.py: * custom_components/daikin_onecta/water_heater.py: * tests/snapshots/test_init.ambr: * tests/test_init.py: --- custom_components/daikin_onecta/climate.py | 6 +- custom_components/daikin_onecta/sensor.py | 58 +- .../daikin_onecta/water_heater.py | 12 +- tests/fixtures/minimal_data.json | 530 +++++ tests/snapshots/test_init.ambr | 2055 +++++++++++++++++ tests/test_init.py | 12 + 6 files changed, 2638 insertions(+), 35 deletions(-) create mode 100644 tests/fixtures/minimal_data.json diff --git a/custom_components/daikin_onecta/climate.py b/custom_components/daikin_onecta/climate.py index 025dfdf..7db958c 100644 --- a/custom_components/daikin_onecta/climate.py +++ b/custom_components/daikin_onecta/climate.py @@ -345,8 +345,10 @@ def get_hvac_mode(self): mode = HVACMode.OFF operationmode = self.operation_mode() cc = self.climate_control() - if cc["onOffMode"]["value"] != "off": - mode = operationmode["value"] + onoff = cc.get("onOffMode") + if onoff is not None: + if onoff["value"] != "off": + mode = operationmode["value"] return DAIKIN_HVAC_TO_HA.get(mode, HVACMode.HEAT_COOL) def get_hvac_modes(self): diff --git a/custom_components/daikin_onecta/sensor.py b/custom_components/daikin_onecta/sensor.py index a1ccbef..0470550 100644 --- a/custom_components/daikin_onecta/sensor.py +++ b/custom_components/daikin_onecta/sensor.py @@ -108,39 +108,41 @@ async def async_setup_entry(hass, config_entry, async_add_entities): if cd is not None: # Retrieve the available operationModes, we can only provide consumption data for # supported operation modes - operation_modes = management_point["operationMode"]["values"] - cdv = cd.get("value") - if cdv is not None: - cdve = cdv.get("electrical") - if cdve is not None: - _LOGGER.info("Device '%s' provides electrical", device.name) - for mode in cdve: - # Only handle consumptionData for an operation mode supported by this device - if mode in operation_modes: - _LOGGER.info( - "Device '%s' provides mode %s %s", - device.name, - management_point_type, - mode, - ) - for period in cdve[mode]: + opmode = management_point.get("operationMode") + if opmode is not None: + operation_modes = opmode["values"] + cdv = cd.get("value") + if cdv is not None: + cdve = cdv.get("electrical") + if cdve is not None: + _LOGGER.info("Device '%s' provides electrical", device.name) + for mode in cdve: + # Only handle consumptionData for an operation mode supported by this device + if mode in operation_modes: _LOGGER.info( - "Device '%s:%s' provides mode %s %s supports period %s", + "Device '%s' provides mode %s %s", device.name, - embedded_id, management_point_type, mode, - period, ) - periodName = SENSOR_PERIODS[period] - sensor = f"{device.name} {management_point_type} {mode} {periodName}" - _LOGGER.info("Proposing sensor '%s'", sensor) - sensors.append(DaikinEnergySensor(device, coordinator, embedded_id, management_point_type, mode, period)) - else: - _LOGGER.info( - "Ignoring consumption data '%s', not a supported operation_mode", - mode, - ) + for period in cdve[mode]: + _LOGGER.info( + "Device '%s:%s' provides mode %s %s supports period %s", + device.name, + embedded_id, + management_point_type, + mode, + period, + ) + periodName = SENSOR_PERIODS[period] + sensor = f"{device.name} {management_point_type} {mode} {periodName}" + _LOGGER.info("Proposing sensor '%s'", sensor) + sensors.append(DaikinEnergySensor(device, coordinator, embedded_id, management_point_type, mode, period)) + else: + _LOGGER.info( + "Ignoring consumption data '%s', not a supported operation_mode", + mode, + ) async_add_entities(sensors) diff --git a/custom_components/daikin_onecta/water_heater.py b/custom_components/daikin_onecta/water_heater.py index 0234b25..036f3af 100644 --- a/custom_components/daikin_onecta/water_heater.py +++ b/custom_components/daikin_onecta/water_heater.py @@ -89,11 +89,13 @@ def hotwatertank_data(self): def domestic_hotwater_temperature(self): # Find the json dictionary for controlling the hot water temperature dht = None - temp_control = self.hotwatertank_data["temperatureControl"]["value"] - if temp_control: - heating_mode = temp_control["operationModes"]["heating"] - if heating_mode is not None: - dht = heating_mode["setpoints"]["domesticHotWaterTemperature"] + tc = self.hotwatertank_data.get("temperatureControl") + if tc is not None: + temp_control = tc["value"] + if temp_control: + heating_mode = temp_control["operationModes"]["heating"] + if heating_mode is not None: + dht = heating_mode["setpoints"]["domesticHotWaterTemperature"] return dht def get_supported_features(self): diff --git a/tests/fixtures/minimal_data.json b/tests/fixtures/minimal_data.json new file mode 100644 index 0000000..fb351ab --- /dev/null +++ b/tests/fixtures/minimal_data.json @@ -0,0 +1,530 @@ +[ +{ + "_id": "b84e8af3-310a-4e6e-8e52-295573423485", + "deviceModel": "Altherma", + "embeddedId": "c50ad019-9f1e-4334-9043-c4b5bfd020a5", + "id": "b84e8af3-310a-4e6e-8e52-295573423485", + "isCloudConnectionUp": { + "settable": false, + "value": true + }, + "managementPoints": [ + { + "embeddedId": "gateway", + "managementPointType": "gateway", + "managementPointCategory": "secondary", + "ipAddress": { + "settable": false, + "value": "192.168.2.13", + "maxLength": 15 + }, + "isFirmwareUpdateSupported": { + "settable": false, + "requiresReboot": false, + "value": false + }, + "modelInfo": { + "settable": false, + "value": "BRP069A78", + "maxLength": 9 + }, + "name": { + "settable": false, + "requiresReboot": false, + "value": "Gateway", + "maxLength": 63 + } + }, + { + "embeddedId": "climateControlMainZone", + "managementPointType": "climateControl", + "managementPointCategory": "primary", + "managementPointSubType": "mainZone", + "consumptionData": { + "settable": false, + "requiresReboot": false, + "ref": "#consumptionData", + "value": { + "electrical": { + "heating": { + "d": [ + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + null, + null, + null + ], + "w": [ + 5, + 2, + 4, + 3, + 4, + 7, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0 + ], + "m": [ + 504, + 355, + 343, + 181, + 16, + 0, + 0, + 0, + 0, + 56, + 285, + 421, + 755, + 198, + 143, + 112, + 0, + 0, + 0, + 0, + 15, + 20, + null, + null + ] + }, + "cooling": { + "d": [ + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + null, + null, + null + ], + "w": [ + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0 + ], + "m": [ + 0, + 0, + 0, + 0, + 20, + 163, + 90, + 99, + 103, + 23, + 0, + 0, + 0, + 0, + 0, + 8, + 53, + 75, + 120, + 146, + 45, + 0, + null, + null + ] + } + } + } + }, + "controlMode": { + "settable": false, + "requiresReboot": false, + "value": "roomTemperature", + "values": [ + "leavingWaterTemperature", + "externalRoomTemperature", + "roomTemperature" + ] + }, + "isHolidayModeActive": { + "settable": false, + "requiresReboot": false, + "value": false + }, + "isInEmergencyState": { + "settable": false, + "requiresReboot": false, + "value": false + }, + "isInErrorState": { + "settable": false, + "requiresReboot": false, + "value": false + }, + "isInInstallerState": { + "settable": false, + "requiresReboot": false, + "value": false + }, + "name": { + "settable": false, + "requiresReboot": false, + "value": "", + "maxLength": 63 + }, + "operationMode": { + "settable": true, + "requiresReboot": false, + "value": "auto", + "values": [ + "heating", + "cooling", + "auto" + ] + }, + "sensoryData": { + "settable": false, + "ref": "#sensoryData", + "value": { + "leavingWaterTemperature": { + "settable": false, + "requiresReboot": false, + "value": 26, + "maxValue": 127, + "minValue": -127, + "stepValue": 1 + }, + "outdoorTemperature": { + "settable": false, + "requiresReboot": false, + "value": 9, + "maxValue": 127, + "minValue": -127, + "stepValue": 1 + }, + "roomTemperature": { + "settable": false, + "requiresReboot": false, + "value": 21.2, + "maxValue": 127, + "minValue": -127, + "stepValue": 0.1 + } + } + }, + "setpointMode": { + "settable": false, + "requiresReboot": true, + "value": "fixed", + "values": [ + "fixed", + "weatherDependentHeatingFixedCooling", + "weatherDependent" + ] + }, + "temperatureControl": { + "settable": true, + "ref": "#temperatureControl", + "value": { + "operationModes": { + "auto": { + "setpoints": { + "roomTemperature": { + "settable": true, + "requiresReboot": false, + "value": 22, + "maxValue": 30, + "minValue": 12, + "stepValue": 0.5 + } + } + }, + "cooling": { + "setpoints": { + "leavingWaterTemperature": { + "settable": true, + "requiresReboot": false, + "value": 18, + "maxValue": 22, + "minValue": 18, + "stepValue": 1 + }, + "roomTemperature": { + "settable": true, + "requiresReboot": false, + "value": 22, + "maxValue": 35, + "minValue": 15, + "stepValue": 0.5 + } + } + }, + "heating": { + "setpoints": { + "leavingWaterTemperature": { + "settable": true, + "requiresReboot": false, + "value": 35, + "maxValue": 55, + "minValue": 25, + "stepValue": 1 + }, + "roomTemperature": { + "settable": true, + "requiresReboot": false, + "value": 22, + "maxValue": 30, + "minValue": 12, + "stepValue": 0.5 + } + } + } + } + } + } + }, + { + "embeddedId": "domesticHotWaterTank", + "managementPointType": "domesticHotWaterTank", + "managementPointCategory": "primary", + "consumptionData": { + "settable": false, + "requiresReboot": false, + "ref": "#consumptionData", + "value": { + "electrical": { + "heating": { + "d": [ + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 2, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 1, + 0, + 0, + 3, + 0, + null, + null, + null + ], + "w": [ + 6, + 8, + 4, + 8, + 4, + 7, + 5, + 2, + 3, + 3, + 3, + 5, + 2, + 4 + ], + "m": [ + 151, + 126, + 147, + 124, + 131, + 97, + 116, + 116, + 126, + 150, + 152, + 155, + 143, + 143, + 132, + 107, + 146, + 137, + 113, + 104, + 149, + 58, + null, + null + ] + } + } + } + }, + "heatupMode": { + "settable": false, + "requiresReboot": true, + "value": "reheatOnly", + "values": [ + "reheatOnly", + "reheatSchedule", + "scheduleOnly" + ] + }, + "isHolidayModeActive": { + "settable": false, + "requiresReboot": false, + "value": false + }, + "isInErrorState": { + "settable": false, + "requiresReboot": false, + "value": false + }, + "isInInstallerState": { + "settable": false, + "requiresReboot": false, + "value": false + }, + "name": { + "settable": false, + "requiresReboot": false, + "value": "", + "maxLength": 63 + }, + "onOffMode": { + "settable": true, + "requiresReboot": false, + "value": "on", + "values": [ + "off", + "on" + ] + }, + "sensoryData": { + "settable": false, + "ref": "#sensoryData", + "value": { + "tankTemperature": { + "settable": false, + "requiresReboot": false, + "value": 53, + "maxValue": 127, + "minValue": -127, + "stepValue": 1 + } + } + }, + "setpointMode": { + "settable": false, + "requiresReboot": false, + "value": "fixed", + "values": [ + "fixed", + "weatherDependent" + ] + } + }, + { + "embeddedId": "indoorUnitHydro", + "managementPointType": "indoorUnitHydro", + "managementPointCategory": "secondary", + "modelInfo": { + "settable": false, + "requiresReboot": false, + "value": "EHVX08S18EJ6V", + "maxLength": 16 + }, + "name": { + "settable": false, + "requiresReboot": false, + "value": "Indoor Hydro Unit", + "maxLength": 63 + } + }, + { + "embeddedId": "userInterface", + "managementPointType": "userInterface", + "managementPointCategory": "secondary", + "modelInfo": { + "settable": false, + "requiresReboot": false, + "value": "EHVX08S18EJ6V", + "maxLength": 16 + }, + "name": { + "settable": false, + "requiresReboot": false, + "value": "User Interface", + "maxLength": 63 + }, + "softwareVersion": { + "settable": false, + "requiresReboot": false, + "value": "7.5.0", + "maxLength": 16 + } + } + ], + "timestamp": "2024-10-13T17:25:54.132Z", + "type": "heating-wlan" + } +] diff --git a/tests/snapshots/test_init.ambr b/tests/snapshots/test_init.ambr index d9db4ea..c2abadf 100644 --- a/tests/snapshots/test_init.ambr +++ b/tests/snapshots/test_init.ambr @@ -76260,6 +76260,2061 @@ 'state': 'heat_pump', }) # --- +# name: test_minimal_data[binary_sensor.altherma_climatecontrol_is_holiday_mode_active-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': None, + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'binary_sensor', + 'entity_category': , + 'entity_id': 'binary_sensor.altherma_climatecontrol_is_holiday_mode_active', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:information-outline', + 'original_name': 'ClimateControl Is Holiday Mode Active', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'climatecontrol_isholidaymodeactive', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_climateControl_None_isHolidayModeActive', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[binary_sensor.altherma_climatecontrol_is_holiday_mode_active-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma ClimateControl Is Holiday Mode Active', + 'icon': 'mdi:information-outline', + }), + 'context': , + 'entity_id': 'binary_sensor.altherma_climatecontrol_is_holiday_mode_active', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': 'off', + }) +# --- +# name: test_minimal_data[binary_sensor.altherma_climatecontrol_is_in_emergency_state-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': None, + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'binary_sensor', + 'entity_category': , + 'entity_id': 'binary_sensor.altherma_climatecontrol_is_in_emergency_state', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': , + 'original_icon': 'mdi:information-outline', + 'original_name': 'ClimateControl Is In Emergency State', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'climatecontrol_isinemergencystate', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_climateControl_None_isInEmergencyState', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[binary_sensor.altherma_climatecontrol_is_in_emergency_state-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'device_class': 'problem', + 'friendly_name': 'Altherma ClimateControl Is In Emergency State', + 'icon': 'mdi:information-outline', + }), + 'context': , + 'entity_id': 'binary_sensor.altherma_climatecontrol_is_in_emergency_state', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': 'off', + }) +# --- +# name: test_minimal_data[binary_sensor.altherma_climatecontrol_is_in_error_state-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': None, + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'binary_sensor', + 'entity_category': , + 'entity_id': 'binary_sensor.altherma_climatecontrol_is_in_error_state', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': , + 'original_icon': 'mdi:information-outline', + 'original_name': 'ClimateControl Is In Error State', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'climatecontrol_isinerrorstate', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_climateControl_None_isInErrorState', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[binary_sensor.altherma_climatecontrol_is_in_error_state-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'device_class': 'problem', + 'friendly_name': 'Altherma ClimateControl Is In Error State', + 'icon': 'mdi:information-outline', + }), + 'context': , + 'entity_id': 'binary_sensor.altherma_climatecontrol_is_in_error_state', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': 'off', + }) +# --- +# name: test_minimal_data[binary_sensor.altherma_climatecontrol_is_in_installer_state-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': None, + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'binary_sensor', + 'entity_category': , + 'entity_id': 'binary_sensor.altherma_climatecontrol_is_in_installer_state', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:information-outline', + 'original_name': 'ClimateControl Is In Installer State', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'climatecontrol_isininstallerstate', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_climateControl_None_isInInstallerState', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[binary_sensor.altherma_climatecontrol_is_in_installer_state-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma ClimateControl Is In Installer State', + 'icon': 'mdi:information-outline', + }), + 'context': , + 'entity_id': 'binary_sensor.altherma_climatecontrol_is_in_installer_state', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': 'off', + }) +# --- +# name: test_minimal_data[binary_sensor.altherma_domestichotwatertank_is_holiday_mode_active-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': None, + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'binary_sensor', + 'entity_category': , + 'entity_id': 'binary_sensor.altherma_domestichotwatertank_is_holiday_mode_active', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:information-outline', + 'original_name': 'DomesticHotWaterTank Is Holiday Mode Active', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'domestichotwatertank_isholidaymodeactive', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_domesticHotWaterTank_None_isHolidayModeActive', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[binary_sensor.altherma_domestichotwatertank_is_holiday_mode_active-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma DomesticHotWaterTank Is Holiday Mode Active', + 'icon': 'mdi:information-outline', + }), + 'context': , + 'entity_id': 'binary_sensor.altherma_domestichotwatertank_is_holiday_mode_active', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': 'off', + }) +# --- +# name: test_minimal_data[binary_sensor.altherma_domestichotwatertank_is_in_error_state-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': None, + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'binary_sensor', + 'entity_category': , + 'entity_id': 'binary_sensor.altherma_domestichotwatertank_is_in_error_state', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': , + 'original_icon': 'mdi:information-outline', + 'original_name': 'DomesticHotWaterTank Is In Error State', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'domestichotwatertank_isinerrorstate', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_domesticHotWaterTank_None_isInErrorState', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[binary_sensor.altherma_domestichotwatertank_is_in_error_state-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'device_class': 'problem', + 'friendly_name': 'Altherma DomesticHotWaterTank Is In Error State', + 'icon': 'mdi:information-outline', + }), + 'context': , + 'entity_id': 'binary_sensor.altherma_domestichotwatertank_is_in_error_state', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': 'off', + }) +# --- +# name: test_minimal_data[binary_sensor.altherma_domestichotwatertank_is_in_installer_state-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': None, + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'binary_sensor', + 'entity_category': , + 'entity_id': 'binary_sensor.altherma_domestichotwatertank_is_in_installer_state', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:information-outline', + 'original_name': 'DomesticHotWaterTank Is In Installer State', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'domestichotwatertank_isininstallerstate', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_domesticHotWaterTank_None_isInInstallerState', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[binary_sensor.altherma_domestichotwatertank_is_in_installer_state-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma DomesticHotWaterTank Is In Installer State', + 'icon': 'mdi:information-outline', + }), + 'context': , + 'entity_id': 'binary_sensor.altherma_domestichotwatertank_is_in_installer_state', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': 'off', + }) +# --- +# name: test_minimal_data[binary_sensor.altherma_gateway_is_firmware_update_supported-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': None, + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'binary_sensor', + 'entity_category': , + 'entity_id': 'binary_sensor.altherma_gateway_is_firmware_update_supported', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:information-outline', + 'original_name': 'Gateway Is Firmware Update Supported', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'gateway_isfirmwareupdatesupported', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_gateway_None_isFirmwareUpdateSupported', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[binary_sensor.altherma_gateway_is_firmware_update_supported-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma Gateway Is Firmware Update Supported', + 'icon': 'mdi:information-outline', + }), + 'context': , + 'entity_id': 'binary_sensor.altherma_gateway_is_firmware_update_supported', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': 'off', + }) +# --- +# name: test_minimal_data[climate.altherma_leaving_water_temperature-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': dict({ + 'hvac_modes': list([ + , + , + , + , + ]), + 'max_temp': 35, + 'min_temp': 7, + }), + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'climate', + 'entity_category': None, + 'entity_id': 'climate.altherma_leaving_water_temperature', + 'has_entity_name': False, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': None, + 'original_name': 'Altherma Leaving Water Temperature', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': , + 'translation_key': 'daikin_onecta', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_leavingWaterTemperature', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[climate.altherma_leaving_water_temperature-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'current_temperature': 26, + 'friendly_name': 'Altherma Leaving Water Temperature', + 'hvac_modes': list([ + , + , + , + , + ]), + 'max_temp': 35, + 'min_temp': 7, + 'supported_features': , + }), + 'context': , + 'entity_id': 'climate.altherma_leaving_water_temperature', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': 'off', + }) +# --- +# name: test_minimal_data[climate.altherma_room_temperature-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': dict({ + 'hvac_modes': list([ + , + , + , + , + ]), + 'max_temp': 30, + 'min_temp': 12, + 'target_temp_step': 0.5, + }), + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'climate', + 'entity_category': None, + 'entity_id': 'climate.altherma_room_temperature', + 'has_entity_name': False, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': None, + 'original_name': 'Altherma Room Temperature', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': , + 'translation_key': 'daikin_onecta', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_roomTemperature', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[climate.altherma_room_temperature-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'current_temperature': 21.2, + 'friendly_name': 'Altherma Room Temperature', + 'hvac_modes': list([ + , + , + , + , + ]), + 'max_temp': 30, + 'min_temp': 12, + 'supported_features': , + 'target_temp_step': 0.5, + 'temperature': 22, + }), + 'context': , + 'entity_id': 'climate.altherma_room_temperature', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': 'off', + }) +# --- +# name: test_minimal_data[sensor.altherma_climatecontrol_control_mode-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': None, + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': None, + 'entity_id': 'sensor.altherma_climatecontrol_control_mode', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:alphabetical', + 'original_name': 'ClimateControl Control Mode', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'climatecontrol_controlmode', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_climateControl_None_controlMode', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[sensor.altherma_climatecontrol_control_mode-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma ClimateControl Control Mode', + 'icon': 'mdi:alphabetical', + }), + 'context': , + 'entity_id': 'sensor.altherma_climatecontrol_control_mode', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': 'roomTemperature', + }) +# --- +# name: test_minimal_data[sensor.altherma_climatecontrol_cooling_daily_electrical_consumption-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': dict({ + 'state_class': , + }), + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': None, + 'entity_id': 'sensor.altherma_climatecontrol_cooling_daily_electrical_consumption', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': , + 'original_icon': 'mdi:snowflake', + 'original_name': 'ClimateControl Cooling Daily Electrical Consumption', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': None, + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_climateControl_electrical_cooling_d', + 'unit_of_measurement': , + }) +# --- +# name: test_minimal_data[sensor.altherma_climatecontrol_cooling_daily_electrical_consumption-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'device_class': 'energy', + 'friendly_name': 'Altherma ClimateControl Cooling Daily Electrical Consumption', + 'icon': 'mdi:snowflake', + 'state_class': , + 'unit_of_measurement': , + }), + 'context': , + 'entity_id': 'sensor.altherma_climatecontrol_cooling_daily_electrical_consumption', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': '0', + }) +# --- +# name: test_minimal_data[sensor.altherma_climatecontrol_cooling_weekly_electrical_consumption-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': dict({ + 'state_class': , + }), + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': None, + 'entity_id': 'sensor.altherma_climatecontrol_cooling_weekly_electrical_consumption', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': , + 'original_icon': 'mdi:snowflake', + 'original_name': 'ClimateControl Cooling Weekly Electrical Consumption', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': None, + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_climateControl_electrical_cooling_w', + 'unit_of_measurement': , + }) +# --- +# name: test_minimal_data[sensor.altherma_climatecontrol_cooling_weekly_electrical_consumption-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'device_class': 'energy', + 'friendly_name': 'Altherma ClimateControl Cooling Weekly Electrical Consumption', + 'icon': 'mdi:snowflake', + 'state_class': , + 'unit_of_measurement': , + }), + 'context': , + 'entity_id': 'sensor.altherma_climatecontrol_cooling_weekly_electrical_consumption', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': '0', + }) +# --- +# name: test_minimal_data[sensor.altherma_climatecontrol_cooling_yearly_electrical_consumption-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': dict({ + 'state_class': , + }), + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': None, + 'entity_id': 'sensor.altherma_climatecontrol_cooling_yearly_electrical_consumption', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': , + 'original_icon': 'mdi:snowflake', + 'original_name': 'ClimateControl Cooling Yearly Electrical Consumption', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': None, + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_climateControl_electrical_cooling_m', + 'unit_of_measurement': , + }) +# --- +# name: test_minimal_data[sensor.altherma_climatecontrol_cooling_yearly_electrical_consumption-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'device_class': 'energy', + 'friendly_name': 'Altherma ClimateControl Cooling Yearly Electrical Consumption', + 'icon': 'mdi:snowflake', + 'state_class': , + 'unit_of_measurement': , + }), + 'context': , + 'entity_id': 'sensor.altherma_climatecontrol_cooling_yearly_electrical_consumption', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': '447', + }) +# --- +# name: test_minimal_data[sensor.altherma_climatecontrol_heating_daily_electrical_consumption-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': dict({ + 'state_class': , + }), + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': None, + 'entity_id': 'sensor.altherma_climatecontrol_heating_daily_electrical_consumption', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': , + 'original_icon': 'mdi:fire', + 'original_name': 'ClimateControl Heating Daily Electrical Consumption', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': None, + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_climateControl_electrical_heating_d', + 'unit_of_measurement': , + }) +# --- +# name: test_minimal_data[sensor.altherma_climatecontrol_heating_daily_electrical_consumption-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'device_class': 'energy', + 'friendly_name': 'Altherma ClimateControl Heating Daily Electrical Consumption', + 'icon': 'mdi:fire', + 'state_class': , + 'unit_of_measurement': , + }), + 'context': , + 'entity_id': 'sensor.altherma_climatecontrol_heating_daily_electrical_consumption', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': '0', + }) +# --- +# name: test_minimal_data[sensor.altherma_climatecontrol_heating_weekly_electrical_consumption-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': dict({ + 'state_class': , + }), + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': None, + 'entity_id': 'sensor.altherma_climatecontrol_heating_weekly_electrical_consumption', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': , + 'original_icon': 'mdi:fire', + 'original_name': 'ClimateControl Heating Weekly Electrical Consumption', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': None, + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_climateControl_electrical_heating_w', + 'unit_of_measurement': , + }) +# --- +# name: test_minimal_data[sensor.altherma_climatecontrol_heating_weekly_electrical_consumption-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'device_class': 'energy', + 'friendly_name': 'Altherma ClimateControl Heating Weekly Electrical Consumption', + 'icon': 'mdi:fire', + 'state_class': , + 'unit_of_measurement': , + }), + 'context': , + 'entity_id': 'sensor.altherma_climatecontrol_heating_weekly_electrical_consumption', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': '0', + }) +# --- +# name: test_minimal_data[sensor.altherma_climatecontrol_heating_yearly_electrical_consumption-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': dict({ + 'state_class': , + }), + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': None, + 'entity_id': 'sensor.altherma_climatecontrol_heating_yearly_electrical_consumption', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': , + 'original_icon': 'mdi:fire', + 'original_name': 'ClimateControl Heating Yearly Electrical Consumption', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': None, + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_climateControl_electrical_heating_m', + 'unit_of_measurement': , + }) +# --- +# name: test_minimal_data[sensor.altherma_climatecontrol_heating_yearly_electrical_consumption-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'device_class': 'energy', + 'friendly_name': 'Altherma ClimateControl Heating Yearly Electrical Consumption', + 'icon': 'mdi:fire', + 'state_class': , + 'unit_of_measurement': , + }), + 'context': , + 'entity_id': 'sensor.altherma_climatecontrol_heating_yearly_electrical_consumption', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': '1243', + }) +# --- +# name: test_minimal_data[sensor.altherma_climatecontrol_leaving_water_temperature-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': dict({ + 'state_class': , + }), + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': None, + 'entity_id': 'sensor.altherma_climatecontrol_leaving_water_temperature', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': , + 'original_icon': '', + 'original_name': 'ClimateControl Leaving Water Temperature', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'climatecontrol_leavingwatertemperature', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_climateControl_sensoryData_leavingWaterTemperature', + 'unit_of_measurement': , + }) +# --- +# name: test_minimal_data[sensor.altherma_climatecontrol_leaving_water_temperature-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'device_class': 'temperature', + 'friendly_name': 'Altherma ClimateControl Leaving Water Temperature', + 'icon': '', + 'state_class': , + 'unit_of_measurement': , + }), + 'context': , + 'entity_id': 'sensor.altherma_climatecontrol_leaving_water_temperature', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': '26', + }) +# --- +# name: test_minimal_data[sensor.altherma_climatecontrol_name-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': None, + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': , + 'entity_id': 'sensor.altherma_climatecontrol_name', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:information-outline', + 'original_name': 'ClimateControl Name', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'climatecontrol_name', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_climateControl_None_name', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[sensor.altherma_climatecontrol_name-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma ClimateControl Name', + 'icon': 'mdi:information-outline', + }), + 'context': , + 'entity_id': 'sensor.altherma_climatecontrol_name', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': '', + }) +# --- +# name: test_minimal_data[sensor.altherma_climatecontrol_outdoor_temperature-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': dict({ + 'state_class': , + }), + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': None, + 'entity_id': 'sensor.altherma_climatecontrol_outdoor_temperature', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': , + 'original_icon': '', + 'original_name': 'ClimateControl Outdoor Temperature', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'climatecontrol_outdoortemperature', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_climateControl_sensoryData_outdoorTemperature', + 'unit_of_measurement': , + }) +# --- +# name: test_minimal_data[sensor.altherma_climatecontrol_outdoor_temperature-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'device_class': 'temperature', + 'friendly_name': 'Altherma ClimateControl Outdoor Temperature', + 'icon': '', + 'state_class': , + 'unit_of_measurement': , + }), + 'context': , + 'entity_id': 'sensor.altherma_climatecontrol_outdoor_temperature', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': '9', + }) +# --- +# name: test_minimal_data[sensor.altherma_climatecontrol_room_temperature-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': dict({ + 'state_class': , + }), + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': None, + 'entity_id': 'sensor.altherma_climatecontrol_room_temperature', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': , + 'original_icon': '', + 'original_name': 'ClimateControl Room Temperature', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'climatecontrol_roomtemperature', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_climateControl_sensoryData_roomTemperature', + 'unit_of_measurement': , + }) +# --- +# name: test_minimal_data[sensor.altherma_climatecontrol_room_temperature-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'device_class': 'temperature', + 'friendly_name': 'Altherma ClimateControl Room Temperature', + 'icon': '', + 'state_class': , + 'unit_of_measurement': , + }), + 'context': , + 'entity_id': 'sensor.altherma_climatecontrol_room_temperature', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': '21.2', + }) +# --- +# name: test_minimal_data[sensor.altherma_climatecontrol_setpoint_mode-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': None, + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': None, + 'entity_id': 'sensor.altherma_climatecontrol_setpoint_mode', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:alphabetical', + 'original_name': 'ClimateControl Setpoint Mode', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'climatecontrol_setpointmode', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_climateControl_None_setpointMode', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[sensor.altherma_climatecontrol_setpoint_mode-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma ClimateControl Setpoint Mode', + 'icon': 'mdi:alphabetical', + }), + 'context': , + 'entity_id': 'sensor.altherma_climatecontrol_setpoint_mode', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': 'fixed', + }) +# --- +# name: test_minimal_data[sensor.altherma_domestichotwatertank_heatup_mode-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': None, + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': None, + 'entity_id': 'sensor.altherma_domestichotwatertank_heatup_mode', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:alphabetical', + 'original_name': 'DomesticHotWaterTank Heatup Mode', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'domestichotwatertank_heatupmode', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_domesticHotWaterTank_None_heatupMode', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[sensor.altherma_domestichotwatertank_heatup_mode-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma DomesticHotWaterTank Heatup Mode', + 'icon': 'mdi:alphabetical', + }), + 'context': , + 'entity_id': 'sensor.altherma_domestichotwatertank_heatup_mode', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': 'reheatOnly', + }) +# --- +# name: test_minimal_data[sensor.altherma_domestichotwatertank_name-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': None, + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': , + 'entity_id': 'sensor.altherma_domestichotwatertank_name', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:information-outline', + 'original_name': 'DomesticHotWaterTank Name', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'domestichotwatertank_name', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_domesticHotWaterTank_None_name', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[sensor.altherma_domestichotwatertank_name-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma DomesticHotWaterTank Name', + 'icon': 'mdi:information-outline', + }), + 'context': , + 'entity_id': 'sensor.altherma_domestichotwatertank_name', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': '', + }) +# --- +# name: test_minimal_data[sensor.altherma_domestichotwatertank_setpoint_mode-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': None, + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': None, + 'entity_id': 'sensor.altherma_domestichotwatertank_setpoint_mode', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:alphabetical', + 'original_name': 'DomesticHotWaterTank Setpoint Mode', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'domestichotwatertank_setpointmode', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_domesticHotWaterTank_None_setpointMode', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[sensor.altherma_domestichotwatertank_setpoint_mode-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma DomesticHotWaterTank Setpoint Mode', + 'icon': 'mdi:alphabetical', + }), + 'context': , + 'entity_id': 'sensor.altherma_domestichotwatertank_setpoint_mode', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': 'fixed', + }) +# --- +# name: test_minimal_data[sensor.altherma_domestichotwatertank_tank_temperature-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': dict({ + 'state_class': , + }), + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': None, + 'entity_id': 'sensor.altherma_domestichotwatertank_tank_temperature', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': , + 'original_icon': 'mdi:bathtub-outline', + 'original_name': 'DomesticHotWaterTank Tank Temperature', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'domestichotwatertank_tanktemperature', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_domesticHotWaterTank_sensoryData_tankTemperature', + 'unit_of_measurement': , + }) +# --- +# name: test_minimal_data[sensor.altherma_domestichotwatertank_tank_temperature-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'device_class': 'temperature', + 'friendly_name': 'Altherma DomesticHotWaterTank Tank Temperature', + 'icon': 'mdi:bathtub-outline', + 'state_class': , + 'unit_of_measurement': , + }), + 'context': , + 'entity_id': 'sensor.altherma_domestichotwatertank_tank_temperature', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': '53', + }) +# --- +# name: test_minimal_data[sensor.altherma_gateway_ip_address-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': None, + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': , + 'entity_id': 'sensor.altherma_gateway_ip_address', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:ip-network', + 'original_name': 'Gateway Ip Address', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'gateway_ipaddress', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_gateway_None_ipAddress', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[sensor.altherma_gateway_ip_address-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma Gateway Ip Address', + 'icon': 'mdi:ip-network', + }), + 'context': , + 'entity_id': 'sensor.altherma_gateway_ip_address', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': '192.168.2.13', + }) +# --- +# name: test_minimal_data[sensor.altherma_gateway_model_info-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': None, + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': , + 'entity_id': 'sensor.altherma_gateway_model_info', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:information-outline', + 'original_name': 'Gateway Model Info', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'gateway_modelinfo', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_gateway_None_modelInfo', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[sensor.altherma_gateway_model_info-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma Gateway Model Info', + 'icon': 'mdi:information-outline', + }), + 'context': , + 'entity_id': 'sensor.altherma_gateway_model_info', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': 'BRP069A78', + }) +# --- +# name: test_minimal_data[sensor.altherma_gateway_name-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': None, + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': , + 'entity_id': 'sensor.altherma_gateway_name', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:information-outline', + 'original_name': 'Gateway Name', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'gateway_name', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_gateway_None_name', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[sensor.altherma_gateway_name-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma Gateway Name', + 'icon': 'mdi:information-outline', + }), + 'context': , + 'entity_id': 'sensor.altherma_gateway_name', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': 'Gateway', + }) +# --- +# name: test_minimal_data[sensor.altherma_indoorunithydro_model_info-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': None, + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': , + 'entity_id': 'sensor.altherma_indoorunithydro_model_info', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:information-outline', + 'original_name': 'IndoorUnitHydro Model Info', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'indoorunithydro_modelinfo', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_indoorUnitHydro_None_modelInfo', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[sensor.altherma_indoorunithydro_model_info-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma IndoorUnitHydro Model Info', + 'icon': 'mdi:information-outline', + }), + 'context': , + 'entity_id': 'sensor.altherma_indoorunithydro_model_info', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': 'EHVX08S18EJ6V', + }) +# --- +# name: test_minimal_data[sensor.altherma_indoorunithydro_name-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': None, + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': , + 'entity_id': 'sensor.altherma_indoorunithydro_name', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:information-outline', + 'original_name': 'IndoorUnitHydro Name', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'indoorunithydro_name', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_indoorUnitHydro_None_name', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[sensor.altherma_indoorunithydro_name-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma IndoorUnitHydro Name', + 'icon': 'mdi:information-outline', + }), + 'context': , + 'entity_id': 'sensor.altherma_indoorunithydro_name', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': 'Indoor Hydro Unit', + }) +# --- +# name: test_minimal_data[sensor.altherma_ratelimit_day-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': dict({ + 'state_class': , + }), + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': , + 'entity_id': 'sensor.altherma_ratelimit_day', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:information-outline', + 'original_name': 'RateLimit day', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': None, + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_limitsensor_day', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[sensor.altherma_ratelimit_day-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma RateLimit day', + 'icon': 'mdi:information-outline', + 'state_class': , + }), + 'context': , + 'entity_id': 'sensor.altherma_ratelimit_day', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': '0', + }) +# --- +# name: test_minimal_data[sensor.altherma_ratelimit_minute-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': dict({ + 'state_class': , + }), + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': , + 'entity_id': 'sensor.altherma_ratelimit_minute', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:information-outline', + 'original_name': 'RateLimit minute', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': None, + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_limitsensor_minute', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[sensor.altherma_ratelimit_minute-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma RateLimit minute', + 'icon': 'mdi:information-outline', + 'state_class': , + }), + 'context': , + 'entity_id': 'sensor.altherma_ratelimit_minute', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': '0', + }) +# --- +# name: test_minimal_data[sensor.altherma_ratelimit_ratelimit_reset-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': dict({ + 'state_class': , + }), + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': , + 'entity_id': 'sensor.altherma_ratelimit_ratelimit_reset', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:information-outline', + 'original_name': 'RateLimit ratelimit_reset', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': None, + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_limitsensor_ratelimit_reset', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[sensor.altherma_ratelimit_ratelimit_reset-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma RateLimit ratelimit_reset', + 'icon': 'mdi:information-outline', + 'state_class': , + }), + 'context': , + 'entity_id': 'sensor.altherma_ratelimit_ratelimit_reset', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': '0', + }) +# --- +# name: test_minimal_data[sensor.altherma_ratelimit_remaining_day-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': dict({ + 'state_class': , + }), + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': , + 'entity_id': 'sensor.altherma_ratelimit_remaining_day', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:information-outline', + 'original_name': 'RateLimit remaining_day', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': None, + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_limitsensor_remaining_day', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[sensor.altherma_ratelimit_remaining_day-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma RateLimit remaining_day', + 'icon': 'mdi:information-outline', + 'state_class': , + }), + 'context': , + 'entity_id': 'sensor.altherma_ratelimit_remaining_day', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': '0', + }) +# --- +# name: test_minimal_data[sensor.altherma_ratelimit_remaining_minutes-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': dict({ + 'state_class': , + }), + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': , + 'entity_id': 'sensor.altherma_ratelimit_remaining_minutes', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:information-outline', + 'original_name': 'RateLimit remaining_minutes', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': None, + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_limitsensor_remaining_minutes', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[sensor.altherma_ratelimit_remaining_minutes-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma RateLimit remaining_minutes', + 'icon': 'mdi:information-outline', + 'state_class': , + }), + 'context': , + 'entity_id': 'sensor.altherma_ratelimit_remaining_minutes', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': '0', + }) +# --- +# name: test_minimal_data[sensor.altherma_ratelimit_retry_after-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': dict({ + 'state_class': , + }), + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': , + 'entity_id': 'sensor.altherma_ratelimit_retry_after', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:information-outline', + 'original_name': 'RateLimit retry_after', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': None, + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_limitsensor_retry_after', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[sensor.altherma_ratelimit_retry_after-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma RateLimit retry_after', + 'icon': 'mdi:information-outline', + 'state_class': , + }), + 'context': , + 'entity_id': 'sensor.altherma_ratelimit_retry_after', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': '0', + }) +# --- +# name: test_minimal_data[sensor.altherma_userinterface_model_info-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': None, + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': , + 'entity_id': 'sensor.altherma_userinterface_model_info', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:information-outline', + 'original_name': 'UserInterface Model Info', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'userinterface_modelinfo', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_userInterface_None_modelInfo', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[sensor.altherma_userinterface_model_info-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma UserInterface Model Info', + 'icon': 'mdi:information-outline', + }), + 'context': , + 'entity_id': 'sensor.altherma_userinterface_model_info', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': 'EHVX08S18EJ6V', + }) +# --- +# name: test_minimal_data[sensor.altherma_userinterface_name-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': None, + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': , + 'entity_id': 'sensor.altherma_userinterface_name', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:information-outline', + 'original_name': 'UserInterface Name', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'userinterface_name', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_userInterface_None_name', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[sensor.altherma_userinterface_name-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma UserInterface Name', + 'icon': 'mdi:information-outline', + }), + 'context': , + 'entity_id': 'sensor.altherma_userinterface_name', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': 'User Interface', + }) +# --- +# name: test_minimal_data[sensor.altherma_userinterface_software_version-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': None, + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'sensor', + 'entity_category': , + 'entity_id': 'sensor.altherma_userinterface_software_version', + 'has_entity_name': True, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': 'mdi:information-outline', + 'original_name': 'UserInterface Software Version', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': 0, + 'translation_key': 'userinterface_softwareversion', + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485_userInterface_None_softwareVersion', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[sensor.altherma_userinterface_software_version-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'friendly_name': 'Altherma UserInterface Software Version', + 'icon': 'mdi:information-outline', + }), + 'context': , + 'entity_id': 'sensor.altherma_userinterface_software_version', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': '7.5.0', + }) +# --- +# name: test_minimal_data[water_heater.altherma-entry] + EntityRegistryEntrySnapshot({ + 'aliases': set({ + }), + 'area_id': None, + 'capabilities': dict({ + 'max_temp': None, + 'min_temp': None, + 'operation_list': list([ + 'off', + 'heat_pump', + ]), + }), + 'config_entry_id': , + 'device_class': None, + 'device_id': , + 'disabled_by': None, + 'domain': 'water_heater', + 'entity_category': None, + 'entity_id': 'water_heater.altherma', + 'has_entity_name': False, + 'hidden_by': None, + 'icon': None, + 'id': , + 'labels': set({ + }), + 'name': None, + 'options': dict({ + }), + 'original_device_class': None, + 'original_icon': None, + 'original_name': 'Altherma', + 'platform': 'daikin_onecta', + 'previous_unique_id': None, + 'supported_features': , + 'translation_key': None, + 'unique_id': 'b84e8af3-310a-4e6e-8e52-295573423485', + 'unit_of_measurement': None, + }) +# --- +# name: test_minimal_data[water_heater.altherma-state] + StateSnapshot({ + 'attributes': ReadOnlyDict({ + 'current_temperature': 53.0, + 'friendly_name': 'Altherma', + 'max_temp': None, + 'min_temp': None, + 'operation_list': list([ + 'off', + 'heat_pump', + ]), + 'operation_mode': 'heat_pump', + 'supported_features': , + 'target_temp_high': None, + 'target_temp_low': None, + 'temperature': None, + }), + 'context': , + 'entity_id': 'water_heater.altherma', + 'last_changed': , + 'last_reported': , + 'last_updated': , + 'state': 'heat_pump', + }) +# --- # name: test_offlinedevice[binary_sensor.studio_climatecontrol_is_holiday_mode_active-entry] EntityRegistryEntrySnapshot({ 'aliases': set({ diff --git a/tests/test_init.py b/tests/test_init.py index 66423de..de9c777 100644 --- a/tests/test_init.py +++ b/tests/test_init.py @@ -982,3 +982,15 @@ async def test_climate( assert len(rsps.calls) == 1 assert rsps.calls[0].request.url == DAIKIN_API_URL + "/v1/gateway-devices" + +async def test_minimal_data( + hass: HomeAssistant, + config_entry: MockConfigEntry, + onecta_auth: AsyncMock, + snapshot: SnapshotAssertion, + entity_registry: er.EntityRegistry, +) -> None: + """Test entities.""" + await snapshot_platform_entities(hass, config_entry, Platform.SENSOR, entity_registry, snapshot, "minimal_data") + + assert hass.states.get("water_heater.altherma").attributes["current_temperature"] == 53 From 243381338f98be1986db255219ad4d181033ff3e Mon Sep 17 00:00:00 2001 From: Johnny Willemsen Date: Mon, 14 Oct 2024 10:06:27 +0200 Subject: [PATCH 2/3] Upgrade python * .github/workflows/precommit.yaml: --- .github/workflows/precommit.yaml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/precommit.yaml b/.github/workflows/precommit.yaml index 621e3a4..d9bd817 100644 --- a/.github/workflows/precommit.yaml +++ b/.github/workflows/precommit.yaml @@ -14,16 +14,17 @@ jobs: steps: - name: Check out the repository uses: actions/checkout@v4 - + - name: Setup Python + uses: "actions/setup-python@v5" + with: + python-version: "3.12" - name: Upgrade pip run: | pip install --constraint=.github/workflows/constraints.txt pip pip --version - - name: Install Python modules run: | pip install --constraint=.github/workflows/constraints.txt pre-commit black flake8 reorder-python-imports - - name: Run pre-commit on all files run: | pre-commit run --all-files --show-diff-on-failure --color=always From 7bb72f907199433d1cf888f3ec8496a0503a1a00 Mon Sep 17 00:00:00 2001 From: Johnny Willemsen Date: Mon, 14 Oct 2024 10:19:20 +0200 Subject: [PATCH 3/3] precommit * tests/test_init.py: --- tests/test_init.py | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/test_init.py b/tests/test_init.py index de9c777..fba845c 100644 --- a/tests/test_init.py +++ b/tests/test_init.py @@ -983,6 +983,7 @@ async def test_climate( assert len(rsps.calls) == 1 assert rsps.calls[0].request.url == DAIKIN_API_URL + "/v1/gateway-devices" + async def test_minimal_data( hass: HomeAssistant, config_entry: MockConfigEntry,