feat: add native status bindings for hydraulic circuits and freshwater stations
This commit is contained in:
1 parent
984d9af232
commit
2407e09456
21 files changed
+1073
-974
No files matched your search
@@ -47,11 +47,13 @@ def test_freshwater_cascade_station_links_buffer_reference_and_limits() -> None:
|
||||
"hot_water": "climate.3",
|
||||
"cold_water": "cover.4",
|
||||
"power": "sensor.5",
|
||||
"status": "cover.10",
|
||||
"pump": {"command": "light.6", "feedback": "cover.7"},
|
||||
"valve": {"feedback": "climate.8"},
|
||||
"has_valve": True,
|
||||
}
|
||||
hydraulic = {
|
||||
"status": "lock.11",
|
||||
"stations": [{**station, "id": f"s{i}"} for i in range(4)],
|
||||
"buffer_id": "buffer",
|
||||
"circulation": {"feedback": "cover.9"},
|
||||
@@ -63,6 +65,8 @@ def test_freshwater_cascade_station_links_buffer_reference_and_limits() -> None:
|
||||
{"stations": []},
|
||||
{"stations": [station] * 17},
|
||||
{"stations": [{**station, "power": 123}]},
|
||||
{"stations": [{**station, "status": 123}]},
|
||||
{"status": 123},
|
||||
{"buffer_id": 123},
|
||||
):
|
||||
with pytest.raises(vol.Invalid):
|
||||
@@ -266,9 +270,11 @@ def test_hydronic_circuits_buffer_probes_and_fresh_water_bindings() -> None:
|
||||
"has_valve": False,
|
||||
"pump": control,
|
||||
"valve_type": "mixing",
|
||||
"status": "cover.7",
|
||||
}
|
||||
hydronic = {
|
||||
"card": True,
|
||||
"status": "lock.8",
|
||||
"circuits": [circuit],
|
||||
"sensors": [{"id": f"s{i}", "name": f"Fühler {i}", "entity": None, "level": i / 6} for i in range(7)],
|
||||
"flow": "light.3",
|
||||
@@ -281,6 +287,7 @@ def test_hydronic_circuits_buffer_probes_and_fresh_water_bindings() -> None:
|
||||
for bad in (
|
||||
{"circuits": [{**circuit, "kind": "guess_from_name"}]},
|
||||
{"circuits": [{**circuit, "valve_type": "unknown"}]},
|
||||
{"circuits": [{**circuit, "status": 123}]},
|
||||
{"circuits": [circuit] * 33},
|
||||
{"sensors": [{"id": "s", "name": "Fühler", "entity": None, "level": 1.01}]},
|
||||
{"pump": {"command": 12345}},
|
||||
|
||||
Reference in new issue
Block a user