mirror of
https://github.com/python-kasa/python-kasa.git
synced 2025-08-09 20:24:02 +00:00
Add waterleak alert timestamp (#1162)
The T300 reports the timestamp of the last alarm, this exposes it to consumers.
This commit is contained in:
1073
kasa/tests/fixtures/smart/child/T300(EU)_1.0_1.7.0.json
vendored
1073
kasa/tests/fixtures/smart/child/T300(EU)_1.0_1.7.0.json
vendored
File diff suppressed because it is too large
Load Diff
@@ -1,3 +1,4 @@
|
||||
from datetime import datetime
|
||||
from enum import Enum
|
||||
|
||||
import pytest
|
||||
@@ -15,6 +16,8 @@ waterleak = parametrize(
|
||||
("feature", "prop_name", "type"),
|
||||
[
|
||||
("water_alert", "alert", int),
|
||||
# Can be converted to 'datetime | None' after py3.9 support is dropped
|
||||
("water_alert_timestamp", "alert_timestamp", (datetime, type(None))),
|
||||
("water_leak", "status", Enum),
|
||||
],
|
||||
)
|
||||
|
Reference in New Issue
Block a user