Flow rate unit conversions and device class (#106077)

* Add volume flow rate conversions

* Add missing translations

* Adjust liter unit and add gallons per minute

* Adjust to min instead of m for minutes

* Add matching class for number

* Add some tests for number and sensor platform

* Add deprecated constants

* Add explicit list of flow rate for check

This reverts commit 105171af31.
This commit is contained in:
Joakim Plate 2024-01-30 15:01:08 +01:00 committed by GitHub
parent a8e3df7e50
commit cece117c93
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
14 changed files with 180 additions and 3 deletions

View file

@ -1042,7 +1042,9 @@ class UnitOfVolumeFlowRate(StrEnum):
"""Volume flow rate units."""
CUBIC_METERS_PER_HOUR = "m³/h"
CUBIC_FEET_PER_MINUTE = "ft³/m"
CUBIC_FEET_PER_MINUTE = "ft³/min"
LITERS_PER_MINUTE = "L/min"
GALLONS_PER_MINUTE = "gal/min"
_DEPRECATED_VOLUME_FLOW_RATE_CUBIC_METERS_PER_HOUR: Final = DeprecatedConstantEnum(