Refactorisation and complete #137

This commit is contained in:
Jean-Marc Collin
2023-10-29 09:20:06 +00:00
parent 4905c93a51
commit 1cc47626c7
6 changed files with 510 additions and 341 deletions

View File

@@ -140,7 +140,7 @@ async def test_sensors_over_switch(
entity.incremente_energy()
await energy_sensor.async_my_climate_changed()
assert energy_sensor.state == 16.667
assert energy_sensor.state == round(16.667, 2)
assert energy_sensor.device_class == SensorDeviceClass.ENERGY
assert energy_sensor.state_class == SensorStateClass.TOTAL_INCREASING
# because device_power is 200