From a1ebe74e4570e25a7a27f9f78f11b7b1d3b3a183 Mon Sep 17 00:00:00 2001 From: Mike Degatano Date: Fri, 8 Nov 2024 20:37:29 +0000 Subject: [PATCH] Add system managed fields --- aiohasupervisor/models/addons.py | 2 ++ tests/fixtures/addons_info.json | 4 +++- tests/test_addons.py | 2 ++ 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/aiohasupervisor/models/addons.py b/aiohasupervisor/models/addons.py index dac0786..b7ae168 100644 --- a/aiohasupervisor/models/addons.py +++ b/aiohasupervisor/models/addons.py @@ -246,6 +246,8 @@ class InstalledAddonComplete( ip_address: IPv4Address watchdog: bool devices: list[str] + system_managed: bool + system_managed_config_entry: str | None @dataclass(frozen=True, slots=True) diff --git a/tests/fixtures/addons_info.json b/tests/fixtures/addons_info.json index 5e2d3a7..5f582b5 100644 --- a/tests/fixtures/addons_info.json +++ b/tests/fixtures/addons_info.json @@ -121,6 +121,8 @@ "version": "9.14.0", "update_available": false, "watchdog": false, - "devices": [] + "devices": [], + "system_managed": false, + "system_managed_config_entry": null } } diff --git a/tests/test_addons.py b/tests/test_addons.py index bd6e395..e17e04f 100644 --- a/tests/test_addons.py +++ b/tests/test_addons.py @@ -62,6 +62,8 @@ async def test_addons_info( assert "not_real" in addon.privileged assert addon.supervisor_api is True assert addon.supervisor_role == SupervisorRole.MANAGER + assert addon.system_managed is False + assert addon.system_managed_config_entry is None async def test_addons_uninstall(