refactor: move samsung_appliance/ into custom_components/localthings/ocf/

Makes the integration fully self-contained for HACS distribution.
Users installing via HACS get everything in one directory; no external
samsung_appliance package needed.

All component imports updated to relative (.ocf.*); all test imports
updated to custom_components.localthings.ocf.*. ocf_root_ca.pem moves
with the package and resolves correctly via Path(__file__).parent.
This commit is contained in:
Marc Billow committed 2026-06-30 16:34:20 -05:00
1 parent 0bb27a9204
commit cc2c1e5a1f
50 files changed
+50 -50

No files matched your search

+4 -4
View File
@@ -7,14 +7,14 @@ GOLDEN = Path(__file__).parent / 'fixtures' / 'golden'
def _new_state_keys(name, resources):
from samsung_appliance.registry.by_type import for_device
from samsung_appliance.registry.discovery import discover
from samsung_appliance.registry.adapter import flatten
from custom_components.localthings.ocf.registry.by_type import for_device
from custom_components.localthings.ocf.registry.discovery import discover
from custom_components.localthings.ocf.registry.adapter import flatten
otn = resources.get('/otninformation/vs/0', {})
one_ui = otn.get('swVersionInfo', {}).get('oneUiVersion', '')
reg = for_device(one_ui) if one_ui else None
if reg is None:
from samsung_appliance.registry.registry import CAPABILITIES
from custom_components.localthings.ocf.registry.registry import CAPABILITIES
caps, pats = CAPABILITIES, []
else:
caps, pats = reg.capabilities, reg.pattern_capabilities