mirror of
https://github.com/home-assistant/core.git
synced 2025-07-15 17:27:10 +00:00
After merge, review. (#51139)
This commit is contained in:
parent
fdfb84e8e2
commit
8d365e8bf5
@ -52,8 +52,7 @@ async def async_setup_platform(
|
||||
hub = hass.data[MODBUS_DOMAIN][discovery_info[CONF_NAME]]
|
||||
sensors.append(ModbusRegisterSensor(hub, entry))
|
||||
|
||||
if len(sensors) > 0:
|
||||
async_add_entities(sensors)
|
||||
async_add_entities(sensors)
|
||||
|
||||
|
||||
class ModbusRegisterSensor(BasePlatform, RestoreEntity, SensorEntity):
|
||||
|
@ -210,7 +210,7 @@ async def test_config_wrong_struct_sensor(
|
||||
expect_setup_to_fail=True,
|
||||
)
|
||||
|
||||
assert error_message in "".join(caplog.messages)
|
||||
assert error_message in caplog.text
|
||||
|
||||
|
||||
@pytest.mark.parametrize(
|
||||
|
Loading…
x
Reference in New Issue
Block a user