2022-07-06 05:14:56 +02:00
|
|
|
"""Test NextDNS diagnostics."""
|
2022-07-23 00:58:48 +02:00
|
|
|
|
2023-08-30 12:22:10 +02:00
|
|
|
from syrupy import SnapshotAssertion
|
|
|
|
|
2022-07-23 00:58:48 +02:00
|
|
|
from homeassistant.core import HomeAssistant
|
2022-07-06 05:14:56 +02:00
|
|
|
|
2022-09-19 09:46:59 +02:00
|
|
|
from . import init_integration
|
|
|
|
|
2022-07-06 05:14:56 +02:00
|
|
|
from tests.components.diagnostics import get_diagnostics_for_config_entry
|
2023-02-02 22:29:57 +01:00
|
|
|
from tests.typing import ClientSessionGenerator
|
2022-07-06 05:14:56 +02:00
|
|
|
|
|
|
|
|
2022-07-23 00:58:48 +02:00
|
|
|
async def test_entry_diagnostics(
|
2023-08-30 12:22:10 +02:00
|
|
|
hass: HomeAssistant,
|
|
|
|
hass_client: ClientSessionGenerator,
|
|
|
|
snapshot: SnapshotAssertion,
|
2022-07-23 00:58:48 +02:00
|
|
|
) -> None:
|
2022-07-06 05:14:56 +02:00
|
|
|
"""Test config entry diagnostics."""
|
|
|
|
entry = await init_integration(hass)
|
|
|
|
|
2023-08-30 12:22:10 +02:00
|
|
|
assert await get_diagnostics_for_config_entry(hass, hass_client, entry) == snapshot
|