1
0
mirror of https://github.com/home-assistant/core.git synced 2025-12-24 21:06:19 +00:00

Fix withings wrong sleep state entry (#29651)

* Fixing issue where wrong sleep state entry was being used. closes #28370,#29397

* Fixing formatting.

* Sorting imports to get black checks to pass.

* Using lambda for getting latest sleep serie.
This commit is contained in:
Robert Van Gorkom
2019-12-10 12:54:50 -08:00
committed by Pascal Vizeli
parent 899f6cf1a3
commit 66d2f5f61d
5 changed files with 43 additions and 23 deletions

View File

@@ -1,15 +1,14 @@
"""Tests for the Withings component."""
from asynctest import MagicMock
import pytest
from withings_api import WithingsApi
from withings_api.common import UnauthorizedException, TimeoutException
from withings_api.common import TimeoutException, UnauthorizedException
from homeassistant.exceptions import PlatformNotReady
from homeassistant.components.withings.common import (
NotAuthenticatedError,
WithingsDataManager,
)
from homeassistant.exceptions import PlatformNotReady
@pytest.fixture(name="withings_api")