Change Snoo to use MQTT instead of PubNub (#150570)

This commit is contained in:
Luke Lashley
2025-08-13 18:11:52 -04:00
committed by GitHub
parent ed39b18d94
commit 12706178c2
2 changed files with 2 additions and 2 deletions

View File

@@ -40,7 +40,7 @@ class SnooCoordinator(DataUpdateCoordinator[SnooData]):
async def setup(self) -> None:
"""Perform setup needed on every coordintaor creation."""
await self.snoo.subscribe(self.device, self.async_set_updated_data)
self.snoo.start_subscribe(self.device, self.async_set_updated_data)
# After we subscribe - get the status so that we have something to start with.
# We only need to do this once. The device will auto update otherwise.
await self.snoo.get_status(self.device)

View File

@@ -48,7 +48,7 @@ def find_update_callback(
mock: AsyncMock, serial_number: str
) -> Callable[[SnooData], Awaitable[None]]:
"""Find the update callback for a specific identifier."""
for call in mock.subscribe.call_args_list:
for call in mock.start_subscribe.call_args_list:
if call[0][0].serialNumber == serial_number:
return call[0][1]
pytest.fail(f"Callback for identifier {serial_number} not found")