mirror of
https://github.com/home-assistant/core.git
synced 2025-07-21 12:17:07 +00:00
Bump nettigo_air_monitor
library to version 1.1.1 (#57483)
This commit is contained in:
parent
b72f1553ea
commit
8ee6662cff
@ -34,6 +34,8 @@ SUFFIX_P4: Final = "_p4"
|
||||
ATTR_BME280_HUMIDITY: Final = "bme280_humidity"
|
||||
ATTR_BME280_PRESSURE: Final = "bme280_pressure"
|
||||
ATTR_BME280_TEMPERATURE: Final = "bme280_temperature"
|
||||
ATTR_BMP180_PRESSURE: Final = "bmp180_pressure"
|
||||
ATTR_BMP180_TEMPERATURE: Final = "bmp180_temperature"
|
||||
ATTR_BMP280_PRESSURE: Final = "bmp280_pressure"
|
||||
ATTR_BMP280_TEMPERATURE: Final = "bmp280_temperature"
|
||||
ATTR_DHT22_HUMIDITY: Final = "dht22_humidity"
|
||||
@ -86,6 +88,20 @@ SENSORS: Final[tuple[SensorEntityDescription, ...]] = (
|
||||
device_class=DEVICE_CLASS_TEMPERATURE,
|
||||
state_class=STATE_CLASS_MEASUREMENT,
|
||||
),
|
||||
SensorEntityDescription(
|
||||
key=ATTR_BMP180_PRESSURE,
|
||||
name=f"{DEFAULT_NAME} BMP180 Pressure",
|
||||
native_unit_of_measurement=PRESSURE_HPA,
|
||||
device_class=DEVICE_CLASS_PRESSURE,
|
||||
state_class=STATE_CLASS_MEASUREMENT,
|
||||
),
|
||||
SensorEntityDescription(
|
||||
key=ATTR_BMP180_TEMPERATURE,
|
||||
name=f"{DEFAULT_NAME} BMP180 Temperature",
|
||||
native_unit_of_measurement=TEMP_CELSIUS,
|
||||
device_class=DEVICE_CLASS_TEMPERATURE,
|
||||
state_class=STATE_CLASS_MEASUREMENT,
|
||||
),
|
||||
SensorEntityDescription(
|
||||
key=ATTR_BMP280_PRESSURE,
|
||||
name=f"{DEFAULT_NAME} BMP280 Pressure",
|
||||
|
@ -3,7 +3,7 @@
|
||||
"name": "Nettigo Air Monitor",
|
||||
"documentation": "https://www.home-assistant.io/integrations/nam",
|
||||
"codeowners": ["@bieniu"],
|
||||
"requirements": ["nettigo-air-monitor==1.1.0"],
|
||||
"requirements": ["nettigo-air-monitor==1.1.1"],
|
||||
"zeroconf": [
|
||||
{
|
||||
"type": "_http._tcp.local.",
|
||||
|
@ -1050,7 +1050,7 @@ netdisco==3.0.0
|
||||
netmap==0.7.0.2
|
||||
|
||||
# homeassistant.components.nam
|
||||
nettigo-air-monitor==1.1.0
|
||||
nettigo-air-monitor==1.1.1
|
||||
|
||||
# homeassistant.components.neurio_energy
|
||||
neurio==0.3.1
|
||||
|
@ -621,7 +621,7 @@ netdisco==3.0.0
|
||||
netmap==0.7.0.2
|
||||
|
||||
# homeassistant.components.nam
|
||||
nettigo-air-monitor==1.1.0
|
||||
nettigo-air-monitor==1.1.1
|
||||
|
||||
# homeassistant.components.nexia
|
||||
nexia==0.9.11
|
||||
|
@ -24,6 +24,8 @@ nam_data = {
|
||||
{"value_type": "BME280_temperature", "value": "7.56"},
|
||||
{"value_type": "BME280_humidity", "value": "45.69"},
|
||||
{"value_type": "BME280_pressure", "value": "101101.17"},
|
||||
{"value_type": "BMP_temperature", "value": "7.56"},
|
||||
{"value_type": "BMP_pressure", "value": "103201.18"},
|
||||
{"value_type": "BMP280_temperature", "value": "5.56"},
|
||||
{"value_type": "BMP280_pressure", "value": "102201.18"},
|
||||
{"value_type": "SHT3X_temperature", "value": "6.28"},
|
||||
|
@ -97,6 +97,28 @@ async def test_sensor(hass):
|
||||
assert entry
|
||||
assert entry.unique_id == "aa:bb:cc:dd:ee:ff-bme280_pressure"
|
||||
|
||||
state = hass.states.get("sensor.nettigo_air_monitor_bmp180_temperature")
|
||||
assert state
|
||||
assert state.state == "7.6"
|
||||
assert state.attributes.get(ATTR_DEVICE_CLASS) == DEVICE_CLASS_TEMPERATURE
|
||||
assert state.attributes.get(ATTR_STATE_CLASS) == STATE_CLASS_MEASUREMENT
|
||||
assert state.attributes.get(ATTR_UNIT_OF_MEASUREMENT) == TEMP_CELSIUS
|
||||
|
||||
entry = registry.async_get("sensor.nettigo_air_monitor_bmp180_temperature")
|
||||
assert entry
|
||||
assert entry.unique_id == "aa:bb:cc:dd:ee:ff-bmp180_temperature"
|
||||
|
||||
state = hass.states.get("sensor.nettigo_air_monitor_bmp180_pressure")
|
||||
assert state
|
||||
assert state.state == "1032"
|
||||
assert state.attributes.get(ATTR_DEVICE_CLASS) == DEVICE_CLASS_PRESSURE
|
||||
assert state.attributes.get(ATTR_STATE_CLASS) == STATE_CLASS_MEASUREMENT
|
||||
assert state.attributes.get(ATTR_UNIT_OF_MEASUREMENT) == PRESSURE_HPA
|
||||
|
||||
entry = registry.async_get("sensor.nettigo_air_monitor_bmp180_pressure")
|
||||
assert entry
|
||||
assert entry.unique_id == "aa:bb:cc:dd:ee:ff-bmp180_pressure"
|
||||
|
||||
state = hass.states.get("sensor.nettigo_air_monitor_bmp280_temperature")
|
||||
assert state
|
||||
assert state.state == "5.6"
|
||||
|
Loading…
x
Reference in New Issue
Block a user