1
mirror of https://github.com/home-assistant/core synced 2024-09-03 08:14:07 +02:00

Fix UniFi Protect write rate sensor (#73759)

This commit is contained in:
Christopher Bailey 2022-06-20 20:10:59 -04:00 committed by GitHub
parent 4bc1314499
commit b956d125f9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -171,7 +171,7 @@ CAMERA_SENSORS: tuple[ProtectSensorEntityDescription, ...] = (
native_unit_of_measurement=DATA_RATE_BYTES_PER_SECOND,
entity_category=EntityCategory.DIAGNOSTIC,
state_class=SensorStateClass.MEASUREMENT,
ufp_value="stats.storage.rate",
ufp_value="stats.storage.rate_per_second",
precision=2,
),
ProtectSensorEntityDescription(

View File

@ -159,7 +159,7 @@ async def camera_fixture(
camera_obj.stats.video.recording_start = now
camera_obj.stats.storage.used = 100.0
camera_obj.stats.storage.used = 100.0
camera_obj.stats.storage.rate = 100.0
camera_obj.stats.storage.rate = 0.1
camera_obj.voltage = 20.0
mock_entry.api.bootstrap.reset_objects()