Add snapshot tests to Netatmo platforms (#107932)
* Add snapshot tests to Netatmo platforms * Add snapshot tests to Netatmo platforms
This commit is contained in:
parent
0458bd68d9
commit
902619a4db
15 changed files with 7211 additions and 10 deletions
|
@ -1,6 +1,8 @@
|
|||
"""The tests for Netatmo cover."""
|
||||
from unittest.mock import AsyncMock, patch
|
||||
|
||||
from syrupy import SnapshotAssertion
|
||||
|
||||
from homeassistant.components.cover import (
|
||||
ATTR_POSITION,
|
||||
DOMAIN as COVER_DOMAIN,
|
||||
|
@ -11,12 +13,30 @@ from homeassistant.components.cover import (
|
|||
)
|
||||
from homeassistant.const import ATTR_ENTITY_ID, Platform
|
||||
from homeassistant.core import HomeAssistant
|
||||
import homeassistant.helpers.entity_registry as er
|
||||
|
||||
from .common import selected_platforms
|
||||
from .common import selected_platforms, snapshot_platform_entities
|
||||
|
||||
from tests.common import MockConfigEntry
|
||||
|
||||
|
||||
async def test_entity(
|
||||
hass: HomeAssistant,
|
||||
config_entry: MockConfigEntry,
|
||||
netatmo_auth: AsyncMock,
|
||||
snapshot: SnapshotAssertion,
|
||||
entity_registry: er.EntityRegistry,
|
||||
) -> None:
|
||||
"""Test entities."""
|
||||
await snapshot_platform_entities(
|
||||
hass,
|
||||
config_entry,
|
||||
Platform.COVER,
|
||||
entity_registry,
|
||||
snapshot,
|
||||
)
|
||||
|
||||
|
||||
async def test_cover_setup_and_services(
|
||||
hass: HomeAssistant, config_entry: MockConfigEntry, netatmo_auth: AsyncMock
|
||||
) -> None:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue