mirror of
https://github.com/home-assistant/core.git
synced 2025-07-18 10:47:10 +00:00
Add tuya snapshots for qxj category (#148802)
This commit is contained in:
parent
cd94685b7d
commit
b89b248b4c
@ -75,6 +75,14 @@ DEVICE_MOCKS = {
|
||||
Platform.BINARY_SENSOR,
|
||||
Platform.SENSOR,
|
||||
],
|
||||
"qxj_temp_humidity_external_probe": [
|
||||
# https://github.com/home-assistant/core/issues/136472
|
||||
Platform.SENSOR,
|
||||
],
|
||||
"qxj_weather_station": [
|
||||
# https://github.com/orgs/home-assistant/discussions/318
|
||||
Platform.SENSOR,
|
||||
],
|
||||
"rqbj_gas_sensor": [
|
||||
# https://github.com/orgs/home-assistant/discussions/100
|
||||
Platform.BINARY_SENSOR,
|
||||
|
@ -0,0 +1,65 @@
|
||||
{
|
||||
"endpoint": "https://apigw.tuyaeu.com",
|
||||
"terminal_id": "1708196692712PHOeqy",
|
||||
"mqtt_connected": true,
|
||||
"disabled_by": null,
|
||||
"disabled_polling": false,
|
||||
"id": "bff00f6abe0563b284t77p",
|
||||
"name": "Frysen",
|
||||
"category": "qxj",
|
||||
"product_id": "is2indt9nlth6esa",
|
||||
"product_name": "T & H Sensor with external probe",
|
||||
"online": true,
|
||||
"sub": false,
|
||||
"time_zone": "+01:00",
|
||||
"active_time": "2025-01-27T15:19:27+00:00",
|
||||
"create_time": "2025-01-27T15:19:27+00:00",
|
||||
"update_time": "2025-01-27T15:19:27+00:00",
|
||||
"function": {},
|
||||
"status_range": {
|
||||
"temp_current": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "\u2103",
|
||||
"min": -99,
|
||||
"max": 600,
|
||||
"scale": 1,
|
||||
"step": 1
|
||||
}
|
||||
},
|
||||
"humidity_value": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "%",
|
||||
"min": 0,
|
||||
"max": 100,
|
||||
"scale": 0,
|
||||
"step": 1
|
||||
}
|
||||
},
|
||||
"battery_state": {
|
||||
"type": "Enum",
|
||||
"value": {
|
||||
"range": ["low", "middle", "high"]
|
||||
}
|
||||
},
|
||||
"temp_current_external": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "\u2103",
|
||||
"min": -400,
|
||||
"max": 1200,
|
||||
"scale": 1,
|
||||
"step": 1
|
||||
}
|
||||
}
|
||||
},
|
||||
"status": {
|
||||
"temp_current": 222,
|
||||
"humidity_value": 38,
|
||||
"battery_state": "high",
|
||||
"temp_current_external": -130
|
||||
},
|
||||
"set_up": false,
|
||||
"support_local": true
|
||||
}
|
412
tests/components/tuya/fixtures/qxj_weather_station.json
Normal file
412
tests/components/tuya/fixtures/qxj_weather_station.json
Normal file
@ -0,0 +1,412 @@
|
||||
{
|
||||
"endpoint": "https://apigw.tuyaeu.com",
|
||||
"terminal_id": "1751921699759JsVujI",
|
||||
"mqtt_connected": true,
|
||||
"disabled_by": null,
|
||||
"disabled_polling": false,
|
||||
"id": "bf84c743a84eb2c8abeurz",
|
||||
"name": "BR 7-in-1 WLAN Wetterstation Anthrazit",
|
||||
"category": "qxj",
|
||||
"product_id": "fsea1lat3vuktbt6",
|
||||
"product_name": "BR 7-in-1 WLAN Wetterstation Anthrazit",
|
||||
"online": true,
|
||||
"sub": false,
|
||||
"time_zone": "+02:00",
|
||||
"active_time": "2025-07-07T17:43:41+00:00",
|
||||
"create_time": "2025-07-07T17:43:41+00:00",
|
||||
"update_time": "2025-07-07T17:43:41+00:00",
|
||||
"function": {
|
||||
"temp_unit_convert": {
|
||||
"type": "Enum",
|
||||
"value": {
|
||||
"range": ["c", "f"]
|
||||
}
|
||||
},
|
||||
"windspeed_unit_convert": {
|
||||
"type": "Enum",
|
||||
"value": {
|
||||
"range": ["mph"]
|
||||
}
|
||||
},
|
||||
"pressure_unit_convert": {
|
||||
"type": "Enum",
|
||||
"value": {
|
||||
"range": ["hpa", "inhg", "mmhg"]
|
||||
}
|
||||
},
|
||||
"rain_unit_convert": {
|
||||
"type": "Enum",
|
||||
"value": {
|
||||
"range": ["mm", "inch"]
|
||||
}
|
||||
},
|
||||
"bright_unit_convert": {
|
||||
"type": "Enum",
|
||||
"value": {
|
||||
"range": ["lux", "fc", "wm2"]
|
||||
}
|
||||
}
|
||||
},
|
||||
"status_range": {
|
||||
"temp_current": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "\u2103",
|
||||
"min": -400,
|
||||
"max": 600,
|
||||
"scale": 1,
|
||||
"step": 1
|
||||
}
|
||||
},
|
||||
"humidity_value": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "%",
|
||||
"min": 0,
|
||||
"max": 100,
|
||||
"scale": 0,
|
||||
"step": 1
|
||||
}
|
||||
},
|
||||
"battery_state": {
|
||||
"type": "Enum",
|
||||
"value": {
|
||||
"range": ["low", "high"]
|
||||
}
|
||||
},
|
||||
"temp_unit_convert": {
|
||||
"type": "Enum",
|
||||
"value": {
|
||||
"range": ["c", "f"]
|
||||
}
|
||||
},
|
||||
"windspeed_unit_convert": {
|
||||
"type": "Enum",
|
||||
"value": {
|
||||
"range": ["mph"]
|
||||
}
|
||||
},
|
||||
"pressure_unit_convert": {
|
||||
"type": "Enum",
|
||||
"value": {
|
||||
"range": ["hpa", "inhg", "mmhg"]
|
||||
}
|
||||
},
|
||||
"rain_unit_convert": {
|
||||
"type": "Enum",
|
||||
"value": {
|
||||
"range": ["mm", "inch"]
|
||||
}
|
||||
},
|
||||
"bright_unit_convert": {
|
||||
"type": "Enum",
|
||||
"value": {
|
||||
"range": ["lux", "fc", "wm2"]
|
||||
}
|
||||
},
|
||||
"fault_type": {
|
||||
"type": "Enum",
|
||||
"value": {
|
||||
"range": [
|
||||
"normal",
|
||||
"ch1_offline",
|
||||
"ch2_offline",
|
||||
"ch3_offline",
|
||||
"offline"
|
||||
]
|
||||
}
|
||||
},
|
||||
"battery_status": {
|
||||
"type": "Enum",
|
||||
"value": {
|
||||
"range": ["low", "high"]
|
||||
}
|
||||
},
|
||||
"battery_state_1": {
|
||||
"type": "Enum",
|
||||
"value": {
|
||||
"range": ["low", "high"]
|
||||
}
|
||||
},
|
||||
"battery_state_2": {
|
||||
"type": "Enum",
|
||||
"value": {
|
||||
"range": ["low", "high"]
|
||||
}
|
||||
},
|
||||
"battery_state_3": {
|
||||
"type": "Enum",
|
||||
"value": {
|
||||
"range": ["low", "high"]
|
||||
}
|
||||
},
|
||||
"temp_current_external": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "\u2103",
|
||||
"min": -400,
|
||||
"max": 600,
|
||||
"scale": 1,
|
||||
"step": 1
|
||||
}
|
||||
},
|
||||
"humidity_outdoor": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "%",
|
||||
"min": 0,
|
||||
"max": 100,
|
||||
"scale": 0,
|
||||
"step": 1
|
||||
}
|
||||
},
|
||||
"temp_current_external_1": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "\u2103",
|
||||
"min": -400,
|
||||
"max": 600,
|
||||
"scale": 1,
|
||||
"step": 1
|
||||
}
|
||||
},
|
||||
"humidity_outdoor_1": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "%",
|
||||
"min": 0,
|
||||
"max": 100,
|
||||
"scale": 0,
|
||||
"step": 1
|
||||
}
|
||||
},
|
||||
"temp_current_external_2": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "\u2103",
|
||||
"min": -400,
|
||||
"max": 600,
|
||||
"scale": 1,
|
||||
"step": 1
|
||||
}
|
||||
},
|
||||
"humidity_outdoor_2": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "%",
|
||||
"min": 0,
|
||||
"max": 100,
|
||||
"scale": 0,
|
||||
"step": 1
|
||||
}
|
||||
},
|
||||
"temp_current_external_3": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "\u2103",
|
||||
"min": -400,
|
||||
"max": 600,
|
||||
"scale": 1,
|
||||
"step": 1
|
||||
}
|
||||
},
|
||||
"humidity_outdoor_3": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "%",
|
||||
"min": 0,
|
||||
"max": 100,
|
||||
"scale": 0,
|
||||
"step": 1
|
||||
}
|
||||
},
|
||||
"atmospheric_pressture": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "hPa",
|
||||
"min": 3000,
|
||||
"max": 12000,
|
||||
"scale": 1,
|
||||
"step": 1
|
||||
}
|
||||
},
|
||||
"pressure_drop": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "hPa",
|
||||
"min": 0,
|
||||
"max": 15,
|
||||
"scale": 0,
|
||||
"step": 1
|
||||
}
|
||||
},
|
||||
"windspeed_avg": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "m/s",
|
||||
"min": 0,
|
||||
"max": 700,
|
||||
"scale": 1,
|
||||
"step": 1
|
||||
}
|
||||
},
|
||||
"windspeed_gust": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "m/s",
|
||||
"min": 0,
|
||||
"max": 700,
|
||||
"scale": 1,
|
||||
"step": 1
|
||||
}
|
||||
},
|
||||
"wind_direct": {
|
||||
"type": "Enum",
|
||||
"value": {
|
||||
"range": [
|
||||
"north",
|
||||
"north_north_east",
|
||||
"north_east",
|
||||
"east_north_east",
|
||||
"east",
|
||||
"east_south_east",
|
||||
"south_east",
|
||||
"south_south_east",
|
||||
"south",
|
||||
"south_south_west",
|
||||
"south_west",
|
||||
"west_south_west",
|
||||
"west",
|
||||
"west_north_west",
|
||||
"north_west",
|
||||
"north_north_west"
|
||||
]
|
||||
}
|
||||
},
|
||||
"rain_24h": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "mm",
|
||||
"min": 0,
|
||||
"max": 1000000,
|
||||
"scale": 3,
|
||||
"step": 1
|
||||
}
|
||||
},
|
||||
"rain_rate": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "mm",
|
||||
"min": 0,
|
||||
"max": 999999,
|
||||
"scale": 3,
|
||||
"step": 1
|
||||
}
|
||||
},
|
||||
"uv_index": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "",
|
||||
"min": 0,
|
||||
"max": 180,
|
||||
"scale": 1,
|
||||
"step": 1
|
||||
}
|
||||
},
|
||||
"bright_value": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "lux",
|
||||
"min": 0,
|
||||
"max": 238000,
|
||||
"scale": 0,
|
||||
"step": 100
|
||||
}
|
||||
},
|
||||
"dew_point_temp": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "\u2103",
|
||||
"min": -400,
|
||||
"max": 800,
|
||||
"scale": 1,
|
||||
"step": 1
|
||||
}
|
||||
},
|
||||
"feellike_temp": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "\u2103",
|
||||
"min": -650,
|
||||
"max": 500,
|
||||
"scale": 1,
|
||||
"step": 1
|
||||
}
|
||||
},
|
||||
"heat_index": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "\u2103",
|
||||
"min": 260,
|
||||
"max": 500,
|
||||
"scale": 1,
|
||||
"step": 1
|
||||
}
|
||||
},
|
||||
"windchill_index": {
|
||||
"type": "Integer",
|
||||
"value": {
|
||||
"unit": "\u2103",
|
||||
"min": -650,
|
||||
"max": 600,
|
||||
"scale": 1,
|
||||
"step": 1
|
||||
}
|
||||
},
|
||||
"com_index": {
|
||||
"type": "Enum",
|
||||
"value": {
|
||||
"range": ["moist", "dry", "comfortable"]
|
||||
}
|
||||
}
|
||||
},
|
||||
"status": {
|
||||
"temp_current": 240,
|
||||
"humidity_value": 52,
|
||||
"battery_state": "high",
|
||||
"temp_unit_convert": "c",
|
||||
"windspeed_unit_convert": "m_s",
|
||||
"pressure_unit_convert": "hpa",
|
||||
"rain_unit_convert": "mm",
|
||||
"bright_unit_convert": "lux",
|
||||
"fault_type": "normal",
|
||||
"battery_status": "low",
|
||||
"battery_state_1": "high",
|
||||
"battery_state_2": "high",
|
||||
"battery_state_3": "low",
|
||||
"temp_current_external": -400,
|
||||
"humidity_outdoor": 0,
|
||||
"temp_current_external_1": 193,
|
||||
"humidity_outdoor_1": 99,
|
||||
"temp_current_external_2": 252,
|
||||
"humidity_outdoor_2": 0,
|
||||
"temp_current_external_3": -400,
|
||||
"humidity_outdoor_3": 0,
|
||||
"atmospheric_pressture": 10040,
|
||||
"pressure_drop": 0,
|
||||
"windspeed_avg": 0,
|
||||
"windspeed_gust": 0,
|
||||
"wind_direct": "none",
|
||||
"rain_24h": 0,
|
||||
"rain_rate": 0,
|
||||
"uv_index": 0,
|
||||
"bright_value": 0,
|
||||
"dew_point_temp": -400,
|
||||
"feellike_temp": -650,
|
||||
"heat_index": 260,
|
||||
"windchill_index": -650,
|
||||
"com_index": "none"
|
||||
},
|
||||
"set_up": false,
|
||||
"support_local": true
|
||||
}
|
@ -1265,6 +1265,485 @@
|
||||
'state': '100.0',
|
||||
})
|
||||
# ---
|
||||
# name: test_platform_setup_and_discovery[qxj_temp_humidity_external_probe][sensor.frysen_battery_state-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': 'sensor',
|
||||
'entity_category': <EntityCategory.DIAGNOSTIC: 'diagnostic'>,
|
||||
'entity_id': 'sensor.frysen_battery_state',
|
||||
'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': 'Battery state',
|
||||
'platform': 'tuya',
|
||||
'previous_unique_id': None,
|
||||
'suggested_object_id': None,
|
||||
'supported_features': 0,
|
||||
'translation_key': 'battery_state',
|
||||
'unique_id': 'tuya.bff00f6abe0563b284t77pbattery_state',
|
||||
'unit_of_measurement': None,
|
||||
})
|
||||
# ---
|
||||
# name: test_platform_setup_and_discovery[qxj_temp_humidity_external_probe][sensor.frysen_battery_state-state]
|
||||
StateSnapshot({
|
||||
'attributes': ReadOnlyDict({
|
||||
'friendly_name': 'Frysen Battery state',
|
||||
}),
|
||||
'context': <ANY>,
|
||||
'entity_id': 'sensor.frysen_battery_state',
|
||||
'last_changed': <ANY>,
|
||||
'last_reported': <ANY>,
|
||||
'last_updated': <ANY>,
|
||||
'state': 'high',
|
||||
})
|
||||
# ---
|
||||
# name: test_platform_setup_and_discovery[qxj_temp_humidity_external_probe][sensor.frysen_humidity-entry]
|
||||
EntityRegistryEntrySnapshot({
|
||||
'aliases': set({
|
||||
}),
|
||||
'area_id': None,
|
||||
'capabilities': dict({
|
||||
'state_class': <SensorStateClass.MEASUREMENT: 'measurement'>,
|
||||
}),
|
||||
'config_entry_id': <ANY>,
|
||||
'config_subentry_id': <ANY>,
|
||||
'device_class': None,
|
||||
'device_id': <ANY>,
|
||||
'disabled_by': None,
|
||||
'domain': 'sensor',
|
||||
'entity_category': None,
|
||||
'entity_id': 'sensor.frysen_humidity',
|
||||
'has_entity_name': True,
|
||||
'hidden_by': None,
|
||||
'icon': None,
|
||||
'id': <ANY>,
|
||||
'labels': set({
|
||||
}),
|
||||
'name': None,
|
||||
'options': dict({
|
||||
}),
|
||||
'original_device_class': <SensorDeviceClass.HUMIDITY: 'humidity'>,
|
||||
'original_icon': None,
|
||||
'original_name': 'Humidity',
|
||||
'platform': 'tuya',
|
||||
'previous_unique_id': None,
|
||||
'suggested_object_id': None,
|
||||
'supported_features': 0,
|
||||
'translation_key': 'humidity',
|
||||
'unique_id': 'tuya.bff00f6abe0563b284t77phumidity_value',
|
||||
'unit_of_measurement': '%',
|
||||
})
|
||||
# ---
|
||||
# name: test_platform_setup_and_discovery[qxj_temp_humidity_external_probe][sensor.frysen_humidity-state]
|
||||
StateSnapshot({
|
||||
'attributes': ReadOnlyDict({
|
||||
'device_class': 'humidity',
|
||||
'friendly_name': 'Frysen Humidity',
|
||||
'state_class': <SensorStateClass.MEASUREMENT: 'measurement'>,
|
||||
'unit_of_measurement': '%',
|
||||
}),
|
||||
'context': <ANY>,
|
||||
'entity_id': 'sensor.frysen_humidity',
|
||||
'last_changed': <ANY>,
|
||||
'last_reported': <ANY>,
|
||||
'last_updated': <ANY>,
|
||||
'state': '38.0',
|
||||
})
|
||||
# ---
|
||||
# name: test_platform_setup_and_discovery[qxj_temp_humidity_external_probe][sensor.frysen_probe_temperature-entry]
|
||||
EntityRegistryEntrySnapshot({
|
||||
'aliases': set({
|
||||
}),
|
||||
'area_id': None,
|
||||
'capabilities': dict({
|
||||
'state_class': <SensorStateClass.MEASUREMENT: 'measurement'>,
|
||||
}),
|
||||
'config_entry_id': <ANY>,
|
||||
'config_subentry_id': <ANY>,
|
||||
'device_class': None,
|
||||
'device_id': <ANY>,
|
||||
'disabled_by': None,
|
||||
'domain': 'sensor',
|
||||
'entity_category': None,
|
||||
'entity_id': 'sensor.frysen_probe_temperature',
|
||||
'has_entity_name': True,
|
||||
'hidden_by': None,
|
||||
'icon': None,
|
||||
'id': <ANY>,
|
||||
'labels': set({
|
||||
}),
|
||||
'name': None,
|
||||
'options': dict({
|
||||
'sensor': dict({
|
||||
'suggested_display_precision': 1,
|
||||
}),
|
||||
}),
|
||||
'original_device_class': <SensorDeviceClass.TEMPERATURE: 'temperature'>,
|
||||
'original_icon': None,
|
||||
'original_name': 'Probe temperature',
|
||||
'platform': 'tuya',
|
||||
'previous_unique_id': None,
|
||||
'suggested_object_id': None,
|
||||
'supported_features': 0,
|
||||
'translation_key': 'temperature_external',
|
||||
'unique_id': 'tuya.bff00f6abe0563b284t77ptemp_current_external',
|
||||
'unit_of_measurement': <UnitOfTemperature.CELSIUS: '°C'>,
|
||||
})
|
||||
# ---
|
||||
# name: test_platform_setup_and_discovery[qxj_temp_humidity_external_probe][sensor.frysen_probe_temperature-state]
|
||||
StateSnapshot({
|
||||
'attributes': ReadOnlyDict({
|
||||
'device_class': 'temperature',
|
||||
'friendly_name': 'Frysen Probe temperature',
|
||||
'state_class': <SensorStateClass.MEASUREMENT: 'measurement'>,
|
||||
'unit_of_measurement': <UnitOfTemperature.CELSIUS: '°C'>,
|
||||
}),
|
||||
'context': <ANY>,
|
||||
'entity_id': 'sensor.frysen_probe_temperature',
|
||||
'last_changed': <ANY>,
|
||||
'last_reported': <ANY>,
|
||||
'last_updated': <ANY>,
|
||||
'state': '-13.0',
|
||||
})
|
||||
# ---
|
||||
# name: test_platform_setup_and_discovery[qxj_temp_humidity_external_probe][sensor.frysen_temperature-entry]
|
||||
EntityRegistryEntrySnapshot({
|
||||
'aliases': set({
|
||||
}),
|
||||
'area_id': None,
|
||||
'capabilities': dict({
|
||||
'state_class': <SensorStateClass.MEASUREMENT: 'measurement'>,
|
||||
}),
|
||||
'config_entry_id': <ANY>,
|
||||
'config_subentry_id': <ANY>,
|
||||
'device_class': None,
|
||||
'device_id': <ANY>,
|
||||
'disabled_by': None,
|
||||
'domain': 'sensor',
|
||||
'entity_category': None,
|
||||
'entity_id': 'sensor.frysen_temperature',
|
||||
'has_entity_name': True,
|
||||
'hidden_by': None,
|
||||
'icon': None,
|
||||
'id': <ANY>,
|
||||
'labels': set({
|
||||
}),
|
||||
'name': None,
|
||||
'options': dict({
|
||||
'sensor': dict({
|
||||
'suggested_display_precision': 1,
|
||||
}),
|
||||
}),
|
||||
'original_device_class': <SensorDeviceClass.TEMPERATURE: 'temperature'>,
|
||||
'original_icon': None,
|
||||
'original_name': 'Temperature',
|
||||
'platform': 'tuya',
|
||||
'previous_unique_id': None,
|
||||
'suggested_object_id': None,
|
||||
'supported_features': 0,
|
||||
'translation_key': 'temperature',
|
||||
'unique_id': 'tuya.bff00f6abe0563b284t77ptemp_current',
|
||||
'unit_of_measurement': <UnitOfTemperature.CELSIUS: '°C'>,
|
||||
})
|
||||
# ---
|
||||
# name: test_platform_setup_and_discovery[qxj_temp_humidity_external_probe][sensor.frysen_temperature-state]
|
||||
StateSnapshot({
|
||||
'attributes': ReadOnlyDict({
|
||||
'device_class': 'temperature',
|
||||
'friendly_name': 'Frysen Temperature',
|
||||
'state_class': <SensorStateClass.MEASUREMENT: 'measurement'>,
|
||||
'unit_of_measurement': <UnitOfTemperature.CELSIUS: '°C'>,
|
||||
}),
|
||||
'context': <ANY>,
|
||||
'entity_id': 'sensor.frysen_temperature',
|
||||
'last_changed': <ANY>,
|
||||
'last_reported': <ANY>,
|
||||
'last_updated': <ANY>,
|
||||
'state': '22.2',
|
||||
})
|
||||
# ---
|
||||
# name: test_platform_setup_and_discovery[qxj_weather_station][sensor.br_7_in_1_wlan_wetterstation_anthrazit_battery_state-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': 'sensor',
|
||||
'entity_category': <EntityCategory.DIAGNOSTIC: 'diagnostic'>,
|
||||
'entity_id': 'sensor.br_7_in_1_wlan_wetterstation_anthrazit_battery_state',
|
||||
'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': 'Battery state',
|
||||
'platform': 'tuya',
|
||||
'previous_unique_id': None,
|
||||
'suggested_object_id': None,
|
||||
'supported_features': 0,
|
||||
'translation_key': 'battery_state',
|
||||
'unique_id': 'tuya.bf84c743a84eb2c8abeurzbattery_state',
|
||||
'unit_of_measurement': None,
|
||||
})
|
||||
# ---
|
||||
# name: test_platform_setup_and_discovery[qxj_weather_station][sensor.br_7_in_1_wlan_wetterstation_anthrazit_battery_state-state]
|
||||
StateSnapshot({
|
||||
'attributes': ReadOnlyDict({
|
||||
'friendly_name': 'BR 7-in-1 WLAN Wetterstation Anthrazit Battery state',
|
||||
}),
|
||||
'context': <ANY>,
|
||||
'entity_id': 'sensor.br_7_in_1_wlan_wetterstation_anthrazit_battery_state',
|
||||
'last_changed': <ANY>,
|
||||
'last_reported': <ANY>,
|
||||
'last_updated': <ANY>,
|
||||
'state': 'high',
|
||||
})
|
||||
# ---
|
||||
# name: test_platform_setup_and_discovery[qxj_weather_station][sensor.br_7_in_1_wlan_wetterstation_anthrazit_humidity-entry]
|
||||
EntityRegistryEntrySnapshot({
|
||||
'aliases': set({
|
||||
}),
|
||||
'area_id': None,
|
||||
'capabilities': dict({
|
||||
'state_class': <SensorStateClass.MEASUREMENT: 'measurement'>,
|
||||
}),
|
||||
'config_entry_id': <ANY>,
|
||||
'config_subentry_id': <ANY>,
|
||||
'device_class': None,
|
||||
'device_id': <ANY>,
|
||||
'disabled_by': None,
|
||||
'domain': 'sensor',
|
||||
'entity_category': None,
|
||||
'entity_id': 'sensor.br_7_in_1_wlan_wetterstation_anthrazit_humidity',
|
||||
'has_entity_name': True,
|
||||
'hidden_by': None,
|
||||
'icon': None,
|
||||
'id': <ANY>,
|
||||
'labels': set({
|
||||
}),
|
||||
'name': None,
|
||||
'options': dict({
|
||||
}),
|
||||
'original_device_class': <SensorDeviceClass.HUMIDITY: 'humidity'>,
|
||||
'original_icon': None,
|
||||
'original_name': 'Humidity',
|
||||
'platform': 'tuya',
|
||||
'previous_unique_id': None,
|
||||
'suggested_object_id': None,
|
||||
'supported_features': 0,
|
||||
'translation_key': 'humidity',
|
||||
'unique_id': 'tuya.bf84c743a84eb2c8abeurzhumidity_value',
|
||||
'unit_of_measurement': '%',
|
||||
})
|
||||
# ---
|
||||
# name: test_platform_setup_and_discovery[qxj_weather_station][sensor.br_7_in_1_wlan_wetterstation_anthrazit_humidity-state]
|
||||
StateSnapshot({
|
||||
'attributes': ReadOnlyDict({
|
||||
'device_class': 'humidity',
|
||||
'friendly_name': 'BR 7-in-1 WLAN Wetterstation Anthrazit Humidity',
|
||||
'state_class': <SensorStateClass.MEASUREMENT: 'measurement'>,
|
||||
'unit_of_measurement': '%',
|
||||
}),
|
||||
'context': <ANY>,
|
||||
'entity_id': 'sensor.br_7_in_1_wlan_wetterstation_anthrazit_humidity',
|
||||
'last_changed': <ANY>,
|
||||
'last_reported': <ANY>,
|
||||
'last_updated': <ANY>,
|
||||
'state': '52.0',
|
||||
})
|
||||
# ---
|
||||
# name: test_platform_setup_and_discovery[qxj_weather_station][sensor.br_7_in_1_wlan_wetterstation_anthrazit_illuminance-entry]
|
||||
EntityRegistryEntrySnapshot({
|
||||
'aliases': set({
|
||||
}),
|
||||
'area_id': None,
|
||||
'capabilities': dict({
|
||||
'state_class': <SensorStateClass.MEASUREMENT: 'measurement'>,
|
||||
}),
|
||||
'config_entry_id': <ANY>,
|
||||
'config_subentry_id': <ANY>,
|
||||
'device_class': None,
|
||||
'device_id': <ANY>,
|
||||
'disabled_by': None,
|
||||
'domain': 'sensor',
|
||||
'entity_category': None,
|
||||
'entity_id': 'sensor.br_7_in_1_wlan_wetterstation_anthrazit_illuminance',
|
||||
'has_entity_name': True,
|
||||
'hidden_by': None,
|
||||
'icon': None,
|
||||
'id': <ANY>,
|
||||
'labels': set({
|
||||
}),
|
||||
'name': None,
|
||||
'options': dict({
|
||||
}),
|
||||
'original_device_class': <SensorDeviceClass.ILLUMINANCE: 'illuminance'>,
|
||||
'original_icon': None,
|
||||
'original_name': 'Illuminance',
|
||||
'platform': 'tuya',
|
||||
'previous_unique_id': None,
|
||||
'suggested_object_id': None,
|
||||
'supported_features': 0,
|
||||
'translation_key': 'illuminance',
|
||||
'unique_id': 'tuya.bf84c743a84eb2c8abeurzbright_value',
|
||||
'unit_of_measurement': 'lx',
|
||||
})
|
||||
# ---
|
||||
# name: test_platform_setup_and_discovery[qxj_weather_station][sensor.br_7_in_1_wlan_wetterstation_anthrazit_illuminance-state]
|
||||
StateSnapshot({
|
||||
'attributes': ReadOnlyDict({
|
||||
'device_class': 'illuminance',
|
||||
'friendly_name': 'BR 7-in-1 WLAN Wetterstation Anthrazit Illuminance',
|
||||
'state_class': <SensorStateClass.MEASUREMENT: 'measurement'>,
|
||||
'unit_of_measurement': 'lx',
|
||||
}),
|
||||
'context': <ANY>,
|
||||
'entity_id': 'sensor.br_7_in_1_wlan_wetterstation_anthrazit_illuminance',
|
||||
'last_changed': <ANY>,
|
||||
'last_reported': <ANY>,
|
||||
'last_updated': <ANY>,
|
||||
'state': '0.0',
|
||||
})
|
||||
# ---
|
||||
# name: test_platform_setup_and_discovery[qxj_weather_station][sensor.br_7_in_1_wlan_wetterstation_anthrazit_probe_temperature-entry]
|
||||
EntityRegistryEntrySnapshot({
|
||||
'aliases': set({
|
||||
}),
|
||||
'area_id': None,
|
||||
'capabilities': dict({
|
||||
'state_class': <SensorStateClass.MEASUREMENT: 'measurement'>,
|
||||
}),
|
||||
'config_entry_id': <ANY>,
|
||||
'config_subentry_id': <ANY>,
|
||||
'device_class': None,
|
||||
'device_id': <ANY>,
|
||||
'disabled_by': None,
|
||||
'domain': 'sensor',
|
||||
'entity_category': None,
|
||||
'entity_id': 'sensor.br_7_in_1_wlan_wetterstation_anthrazit_probe_temperature',
|
||||
'has_entity_name': True,
|
||||
'hidden_by': None,
|
||||
'icon': None,
|
||||
'id': <ANY>,
|
||||
'labels': set({
|
||||
}),
|
||||
'name': None,
|
||||
'options': dict({
|
||||
'sensor': dict({
|
||||
'suggested_display_precision': 1,
|
||||
}),
|
||||
}),
|
||||
'original_device_class': <SensorDeviceClass.TEMPERATURE: 'temperature'>,
|
||||
'original_icon': None,
|
||||
'original_name': 'Probe temperature',
|
||||
'platform': 'tuya',
|
||||
'previous_unique_id': None,
|
||||
'suggested_object_id': None,
|
||||
'supported_features': 0,
|
||||
'translation_key': 'temperature_external',
|
||||
'unique_id': 'tuya.bf84c743a84eb2c8abeurztemp_current_external',
|
||||
'unit_of_measurement': <UnitOfTemperature.CELSIUS: '°C'>,
|
||||
})
|
||||
# ---
|
||||
# name: test_platform_setup_and_discovery[qxj_weather_station][sensor.br_7_in_1_wlan_wetterstation_anthrazit_probe_temperature-state]
|
||||
StateSnapshot({
|
||||
'attributes': ReadOnlyDict({
|
||||
'device_class': 'temperature',
|
||||
'friendly_name': 'BR 7-in-1 WLAN Wetterstation Anthrazit Probe temperature',
|
||||
'state_class': <SensorStateClass.MEASUREMENT: 'measurement'>,
|
||||
'unit_of_measurement': <UnitOfTemperature.CELSIUS: '°C'>,
|
||||
}),
|
||||
'context': <ANY>,
|
||||
'entity_id': 'sensor.br_7_in_1_wlan_wetterstation_anthrazit_probe_temperature',
|
||||
'last_changed': <ANY>,
|
||||
'last_reported': <ANY>,
|
||||
'last_updated': <ANY>,
|
||||
'state': '-40.0',
|
||||
})
|
||||
# ---
|
||||
# name: test_platform_setup_and_discovery[qxj_weather_station][sensor.br_7_in_1_wlan_wetterstation_anthrazit_temperature-entry]
|
||||
EntityRegistryEntrySnapshot({
|
||||
'aliases': set({
|
||||
}),
|
||||
'area_id': None,
|
||||
'capabilities': dict({
|
||||
'state_class': <SensorStateClass.MEASUREMENT: 'measurement'>,
|
||||
}),
|
||||
'config_entry_id': <ANY>,
|
||||
'config_subentry_id': <ANY>,
|
||||
'device_class': None,
|
||||
'device_id': <ANY>,
|
||||
'disabled_by': None,
|
||||
'domain': 'sensor',
|
||||
'entity_category': None,
|
||||
'entity_id': 'sensor.br_7_in_1_wlan_wetterstation_anthrazit_temperature',
|
||||
'has_entity_name': True,
|
||||
'hidden_by': None,
|
||||
'icon': None,
|
||||
'id': <ANY>,
|
||||
'labels': set({
|
||||
}),
|
||||
'name': None,
|
||||
'options': dict({
|
||||
'sensor': dict({
|
||||
'suggested_display_precision': 1,
|
||||
}),
|
||||
}),
|
||||
'original_device_class': <SensorDeviceClass.TEMPERATURE: 'temperature'>,
|
||||
'original_icon': None,
|
||||
'original_name': 'Temperature',
|
||||
'platform': 'tuya',
|
||||
'previous_unique_id': None,
|
||||
'suggested_object_id': None,
|
||||
'supported_features': 0,
|
||||
'translation_key': 'temperature',
|
||||
'unique_id': 'tuya.bf84c743a84eb2c8abeurztemp_current',
|
||||
'unit_of_measurement': <UnitOfTemperature.CELSIUS: '°C'>,
|
||||
})
|
||||
# ---
|
||||
# name: test_platform_setup_and_discovery[qxj_weather_station][sensor.br_7_in_1_wlan_wetterstation_anthrazit_temperature-state]
|
||||
StateSnapshot({
|
||||
'attributes': ReadOnlyDict({
|
||||
'device_class': 'temperature',
|
||||
'friendly_name': 'BR 7-in-1 WLAN Wetterstation Anthrazit Temperature',
|
||||
'state_class': <SensorStateClass.MEASUREMENT: 'measurement'>,
|
||||
'unit_of_measurement': <UnitOfTemperature.CELSIUS: '°C'>,
|
||||
}),
|
||||
'context': <ANY>,
|
||||
'entity_id': 'sensor.br_7_in_1_wlan_wetterstation_anthrazit_temperature',
|
||||
'last_changed': <ANY>,
|
||||
'last_reported': <ANY>,
|
||||
'last_updated': <ANY>,
|
||||
'state': '24.0',
|
||||
})
|
||||
# ---
|
||||
# name: test_platform_setup_and_discovery[rqbj_gas_sensor][sensor.gas_sensor_gas-entry]
|
||||
EntityRegistryEntrySnapshot({
|
||||
'aliases': set({
|
||||
|
Loading…
x
Reference in New Issue
Block a user