Add device support for Bespoke Window AC (issue #87)
The AW06C7155EWAZ window air conditioner (modelNum TP1X_DA_AC_WAC_01001_0000) reports no oneUiVersion and uses the '_WAC_' (Window Air Conditioner) modelNum token instead of the '_RAC_'/'_PRAC_' tokens already handled by for_device_by_model. Add a fallback rule for that token, routing it to the existing airconditioner registry. The device's resource surface (mode/convenient/wind/temperature/power/ filter/humidity) is already fully modeled by the airconditioner capability set, so this is purely a detection-routing fix -- confirmed against the issue #87 diagnostics dump with zero unbound hrefs.
This commit is contained in:
5 files changed
+580
No files matched your search
@@ -231,6 +231,23 @@ def test_registry_reproduces_golden_state_keys_for_caww_tp2():
|
||||
)
|
||||
|
||||
|
||||
def test_registry_reproduces_golden_state_keys_for_window_ac():
|
||||
"""TP1X_DA_AC_WAC_01001_0000 (issue #87, Bespoke Window AC AW06C7155EWAZ)
|
||||
reports no oneUiVersion and carries the '_WAC_' (Window Air Conditioner)
|
||||
token instead of '_RAC_'/'_PRAC_'; resolved via the '_WAC_' modelNum
|
||||
fallback in for_device_by_model. Otherwise binds cleanly against the
|
||||
existing airconditioner registry with zero unbound hrefs."""
|
||||
from tests.conftest import _load_device
|
||||
resources = _load_device('airconditioner_window_ac')
|
||||
golden = json.loads((GOLDEN / 'airconditioner_window_ac.json').read_text())
|
||||
state_keys = _new_state_keys('airconditioner_window_ac', resources)
|
||||
assert set(state_keys) == set(golden['state_keys']), (
|
||||
f"state_keys mismatch:\n"
|
||||
f" extra: {sorted(set(state_keys) - set(golden['state_keys']))}\n"
|
||||
f" missing: {sorted(set(golden['state_keys']) - set(state_keys))}"
|
||||
)
|
||||
|
||||
|
||||
def test_registry_reproduces_golden_state_keys_for_tp1x_rac():
|
||||
"""TP1X_DA-AC-RAC-01001_0000 (issue #38) -- fuller RAC board with display
|
||||
light, self-check, mute-once, and a current-limit setting."""
|
||||
|
||||
Reference in new issue
Block a user