Add Tuya snapshots tests for wk category (thermostat) (#150175)

This commit is contained in:
epenet
2025-08-07 12:53:19 +02:00
committed by GitHub
parent 4f5502ab47
commit df7c657d7e
7 changed files with 952 additions and 4 deletions

View File

@@ -423,15 +423,21 @@ DEVICE_MOCKS = {
"wfcon_b25mh8sxawsgndck": [ "wfcon_b25mh8sxawsgndck": [
# https://github.com/home-assistant/core/issues/149704 # https://github.com/home-assistant/core/issues/149704
], ],
"wg2_nwxr8qcu4seltoro": [
# https://github.com/orgs/home-assistant/discussions/430
Platform.BINARY_SENSOR,
],
"wk_6kijc7nd": [
# https://github.com/home-assistant/core/issues/136513
Platform.CLIMATE,
Platform.NUMBER,
Platform.SWITCH,
],
"wk_aqoouq7x": [ "wk_aqoouq7x": [
# https://github.com/home-assistant/core/issues/146263 # https://github.com/home-assistant/core/issues/146263
Platform.CLIMATE, Platform.CLIMATE,
Platform.SWITCH, Platform.SWITCH,
], ],
"wg2_nwxr8qcu4seltoro": [
# https://github.com/orgs/home-assistant/discussions/430
Platform.BINARY_SENSOR,
],
"wk_fi6dne5tu4t1nm6j": [ "wk_fi6dne5tu4t1nm6j": [
# https://github.com/orgs/home-assistant/discussions/243 # https://github.com/orgs/home-assistant/discussions/243
Platform.CLIMATE, Platform.CLIMATE,
@@ -439,6 +445,17 @@ DEVICE_MOCKS = {
Platform.SENSOR, Platform.SENSOR,
Platform.SWITCH, Platform.SWITCH,
], ],
"wk_gogb05wrtredz3bs": [
# https://github.com/home-assistant/core/issues/136337
Platform.CLIMATE,
Platform.NUMBER,
Platform.SWITCH,
],
"wk_y5obtqhuztqsf2mj": [
# https://github.com/home-assistant/core/issues/139735
Platform.CLIMATE,
Platform.SWITCH,
],
"wsdcg_g2y6z3p3ja2qhyav": [ "wsdcg_g2y6z3p3ja2qhyav": [
# https://github.com/home-assistant/core/issues/102769 # https://github.com/home-assistant/core/issues/102769
Platform.SENSOR, Platform.SENSOR,

View File

@@ -0,0 +1,189 @@
{
"endpoint": "https://apigw.tuyaeu.com",
"terminal_id": "REDACTED",
"mqtt_connected": true,
"disabled_by": null,
"disabled_polling": false,
"id": "bf3c2c83660b8e19e152jb",
"name": "Кабінет",
"category": "wk",
"product_id": "6kijc7nd",
"product_name": "Thermostat Tervix Pro Line ZigBee color",
"online": true,
"sub": true,
"time_zone": "+02:00",
"active_time": "2025-01-22T11:54:29+00:00",
"create_time": "2025-01-22T11:54:29+00:00",
"update_time": "2025-01-22T11:54:29+00:00",
"function": {
"switch": {
"type": "Boolean",
"value": {}
},
"mode": {
"type": "Enum",
"value": {
"range": ["manual", "program"]
}
},
"window_check": {
"type": "Boolean",
"value": {}
},
"frost": {
"type": "Boolean",
"value": {}
},
"temp_set": {
"type": "Integer",
"value": {
"unit": "℃",
"min": 50,
"max": 950,
"scale": 1,
"step": 5
}
},
"upper_temp": {
"type": "Integer",
"value": {
"unit": "℃",
"min": 350,
"max": 950,
"scale": 1,
"step": 5
}
},
"temp_correction": {
"type": "Integer",
"value": {
"unit": "℃",
"min": -9,
"max": 9,
"scale": 0,
"step": 1
}
},
"factory_reset": {
"type": "Boolean",
"value": {}
},
"child_lock": {
"type": "Boolean",
"value": {}
},
"sensor_choose": {
"type": "Enum",
"value": {
"range": ["in", "out"]
}
}
},
"status_range": {
"switch": {
"type": "Boolean",
"value": {}
},
"mode": {
"type": "Enum",
"value": {
"range": ["manual", "program"]
}
},
"window_check": {
"type": "Boolean",
"value": {}
},
"frost": {
"type": "Boolean",
"value": {}
},
"temp_set": {
"type": "Integer",
"value": {
"unit": "℃",
"min": 50,
"max": 950,
"scale": 1,
"step": 5
}
},
"upper_temp": {
"type": "Integer",
"value": {
"unit": "℃",
"min": 350,
"max": 950,
"scale": 1,
"step": 5
}
},
"temp_current": {
"type": "Integer",
"value": {
"unit": "℃",
"min": 0,
"max": 995,
"scale": 1,
"step": 5
}
},
"window_state": {
"type": "Enum",
"value": {
"range": ["close", "open"]
}
},
"temp_correction": {
"type": "Integer",
"value": {
"unit": "℃",
"min": -9,
"max": 9,
"scale": 0,
"step": 1
}
},
"humidity": {
"type": "Integer",
"value": {
"unit": "%",
"min": 0,
"max": 100,
"scale": 0,
"step": 1
}
},
"factory_reset": {
"type": "Boolean",
"value": {}
},
"child_lock": {
"type": "Boolean",
"value": {}
},
"sensor_choose": {
"type": "Enum",
"value": {
"range": ["in", "out"]
}
}
},
"status": {
"switch": true,
"mode": "manual",
"window_check": false,
"frost": false,
"temp_set": 215,
"upper_temp": 450,
"temp_current": 195,
"window_state": "close",
"temp_correction": -2,
"humidity": 23,
"factory_reset": false,
"child_lock": false,
"sensor_choose": "all"
},
"set_up": true,
"support_local": true
}

View File

@@ -0,0 +1,197 @@
{
"endpoint": "https://apigw.tuyaeu.com",
"terminal_id": "REDACTED",
"mqtt_connected": true,
"disabled_by": null,
"disabled_polling": false,
"id": "bf1085bf049a74fcc1idy2",
"name": "smart thermostats",
"category": "wk",
"product_id": "gogb05wrtredz3bs",
"product_name": "smart thermostats",
"online": true,
"sub": false,
"time_zone": "+01:00",
"active_time": "2025-01-23T13:07:21+00:00",
"create_time": "2025-01-23T13:07:21+00:00",
"update_time": "2025-01-23T13:07:21+00:00",
"function": {
"switch": {
"type": "Boolean",
"value": {}
},
"mode": {
"type": "Enum",
"value": {
"range": ["auto", "manual"]
}
},
"frost": {
"type": "Boolean",
"value": {}
},
"temp_set": {
"type": "Integer",
"value": {
"unit": "℃",
"min": 5,
"max": 90,
"scale": 0,
"step": 1
}
},
"upper_temp": {
"type": "Integer",
"value": {
"unit": "℃",
"min": 30,
"max": 90,
"scale": 0,
"step": 1
}
},
"lower_temp": {
"type": "Integer",
"value": {
"unit": "℃",
"min": 5,
"max": 20,
"scale": 0,
"step": 1
}
},
"temp_correction": {
"type": "Integer",
"value": {
"unit": "摄氏度",
"min": -9,
"max": 9,
"scale": 0,
"step": 1
}
},
"factory_reset": {
"type": "Boolean",
"value": {}
},
"child_lock": {
"type": "Boolean",
"value": {}
},
"sensor_choose": {
"type": "Enum",
"value": {
"range": ["in", "out"]
}
}
},
"status_range": {
"switch": {
"type": "Boolean",
"value": {}
},
"mode": {
"type": "Enum",
"value": {
"range": ["auto", "manual"]
}
},
"frost": {
"type": "Boolean",
"value": {}
},
"temp_set": {
"type": "Integer",
"value": {
"unit": "℃",
"min": 5,
"max": 90,
"scale": 0,
"step": 1
}
},
"upper_temp": {
"type": "Integer",
"value": {
"unit": "℃",
"min": 30,
"max": 90,
"scale": 0,
"step": 1
}
},
"temp_current": {
"type": "Integer",
"value": {
"unit": "℃",
"min": 0,
"max": 900,
"scale": 1,
"step": 5
}
},
"lower_temp": {
"type": "Integer",
"value": {
"unit": "℃",
"min": 5,
"max": 20,
"scale": 0,
"step": 1
}
},
"temp_correction": {
"type": "Integer",
"value": {
"unit": "摄氏度",
"min": -9,
"max": 9,
"scale": 0,
"step": 1
}
},
"valve_state": {
"type": "Enum",
"value": {
"range": ["open", "close"]
}
},
"factory_reset": {
"type": "Boolean",
"value": {}
},
"child_lock": {
"type": "Boolean",
"value": {}
},
"sensor_choose": {
"type": "Enum",
"value": {
"range": ["in", "out"]
}
},
"fault": {
"type": "Bitmap",
"value": {
"label": ["e1", "e2", "e3"]
}
}
},
"status": {
"switch": false,
"mode": "manual",
"frost": true,
"temp_set": 12,
"upper_temp": 30,
"temp_current": 215,
"lower_temp": 5,
"temp_correction": -2,
"valve_state": "close",
"factory_reset": false,
"child_lock": false,
"sensor_choose": "in",
"fault": 0
},
"set_up": true,
"support_local": true
}

View File

@@ -0,0 +1,76 @@
{
"endpoint": "https://apigw.tuyaeu.com",
"terminal_id": "REDACTED",
"mqtt_connected": true,
"disabled_by": null,
"disabled_polling": false,
"id": "bf8d64588f4a61965ezszs",
"name": "Term - Prizemi",
"category": "wk",
"product_id": "y5obtqhuztqsf2mj",
"product_name": "Smart",
"online": true,
"sub": false,
"time_zone": "+01:00",
"active_time": "2025-02-22T10:25:25+00:00",
"create_time": "2025-02-22T10:25:25+00:00",
"update_time": "2025-02-22T10:25:25+00:00",
"function": {
"switch": {
"type": "Boolean",
"value": {}
},
"temp_set": {
"type": "Integer",
"value": {
"unit": "℃",
"min": 5,
"max": 700,
"scale": 1,
"step": 1
}
},
"child_lock": {
"type": "Boolean",
"value": {}
}
},
"status_range": {
"switch": {
"type": "Boolean",
"value": {}
},
"temp_set": {
"type": "Integer",
"value": {
"unit": "℃",
"min": 5,
"max": 700,
"scale": 1,
"step": 1
}
},
"temp_current": {
"type": "Integer",
"value": {
"unit": "℃",
"min": 0,
"max": 900,
"scale": 1,
"step": 1
}
},
"child_lock": {
"type": "Boolean",
"value": {}
}
},
"status": {
"switch": true,
"temp_set": 230,
"temp_current": 230,
"child_lock": false
},
"set_up": true,
"support_local": true
}

View File

@@ -74,6 +74,81 @@
'state': 'off', 'state': 'off',
}) })
# --- # ---
# name: test_platform_setup_and_discovery[wk_6kijc7nd][climate.kabinet-entry]
EntityRegistryEntrySnapshot({
'aliases': set({
}),
'area_id': None,
'capabilities': dict({
'hvac_modes': list([
<HVACMode.OFF: 'off'>,
<HVACMode.HEAT_COOL: 'heat_cool'>,
<HVACMode.HEAT_COOL: 'heat_cool'>,
]),
'max_temp': 95.0,
'min_temp': 5.0,
'preset_modes': list([
'program',
]),
'target_temp_step': 0.5,
}),
'config_entry_id': <ANY>,
'config_subentry_id': <ANY>,
'device_class': None,
'device_id': <ANY>,
'disabled_by': None,
'domain': 'climate',
'entity_category': None,
'entity_id': 'climate.kabinet',
'has_entity_name': True,
'hidden_by': None,
'icon': None,
'id': <ANY>,
'labels': set({
}),
'name': None,
'options': dict({
}),
'original_device_class': None,
'original_icon': None,
'original_name': None,
'platform': 'tuya',
'previous_unique_id': None,
'suggested_object_id': None,
'supported_features': <ClimateEntityFeature: 401>,
'translation_key': None,
'unique_id': 'tuya.bf3c2c83660b8e19e152jb',
'unit_of_measurement': None,
})
# ---
# name: test_platform_setup_and_discovery[wk_6kijc7nd][climate.kabinet-state]
StateSnapshot({
'attributes': ReadOnlyDict({
'current_temperature': 19.5,
'friendly_name': 'Кабінет',
'hvac_modes': list([
<HVACMode.OFF: 'off'>,
<HVACMode.HEAT_COOL: 'heat_cool'>,
<HVACMode.HEAT_COOL: 'heat_cool'>,
]),
'max_temp': 95.0,
'min_temp': 5.0,
'preset_mode': None,
'preset_modes': list([
'program',
]),
'supported_features': <ClimateEntityFeature: 401>,
'target_temp_step': 0.5,
'temperature': 21.5,
}),
'context': <ANY>,
'entity_id': 'climate.kabinet',
'last_changed': <ANY>,
'last_reported': <ANY>,
'last_updated': <ANY>,
'state': 'heat_cool',
})
# ---
# name: test_platform_setup_and_discovery[wk_aqoouq7x][climate.clima_cucina-entry] # name: test_platform_setup_and_discovery[wk_aqoouq7x][climate.clima_cucina-entry]
EntityRegistryEntrySnapshot({ EntityRegistryEntrySnapshot({
'aliases': set({ 'aliases': set({
@@ -221,3 +296,137 @@
'state': 'heat_cool', 'state': 'heat_cool',
}) })
# --- # ---
# name: test_platform_setup_and_discovery[wk_gogb05wrtredz3bs][climate.smart_thermostats-entry]
EntityRegistryEntrySnapshot({
'aliases': set({
}),
'area_id': None,
'capabilities': dict({
'hvac_modes': list([
<HVACMode.OFF: 'off'>,
<HVACMode.HEAT_COOL: 'heat_cool'>,
<HVACMode.HEAT_COOL: 'heat_cool'>,
]),
'max_temp': 90.0,
'min_temp': 5.0,
'target_temp_step': 1.0,
}),
'config_entry_id': <ANY>,
'config_subentry_id': <ANY>,
'device_class': None,
'device_id': <ANY>,
'disabled_by': None,
'domain': 'climate',
'entity_category': None,
'entity_id': 'climate.smart_thermostats',
'has_entity_name': True,
'hidden_by': None,
'icon': None,
'id': <ANY>,
'labels': set({
}),
'name': None,
'options': dict({
}),
'original_device_class': None,
'original_icon': None,
'original_name': None,
'platform': 'tuya',
'previous_unique_id': None,
'suggested_object_id': None,
'supported_features': <ClimateEntityFeature: 385>,
'translation_key': None,
'unique_id': 'tuya.bf1085bf049a74fcc1idy2',
'unit_of_measurement': None,
})
# ---
# name: test_platform_setup_and_discovery[wk_gogb05wrtredz3bs][climate.smart_thermostats-state]
StateSnapshot({
'attributes': ReadOnlyDict({
'current_temperature': 21.5,
'friendly_name': 'smart thermostats',
'hvac_modes': list([
<HVACMode.OFF: 'off'>,
<HVACMode.HEAT_COOL: 'heat_cool'>,
<HVACMode.HEAT_COOL: 'heat_cool'>,
]),
'max_temp': 90.0,
'min_temp': 5.0,
'supported_features': <ClimateEntityFeature: 385>,
'target_temp_step': 1.0,
'temperature': 12.0,
}),
'context': <ANY>,
'entity_id': 'climate.smart_thermostats',
'last_changed': <ANY>,
'last_reported': <ANY>,
'last_updated': <ANY>,
'state': 'off',
})
# ---
# name: test_platform_setup_and_discovery[wk_y5obtqhuztqsf2mj][climate.term_prizemi-entry]
EntityRegistryEntrySnapshot({
'aliases': set({
}),
'area_id': None,
'capabilities': dict({
'hvac_modes': list([
<HVACMode.OFF: 'off'>,
<HVACMode.HEAT_COOL: 'heat_cool'>,
]),
'max_temp': 70.0,
'min_temp': 0.5,
'target_temp_step': 0.1,
}),
'config_entry_id': <ANY>,
'config_subentry_id': <ANY>,
'device_class': None,
'device_id': <ANY>,
'disabled_by': None,
'domain': 'climate',
'entity_category': None,
'entity_id': 'climate.term_prizemi',
'has_entity_name': True,
'hidden_by': None,
'icon': None,
'id': <ANY>,
'labels': set({
}),
'name': None,
'options': dict({
}),
'original_device_class': None,
'original_icon': None,
'original_name': None,
'platform': 'tuya',
'previous_unique_id': None,
'suggested_object_id': None,
'supported_features': <ClimateEntityFeature: 385>,
'translation_key': None,
'unique_id': 'tuya.bf8d64588f4a61965ezszs',
'unit_of_measurement': None,
})
# ---
# name: test_platform_setup_and_discovery[wk_y5obtqhuztqsf2mj][climate.term_prizemi-state]
StateSnapshot({
'attributes': ReadOnlyDict({
'current_temperature': 23.0,
'friendly_name': 'Term - Prizemi',
'hvac_modes': list([
<HVACMode.OFF: 'off'>,
<HVACMode.HEAT_COOL: 'heat_cool'>,
]),
'max_temp': 70.0,
'min_temp': 0.5,
'supported_features': <ClimateEntityFeature: 385>,
'target_temp_step': 0.1,
'temperature': 23.0,
}),
'context': <ANY>,
'entity_id': 'climate.term_prizemi',
'last_changed': <ANY>,
'last_reported': <ANY>,
'last_updated': <ANY>,
'state': 'heat_cool',
})
# ---

View File

@@ -759,6 +759,64 @@
'state': '1.0', 'state': '1.0',
}) })
# --- # ---
# name: test_platform_setup_and_discovery[wk_6kijc7nd][number.kabinet_temperature_correction-entry]
EntityRegistryEntrySnapshot({
'aliases': set({
}),
'area_id': None,
'capabilities': dict({
'max': 9.0,
'min': -9.0,
'mode': <NumberMode.AUTO: 'auto'>,
'step': 1.0,
}),
'config_entry_id': <ANY>,
'config_subentry_id': <ANY>,
'device_class': None,
'device_id': <ANY>,
'disabled_by': None,
'domain': 'number',
'entity_category': <EntityCategory.CONFIG: 'config'>,
'entity_id': 'number.kabinet_temperature_correction',
'has_entity_name': True,
'hidden_by': None,
'icon': None,
'id': <ANY>,
'labels': set({
}),
'name': None,
'options': dict({
}),
'original_device_class': None,
'original_icon': None,
'original_name': 'Temperature correction',
'platform': 'tuya',
'previous_unique_id': None,
'suggested_object_id': None,
'supported_features': 0,
'translation_key': 'temp_correction',
'unique_id': 'tuya.bf3c2c83660b8e19e152jbtemp_correction',
'unit_of_measurement': '℃',
})
# ---
# name: test_platform_setup_and_discovery[wk_6kijc7nd][number.kabinet_temperature_correction-state]
StateSnapshot({
'attributes': ReadOnlyDict({
'friendly_name': 'Кабінет Temperature correction',
'max': 9.0,
'min': -9.0,
'mode': <NumberMode.AUTO: 'auto'>,
'step': 1.0,
'unit_of_measurement': '℃',
}),
'context': <ANY>,
'entity_id': 'number.kabinet_temperature_correction',
'last_changed': <ANY>,
'last_reported': <ANY>,
'last_updated': <ANY>,
'state': '-2.0',
})
# ---
# name: test_platform_setup_and_discovery[wk_fi6dne5tu4t1nm6j][number.wifi_smart_gas_boiler_thermostat_temperature_correction-entry] # name: test_platform_setup_and_discovery[wk_fi6dne5tu4t1nm6j][number.wifi_smart_gas_boiler_thermostat_temperature_correction-entry]
EntityRegistryEntrySnapshot({ EntityRegistryEntrySnapshot({
'aliases': set({ 'aliases': set({
@@ -817,6 +875,64 @@
'state': '-1.5', 'state': '-1.5',
}) })
# --- # ---
# name: test_platform_setup_and_discovery[wk_gogb05wrtredz3bs][number.smart_thermostats_temperature_correction-entry]
EntityRegistryEntrySnapshot({
'aliases': set({
}),
'area_id': None,
'capabilities': dict({
'max': 9.0,
'min': -9.0,
'mode': <NumberMode.AUTO: 'auto'>,
'step': 1.0,
}),
'config_entry_id': <ANY>,
'config_subentry_id': <ANY>,
'device_class': None,
'device_id': <ANY>,
'disabled_by': None,
'domain': 'number',
'entity_category': <EntityCategory.CONFIG: 'config'>,
'entity_id': 'number.smart_thermostats_temperature_correction',
'has_entity_name': True,
'hidden_by': None,
'icon': None,
'id': <ANY>,
'labels': set({
}),
'name': None,
'options': dict({
}),
'original_device_class': None,
'original_icon': None,
'original_name': 'Temperature correction',
'platform': 'tuya',
'previous_unique_id': None,
'suggested_object_id': None,
'supported_features': 0,
'translation_key': 'temp_correction',
'unique_id': 'tuya.bf1085bf049a74fcc1idy2temp_correction',
'unit_of_measurement': '摄氏度',
})
# ---
# name: test_platform_setup_and_discovery[wk_gogb05wrtredz3bs][number.smart_thermostats_temperature_correction-state]
StateSnapshot({
'attributes': ReadOnlyDict({
'friendly_name': 'smart thermostats Temperature correction',
'max': 9.0,
'min': -9.0,
'mode': <NumberMode.AUTO: 'auto'>,
'step': 1.0,
'unit_of_measurement': '摄氏度',
}),
'context': <ANY>,
'entity_id': 'number.smart_thermostats_temperature_correction',
'last_changed': <ANY>,
'last_reported': <ANY>,
'last_updated': <ANY>,
'state': '-2.0',
})
# ---
# name: test_platform_setup_and_discovery[ywcgq_h8lvyoahr6s6aybf][number.rainwater_tank_level_alarm_maximum-entry] # name: test_platform_setup_and_discovery[ywcgq_h8lvyoahr6s6aybf][number.rainwater_tank_level_alarm_maximum-entry]
EntityRegistryEntrySnapshot({ EntityRegistryEntrySnapshot({
'aliases': set({ 'aliases': set({

View File

@@ -3339,6 +3339,54 @@
'state': 'unavailable', 'state': 'unavailable',
}) })
# --- # ---
# name: test_platform_setup_and_discovery[wk_6kijc7nd][switch.kabinet_child_lock-entry]
EntityRegistryEntrySnapshot({
'aliases': set({
}),
'area_id': None,
'capabilities': None,
'config_entry_id': <ANY>,
'config_subentry_id': <ANY>,
'device_class': None,
'device_id': <ANY>,
'disabled_by': None,
'domain': 'switch',
'entity_category': <EntityCategory.CONFIG: 'config'>,
'entity_id': 'switch.kabinet_child_lock',
'has_entity_name': True,
'hidden_by': None,
'icon': None,
'id': <ANY>,
'labels': set({
}),
'name': None,
'options': dict({
}),
'original_device_class': None,
'original_icon': None,
'original_name': 'Child lock',
'platform': 'tuya',
'previous_unique_id': None,
'suggested_object_id': None,
'supported_features': 0,
'translation_key': 'child_lock',
'unique_id': 'tuya.bf3c2c83660b8e19e152jbchild_lock',
'unit_of_measurement': None,
})
# ---
# name: test_platform_setup_and_discovery[wk_6kijc7nd][switch.kabinet_child_lock-state]
StateSnapshot({
'attributes': ReadOnlyDict({
'friendly_name': 'Кабінет Child lock',
}),
'context': <ANY>,
'entity_id': 'switch.kabinet_child_lock',
'last_changed': <ANY>,
'last_reported': <ANY>,
'last_updated': <ANY>,
'state': 'off',
})
# ---
# name: test_platform_setup_and_discovery[wk_aqoouq7x][switch.clima_cucina_child_lock-entry] # name: test_platform_setup_and_discovery[wk_aqoouq7x][switch.clima_cucina_child_lock-entry]
EntityRegistryEntrySnapshot({ EntityRegistryEntrySnapshot({
'aliases': set({ 'aliases': set({
@@ -3435,3 +3483,99 @@
'state': 'off', 'state': 'off',
}) })
# --- # ---
# name: test_platform_setup_and_discovery[wk_gogb05wrtredz3bs][switch.smart_thermostats_child_lock-entry]
EntityRegistryEntrySnapshot({
'aliases': set({
}),
'area_id': None,
'capabilities': None,
'config_entry_id': <ANY>,
'config_subentry_id': <ANY>,
'device_class': None,
'device_id': <ANY>,
'disabled_by': None,
'domain': 'switch',
'entity_category': <EntityCategory.CONFIG: 'config'>,
'entity_id': 'switch.smart_thermostats_child_lock',
'has_entity_name': True,
'hidden_by': None,
'icon': None,
'id': <ANY>,
'labels': set({
}),
'name': None,
'options': dict({
}),
'original_device_class': None,
'original_icon': None,
'original_name': 'Child lock',
'platform': 'tuya',
'previous_unique_id': None,
'suggested_object_id': None,
'supported_features': 0,
'translation_key': 'child_lock',
'unique_id': 'tuya.bf1085bf049a74fcc1idy2child_lock',
'unit_of_measurement': None,
})
# ---
# name: test_platform_setup_and_discovery[wk_gogb05wrtredz3bs][switch.smart_thermostats_child_lock-state]
StateSnapshot({
'attributes': ReadOnlyDict({
'friendly_name': 'smart thermostats Child lock',
}),
'context': <ANY>,
'entity_id': 'switch.smart_thermostats_child_lock',
'last_changed': <ANY>,
'last_reported': <ANY>,
'last_updated': <ANY>,
'state': 'off',
})
# ---
# name: test_platform_setup_and_discovery[wk_y5obtqhuztqsf2mj][switch.term_prizemi_child_lock-entry]
EntityRegistryEntrySnapshot({
'aliases': set({
}),
'area_id': None,
'capabilities': None,
'config_entry_id': <ANY>,
'config_subentry_id': <ANY>,
'device_class': None,
'device_id': <ANY>,
'disabled_by': None,
'domain': 'switch',
'entity_category': <EntityCategory.CONFIG: 'config'>,
'entity_id': 'switch.term_prizemi_child_lock',
'has_entity_name': True,
'hidden_by': None,
'icon': None,
'id': <ANY>,
'labels': set({
}),
'name': None,
'options': dict({
}),
'original_device_class': None,
'original_icon': None,
'original_name': 'Child lock',
'platform': 'tuya',
'previous_unique_id': None,
'suggested_object_id': None,
'supported_features': 0,
'translation_key': 'child_lock',
'unique_id': 'tuya.bf8d64588f4a61965ezszschild_lock',
'unit_of_measurement': None,
})
# ---
# name: test_platform_setup_and_discovery[wk_y5obtqhuztqsf2mj][switch.term_prizemi_child_lock-state]
StateSnapshot({
'attributes': ReadOnlyDict({
'friendly_name': 'Term - Prizemi Child lock',
}),
'context': <ANY>,
'entity_id': 'switch.term_prizemi_child_lock',
'last_changed': <ANY>,
'last_reported': <ANY>,
'last_updated': <ANY>,
'state': 'off',
})
# ---