1
0
mirror of https://github.com/home-assistant/core.git synced 2026-02-27 13:25:35 +00:00
Files
core/tests/components/tessie/test_sensor.py
Brett Adams 858fb1fa37 Add snapshot testing to Tessie (#108346)
* Redo Binary Sensors

* Redo Button

* Redo Climate

* Stage unfixed platforms

* Redo Cover

* Redo device tracker

* Redo lock

* Redo Media Player

* Redo Number

* Redo Select

* Redo Sensor

* Redo Switch

* Redo Update

* Fix setup_platform

* Add mixing snapshot

* Fix config flow

* Centralise entity testing

* Update snapshot

* Rename test_entities

* Fix assert_entities
2024-01-27 13:43:55 +01:00

19 lines
581 B
Python

"""Test the Tessie sensor platform."""
from syrupy import SnapshotAssertion
from homeassistant.const import Platform
from homeassistant.core import HomeAssistant
from homeassistant.helpers import entity_registry as er
from .common import assert_entities, setup_platform
async def test_sensors(
hass: HomeAssistant, snapshot: SnapshotAssertion, entity_registry: er.EntityRegistry
) -> None:
"""Tests that the sensor entities are correct."""
entry = await setup_platform(hass, [Platform.SENSOR])
assert_entities(hass, entry.entry_id, entity_registry, snapshot)