Import Generator from collections.abc (4) (#120917)
This commit is contained in:
parent
ca55986057
commit
f11b316dac
116 changed files with 120 additions and 124 deletions
|
@ -1,10 +1,10 @@
|
||||||
"""Fixtures for testing qBittorrent component."""
|
"""Fixtures for testing qBittorrent component."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
import requests_mock
|
import requests_mock
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture
|
@pytest.fixture
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
"""Setup the QNAP tests."""
|
"""Setup the QNAP tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, MagicMock, patch
|
from unittest.mock import AsyncMock, MagicMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
TEST_HOST = "1.2.3.4"
|
TEST_HOST = "1.2.3.4"
|
||||||
TEST_USERNAME = "admin"
|
TEST_USERNAME = "admin"
|
||||||
|
|
|
@ -2,12 +2,12 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from ipaddress import ip_address
|
from ipaddress import ip_address
|
||||||
from unittest.mock import MagicMock, Mock, patch
|
from unittest.mock import MagicMock, Mock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from rabbitair import Mode, Model, Speed
|
from rabbitair import Mode, Model, Speed
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant import config_entries
|
from homeassistant import config_entries
|
||||||
from homeassistant.components import zeroconf
|
from homeassistant.components import zeroconf
|
||||||
|
|
|
@ -2,10 +2,10 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.radio_browser.const import DOMAIN
|
from homeassistant.components.radio_browser.const import DOMAIN
|
||||||
|
|
||||||
|
|
|
@ -2,6 +2,7 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from http import HTTPStatus
|
from http import HTTPStatus
|
||||||
import json
|
import json
|
||||||
from typing import Any
|
from typing import Any
|
||||||
|
@ -9,7 +10,6 @@ from unittest.mock import patch
|
||||||
|
|
||||||
from pyrainbird import encryption
|
from pyrainbird import encryption
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.rainbird import DOMAIN
|
from homeassistant.components.rainbird import DOMAIN
|
||||||
from homeassistant.components.rainbird.const import (
|
from homeassistant.components.rainbird.const import (
|
||||||
|
|
|
@ -1,11 +1,11 @@
|
||||||
"""Tests for the Rain Bird config flow."""
|
"""Tests for the Rain Bird config flow."""
|
||||||
|
|
||||||
|
from collections.abc import AsyncGenerator
|
||||||
from http import HTTPStatus
|
from http import HTTPStatus
|
||||||
from typing import Any
|
from typing import Any
|
||||||
from unittest.mock import AsyncMock, Mock, patch
|
from unittest.mock import AsyncMock, Mock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import AsyncGenerator
|
|
||||||
|
|
||||||
from homeassistant import config_entries
|
from homeassistant import config_entries
|
||||||
from homeassistant.components.rainbird import DOMAIN
|
from homeassistant.components.rainbird import DOMAIN
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
"""Fixtures for the Rainforest RAVEn tests."""
|
"""Fixtures for the Rainforest RAVEn tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.core import HomeAssistant
|
from homeassistant.core import HomeAssistant
|
||||||
|
|
||||||
|
|
|
@ -1,11 +1,11 @@
|
||||||
"""Test Rainforest RAVEn config flow."""
|
"""Test Rainforest RAVEn config flow."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
from aioraven.device import RAVEnConnectionError
|
from aioraven.device import RAVEnConnectionError
|
||||||
import pytest
|
import pytest
|
||||||
from serial.tools.list_ports_common import ListPortInfo
|
from serial.tools.list_ports_common import ListPortInfo
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.rainforest_raven.const import DOMAIN
|
from homeassistant.components.rainforest_raven.const import DOMAIN
|
||||||
from homeassistant.config_entries import SOURCE_USB, SOURCE_USER
|
from homeassistant.config_entries import SOURCE_USB, SOURCE_USER
|
||||||
|
|
|
@ -2,10 +2,10 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import MagicMock, patch
|
from unittest.mock import MagicMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
from vehicle import Vehicle
|
from vehicle import Vehicle
|
||||||
|
|
||||||
from homeassistant.components.rdw.const import CONF_LICENSE_PLATE, DOMAIN
|
from homeassistant.components.rdw.const import CONF_LICENSE_PLATE, DOMAIN
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
"""Fixtures for the recorder component tests."""
|
"""Fixtures for the recorder component tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import patch
|
from unittest.mock import patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components import recorder
|
from homeassistant.components import recorder
|
||||||
from homeassistant.core import HomeAssistant
|
from homeassistant.core import HomeAssistant
|
||||||
|
|
|
@ -1,12 +1,12 @@
|
||||||
"""The tests for the recorder filter matching the EntityFilter component."""
|
"""The tests for the recorder filter matching the EntityFilter component."""
|
||||||
|
|
||||||
|
from collections.abc import AsyncGenerator
|
||||||
import json
|
import json
|
||||||
from unittest.mock import patch
|
from unittest.mock import patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from sqlalchemy import select
|
from sqlalchemy import select
|
||||||
from sqlalchemy.engine.row import Row
|
from sqlalchemy.engine.row import Row
|
||||||
from typing_extensions import AsyncGenerator
|
|
||||||
|
|
||||||
from homeassistant.components.recorder import Recorder, get_instance
|
from homeassistant.components.recorder import Recorder, get_instance
|
||||||
from homeassistant.components.recorder.db_schema import EventData, Events, States
|
from homeassistant.components.recorder.db_schema import EventData, Events, States
|
||||||
|
|
|
@ -3,6 +3,7 @@
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
import asyncio
|
import asyncio
|
||||||
|
from collections.abc import Generator
|
||||||
from datetime import datetime, timedelta
|
from datetime import datetime, timedelta
|
||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
import sqlite3
|
import sqlite3
|
||||||
|
@ -14,7 +15,6 @@ from freezegun.api import FrozenDateTimeFactory
|
||||||
import pytest
|
import pytest
|
||||||
from sqlalchemy.exc import DatabaseError, OperationalError, SQLAlchemyError
|
from sqlalchemy.exc import DatabaseError, OperationalError, SQLAlchemyError
|
||||||
from sqlalchemy.pool import QueuePool
|
from sqlalchemy.pool import QueuePool
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components import recorder
|
from homeassistant.components import recorder
|
||||||
from homeassistant.components.recorder import (
|
from homeassistant.components.recorder import (
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
"""The tests for the recorder filter matching the EntityFilter component."""
|
"""The tests for the recorder filter matching the EntityFilter component."""
|
||||||
|
|
||||||
|
from collections.abc import AsyncGenerator
|
||||||
import datetime
|
import datetime
|
||||||
import importlib
|
import importlib
|
||||||
import sys
|
import sys
|
||||||
|
@ -12,7 +13,6 @@ import pytest
|
||||||
from sqlalchemy import create_engine, inspect
|
from sqlalchemy import create_engine, inspect
|
||||||
from sqlalchemy.exc import IntegrityError
|
from sqlalchemy.exc import IntegrityError
|
||||||
from sqlalchemy.orm import Session
|
from sqlalchemy.orm import Session
|
||||||
from typing_extensions import AsyncGenerator
|
|
||||||
|
|
||||||
from homeassistant.components import recorder
|
from homeassistant.components import recorder
|
||||||
from homeassistant.components.recorder import (
|
from homeassistant.components.recorder import (
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
"""Test data purging."""
|
"""Test data purging."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from datetime import datetime, timedelta
|
from datetime import datetime, timedelta
|
||||||
import json
|
import json
|
||||||
import sqlite3
|
import sqlite3
|
||||||
|
@ -9,7 +10,6 @@ from freezegun import freeze_time
|
||||||
import pytest
|
import pytest
|
||||||
from sqlalchemy.exc import DatabaseError, OperationalError
|
from sqlalchemy.exc import DatabaseError, OperationalError
|
||||||
from sqlalchemy.orm.session import Session
|
from sqlalchemy.orm.session import Session
|
||||||
from typing_extensions import Generator
|
|
||||||
from voluptuous.error import MultipleInvalid
|
from voluptuous.error import MultipleInvalid
|
||||||
|
|
||||||
from homeassistant.components import recorder
|
from homeassistant.components import recorder
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
"""Test data purging."""
|
"""Test data purging."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from datetime import datetime, timedelta
|
from datetime import datetime, timedelta
|
||||||
import json
|
import json
|
||||||
import sqlite3
|
import sqlite3
|
||||||
|
@ -10,7 +11,6 @@ import pytest
|
||||||
from sqlalchemy import text, update
|
from sqlalchemy import text, update
|
||||||
from sqlalchemy.exc import DatabaseError, OperationalError
|
from sqlalchemy.exc import DatabaseError, OperationalError
|
||||||
from sqlalchemy.orm.session import Session
|
from sqlalchemy.orm.session import Session
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components import recorder
|
from homeassistant.components import recorder
|
||||||
from homeassistant.components.recorder import migration
|
from homeassistant.components.recorder import migration
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
"""Pytest module configuration."""
|
"""Pytest module configuration."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture
|
@pytest.fixture
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
"""Provide common Renault fixtures."""
|
"""Provide common Renault fixtures."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
import contextlib
|
import contextlib
|
||||||
from types import MappingProxyType
|
from types import MappingProxyType
|
||||||
from typing import Any
|
from typing import Any
|
||||||
|
@ -8,7 +9,6 @@ from unittest.mock import AsyncMock, patch
|
||||||
import pytest
|
import pytest
|
||||||
from renault_api.kamereon import exceptions, schemas
|
from renault_api.kamereon import exceptions, schemas
|
||||||
from renault_api.renault_account import RenaultAccount
|
from renault_api.renault_account import RenaultAccount
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.renault.const import DOMAIN
|
from homeassistant.components.renault.const import DOMAIN
|
||||||
from homeassistant.config_entries import SOURCE_USER, ConfigEntry
|
from homeassistant.config_entries import SOURCE_USER, ConfigEntry
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
"""Tests for Renault binary sensors."""
|
"""Tests for Renault binary sensors."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import patch
|
from unittest.mock import patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from syrupy.assertion import SnapshotAssertion
|
from syrupy.assertion import SnapshotAssertion
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.config_entries import ConfigEntry
|
from homeassistant.config_entries import ConfigEntry
|
||||||
from homeassistant.const import Platform
|
from homeassistant.const import Platform
|
||||||
|
|
|
@ -1,11 +1,11 @@
|
||||||
"""Tests for Renault sensors."""
|
"""Tests for Renault sensors."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import patch
|
from unittest.mock import patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from renault_api.kamereon import schemas
|
from renault_api.kamereon import schemas
|
||||||
from syrupy.assertion import SnapshotAssertion
|
from syrupy.assertion import SnapshotAssertion
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.button import DOMAIN as BUTTON_DOMAIN, SERVICE_PRESS
|
from homeassistant.components.button import DOMAIN as BUTTON_DOMAIN, SERVICE_PRESS
|
||||||
from homeassistant.config_entries import ConfigEntry
|
from homeassistant.config_entries import ConfigEntry
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
"""Tests for Renault sensors."""
|
"""Tests for Renault sensors."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import patch
|
from unittest.mock import patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from syrupy.assertion import SnapshotAssertion
|
from syrupy.assertion import SnapshotAssertion
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.config_entries import ConfigEntry
|
from homeassistant.config_entries import ConfigEntry
|
||||||
from homeassistant.const import Platform
|
from homeassistant.const import Platform
|
||||||
|
|
|
@ -1,12 +1,12 @@
|
||||||
"""Tests for Renault setup process."""
|
"""Tests for Renault setup process."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from typing import Any
|
from typing import Any
|
||||||
from unittest.mock import Mock, patch
|
from unittest.mock import Mock, patch
|
||||||
|
|
||||||
import aiohttp
|
import aiohttp
|
||||||
import pytest
|
import pytest
|
||||||
from renault_api.gigya.exceptions import GigyaException, InvalidCredentialsException
|
from renault_api.gigya.exceptions import GigyaException, InvalidCredentialsException
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.renault.const import DOMAIN
|
from homeassistant.components.renault.const import DOMAIN
|
||||||
from homeassistant.config_entries import ConfigEntry, ConfigEntryState
|
from homeassistant.config_entries import ConfigEntry, ConfigEntryState
|
||||||
|
|
|
@ -1,11 +1,11 @@
|
||||||
"""Tests for Renault selects."""
|
"""Tests for Renault selects."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import patch
|
from unittest.mock import patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from renault_api.kamereon import schemas
|
from renault_api.kamereon import schemas
|
||||||
from syrupy.assertion import SnapshotAssertion
|
from syrupy.assertion import SnapshotAssertion
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.select import (
|
from homeassistant.components.select import (
|
||||||
ATTR_OPTION,
|
ATTR_OPTION,
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
"""Tests for Renault sensors."""
|
"""Tests for Renault sensors."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import patch
|
from unittest.mock import patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from syrupy.assertion import SnapshotAssertion
|
from syrupy.assertion import SnapshotAssertion
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.config_entries import ConfigEntry
|
from homeassistant.config_entries import ConfigEntry
|
||||||
from homeassistant.const import Platform
|
from homeassistant.const import Platform
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
"""Tests for Renault sensors."""
|
"""Tests for Renault sensors."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from datetime import datetime
|
from datetime import datetime
|
||||||
from unittest.mock import patch
|
from unittest.mock import patch
|
||||||
|
|
||||||
|
@ -7,7 +8,6 @@ import pytest
|
||||||
from renault_api.exceptions import RenaultException
|
from renault_api.exceptions import RenaultException
|
||||||
from renault_api.kamereon import schemas
|
from renault_api.kamereon import schemas
|
||||||
from renault_api.kamereon.models import ChargeSchedule
|
from renault_api.kamereon.models import ChargeSchedule
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.renault.const import DOMAIN
|
from homeassistant.components.renault.const import DOMAIN
|
||||||
from homeassistant.components.renault.services import (
|
from homeassistant.components.renault.services import (
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
"""Setup the Reolink tests."""
|
"""Setup the Reolink tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, MagicMock, patch
|
from unittest.mock import AsyncMock, MagicMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.reolink import const
|
from homeassistant.components.reolink import const
|
||||||
from homeassistant.components.reolink.config_flow import DEFAULT_PROTOCOL
|
from homeassistant.components.reolink.config_flow import DEFAULT_PROTOCOL
|
||||||
|
|
|
@ -1,11 +1,11 @@
|
||||||
"""Configuration for Ring tests."""
|
"""Configuration for Ring tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from itertools import chain
|
from itertools import chain
|
||||||
from unittest.mock import AsyncMock, Mock, create_autospec, patch
|
from unittest.mock import AsyncMock, Mock, create_autospec, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
import ring_doorbell
|
import ring_doorbell
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.ring import DOMAIN
|
from homeassistant.components.ring import DOMAIN
|
||||||
from homeassistant.const import CONF_USERNAME
|
from homeassistant.const import CONF_USERNAME
|
||||||
|
|
|
@ -1,11 +1,11 @@
|
||||||
"""Fixtures for Roku integration tests."""
|
"""Fixtures for Roku integration tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
import json
|
import json
|
||||||
from unittest.mock import MagicMock, patch
|
from unittest.mock import MagicMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from rokuecp import Device as RokuDevice
|
from rokuecp import Device as RokuDevice
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.roku.const import DOMAIN
|
from homeassistant.components.roku.const import DOMAIN
|
||||||
from homeassistant.const import CONF_HOST
|
from homeassistant.const import CONF_HOST
|
||||||
|
|
|
@ -2,13 +2,12 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
from collections.abc import Awaitable, Callable
|
from collections.abc import AsyncGenerator, Awaitable, Callable
|
||||||
from typing import Any
|
from typing import Any
|
||||||
from unittest.mock import patch
|
from unittest.mock import patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
import rtsp_to_webrtc
|
import rtsp_to_webrtc
|
||||||
from typing_extensions import AsyncGenerator
|
|
||||||
|
|
||||||
from homeassistant.components import camera
|
from homeassistant.components import camera
|
||||||
from homeassistant.components.rtsp_to_webrtc import DOMAIN
|
from homeassistant.components.rtsp_to_webrtc import DOMAIN
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
"""Configuration for Sabnzbd tests."""
|
"""Configuration for Sabnzbd tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture
|
@pytest.fixture
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
from collections.abc import Awaitable, Callable
|
from collections.abc import Awaitable, Callable, Generator
|
||||||
from datetime import datetime
|
from datetime import datetime
|
||||||
from socket import AddressFamily # pylint: disable=no-name-in-module
|
from socket import AddressFamily # pylint: disable=no-name-in-module
|
||||||
from typing import Any
|
from typing import Any
|
||||||
|
@ -19,7 +19,6 @@ from samsungtvws.encrypted.remote import SamsungTVEncryptedWSAsyncRemote
|
||||||
from samsungtvws.event import ED_INSTALLED_APP_EVENT
|
from samsungtvws.event import ED_INSTALLED_APP_EVENT
|
||||||
from samsungtvws.exceptions import ResponseError
|
from samsungtvws.exceptions import ResponseError
|
||||||
from samsungtvws.remote import ChannelEmitCommand
|
from samsungtvws.remote import ChannelEmitCommand
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.samsungtv.const import WEBSOCKET_SSL_PORT
|
from homeassistant.components.samsungtv.const import WEBSOCKET_SSL_PORT
|
||||||
from homeassistant.core import HomeAssistant, ServiceCall
|
from homeassistant.core import HomeAssistant, ServiceCall
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
"""Sanix tests configuration."""
|
"""Sanix tests configuration."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from datetime import datetime
|
from datetime import datetime
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
from zoneinfo import ZoneInfo
|
from zoneinfo import ZoneInfo
|
||||||
|
@ -16,7 +17,6 @@ from sanix import (
|
||||||
ATTR_API_TIME,
|
ATTR_API_TIME,
|
||||||
)
|
)
|
||||||
from sanix.models import Measurement
|
from sanix.models import Measurement
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.sanix.const import CONF_SERIAL_NUMBER, DOMAIN
|
from homeassistant.components.sanix.const import CONF_SERIAL_NUMBER, DOMAIN
|
||||||
from homeassistant.const import CONF_TOKEN
|
from homeassistant.const import CONF_TOKEN
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
"""Common fixtures for the Schlage tests."""
|
"""Common fixtures for the Schlage tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, Mock, create_autospec, patch
|
from unittest.mock import AsyncMock, Mock, create_autospec, patch
|
||||||
|
|
||||||
from pyschlage.lock import Lock
|
from pyschlage.lock import Lock
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.schlage.const import DOMAIN
|
from homeassistant.components.schlage.const import DOMAIN
|
||||||
from homeassistant.const import CONF_PASSWORD, CONF_USERNAME
|
from homeassistant.const import CONF_PASSWORD, CONF_USERNAME
|
||||||
|
|
|
@ -2,12 +2,12 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from typing import Any
|
from typing import Any
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
import uuid
|
import uuid
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.rest.data import DEFAULT_TIMEOUT
|
from homeassistant.components.rest.data import DEFAULT_TIMEOUT
|
||||||
from homeassistant.components.rest.schema import DEFAULT_METHOD, DEFAULT_VERIFY_SSL
|
from homeassistant.components.rest.schema import DEFAULT_METHOD, DEFAULT_VERIFY_SSL
|
||||||
|
|
|
@ -1,12 +1,12 @@
|
||||||
"""Tests for ScreenLogic integration service calls."""
|
"""Tests for ScreenLogic integration service calls."""
|
||||||
|
|
||||||
|
from collections.abc import AsyncGenerator
|
||||||
from typing import Any
|
from typing import Any
|
||||||
from unittest.mock import DEFAULT, AsyncMock, patch
|
from unittest.mock import DEFAULT, AsyncMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from screenlogicpy import ScreenLogicGateway
|
from screenlogicpy import ScreenLogicGateway
|
||||||
from screenlogicpy.device_const.system import COLOR_MODE
|
from screenlogicpy.device_const.system import COLOR_MODE
|
||||||
from typing_extensions import AsyncGenerator
|
|
||||||
|
|
||||||
from homeassistant.components.screenlogic import DOMAIN
|
from homeassistant.components.screenlogic import DOMAIN
|
||||||
from homeassistant.components.screenlogic.const import (
|
from homeassistant.components.screenlogic.const import (
|
||||||
|
|
|
@ -2,10 +2,10 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import patch
|
from unittest.mock import patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.season.const import DOMAIN, TYPE_ASTRONOMICAL
|
from homeassistant.components.season.const import DOMAIN, TYPE_ASTRONOMICAL
|
||||||
from homeassistant.const import CONF_TYPE
|
from homeassistant.const import CONF_TYPE
|
||||||
|
|
|
@ -2,13 +2,13 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from datetime import UTC, date, datetime
|
from datetime import UTC, date, datetime
|
||||||
from decimal import Decimal
|
from decimal import Decimal
|
||||||
from types import ModuleType
|
from types import ModuleType
|
||||||
from typing import Any
|
from typing import Any
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components import sensor
|
from homeassistant.components import sensor
|
||||||
from homeassistant.components.number import NumberDeviceClass
|
from homeassistant.components.number import NumberDeviceClass
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
"""Configuration for 17Track tests."""
|
"""Configuration for 17Track tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
from py17track.package import Package
|
from py17track.package import Package
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.seventeentrack.const import (
|
from homeassistant.components.seventeentrack.const import (
|
||||||
CONF_SHOW_ARCHIVED,
|
CONF_SHOW_ARCHIVED,
|
||||||
|
|
|
@ -1,11 +1,11 @@
|
||||||
"""Provide common SFR Box fixtures."""
|
"""Provide common SFR Box fixtures."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
import json
|
import json
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from sfrbox_api.models import DslInfo, FtthInfo, SystemInfo, WanInfo
|
from sfrbox_api.models import DslInfo, FtthInfo, SystemInfo, WanInfo
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.sfr_box.const import DOMAIN
|
from homeassistant.components.sfr_box.const import DOMAIN
|
||||||
from homeassistant.config_entries import SOURCE_USER, ConfigEntry
|
from homeassistant.config_entries import SOURCE_USER, ConfigEntry
|
||||||
|
|
|
@ -1,11 +1,11 @@
|
||||||
"""Test the SFR Box binary sensors."""
|
"""Test the SFR Box binary sensors."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import patch
|
from unittest.mock import patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from sfrbox_api.models import SystemInfo
|
from sfrbox_api.models import SystemInfo
|
||||||
from syrupy.assertion import SnapshotAssertion
|
from syrupy.assertion import SnapshotAssertion
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.config_entries import ConfigEntry
|
from homeassistant.config_entries import ConfigEntry
|
||||||
from homeassistant.const import Platform
|
from homeassistant.const import Platform
|
||||||
|
|
|
@ -1,11 +1,11 @@
|
||||||
"""Test the SFR Box buttons."""
|
"""Test the SFR Box buttons."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import patch
|
from unittest.mock import patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from sfrbox_api.exceptions import SFRBoxError
|
from sfrbox_api.exceptions import SFRBoxError
|
||||||
from syrupy.assertion import SnapshotAssertion
|
from syrupy.assertion import SnapshotAssertion
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.button import DOMAIN as BUTTON_DOMAIN, SERVICE_PRESS
|
from homeassistant.components.button import DOMAIN as BUTTON_DOMAIN, SERVICE_PRESS
|
||||||
from homeassistant.config_entries import ConfigEntry
|
from homeassistant.config_entries import ConfigEntry
|
||||||
|
|
|
@ -1,11 +1,11 @@
|
||||||
"""Test the SFR Box diagnostics."""
|
"""Test the SFR Box diagnostics."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import patch
|
from unittest.mock import patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from sfrbox_api.models import SystemInfo
|
from sfrbox_api.models import SystemInfo
|
||||||
from syrupy.assertion import SnapshotAssertion
|
from syrupy.assertion import SnapshotAssertion
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.config_entries import ConfigEntry
|
from homeassistant.config_entries import ConfigEntry
|
||||||
from homeassistant.core import HomeAssistant
|
from homeassistant.core import HomeAssistant
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
"""Test the SFR Box setup process."""
|
"""Test the SFR Box setup process."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import patch
|
from unittest.mock import patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from sfrbox_api.exceptions import SFRBoxAuthenticationError, SFRBoxError
|
from sfrbox_api.exceptions import SFRBoxAuthenticationError, SFRBoxError
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.sfr_box.const import DOMAIN
|
from homeassistant.components.sfr_box.const import DOMAIN
|
||||||
from homeassistant.config_entries import ConfigEntry, ConfigEntryState
|
from homeassistant.config_entries import ConfigEntry, ConfigEntryState
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
"""Test the SFR Box sensors."""
|
"""Test the SFR Box sensors."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import patch
|
from unittest.mock import patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from syrupy.assertion import SnapshotAssertion
|
from syrupy.assertion import SnapshotAssertion
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.config_entries import ConfigEntry
|
from homeassistant.config_entries import ConfigEntry
|
||||||
from homeassistant.const import Platform
|
from homeassistant.const import Platform
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
"""Define test fixtures for SimpliSafe."""
|
"""Define test fixtures for SimpliSafe."""
|
||||||
|
|
||||||
|
from collections.abc import AsyncGenerator
|
||||||
from unittest.mock import AsyncMock, Mock, patch
|
from unittest.mock import AsyncMock, Mock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from simplipy.system.v3 import SystemV3
|
from simplipy.system.v3 import SystemV3
|
||||||
from typing_extensions import AsyncGenerator
|
|
||||||
|
|
||||||
from homeassistant.components.simplisafe.const import DOMAIN
|
from homeassistant.components.simplisafe.const import DOMAIN
|
||||||
from homeassistant.const import CONF_CODE, CONF_PASSWORD, CONF_TOKEN, CONF_USERNAME
|
from homeassistant.const import CONF_CODE, CONF_PASSWORD, CONF_TOKEN, CONF_USERNAME
|
||||||
|
|
|
@ -2,6 +2,7 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, MagicMock, create_autospec, patch
|
from unittest.mock import AsyncMock, MagicMock, create_autospec, patch
|
||||||
|
|
||||||
from asyncsleepiq import (
|
from asyncsleepiq import (
|
||||||
|
@ -17,7 +18,6 @@ from asyncsleepiq import (
|
||||||
SleepIQSleeper,
|
SleepIQSleeper,
|
||||||
)
|
)
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.sleepiq import DOMAIN
|
from homeassistant.components.sleepiq import DOMAIN
|
||||||
from homeassistant.const import CONF_PASSWORD, CONF_USERNAME
|
from homeassistant.const import CONF_PASSWORD, CONF_USERNAME
|
||||||
|
|
|
@ -2,10 +2,10 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.slimproto.const import DOMAIN
|
from homeassistant.components.slimproto.const import DOMAIN
|
||||||
|
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
"""Test the snapcast config flow."""
|
"""Test the snapcast config flow."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, MagicMock, patch
|
from unittest.mock import AsyncMock, MagicMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture
|
@pytest.fixture
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
"""Fixtures for Sonarr integration tests."""
|
"""Fixtures for Sonarr integration tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
import json
|
import json
|
||||||
from unittest.mock import MagicMock, patch
|
from unittest.mock import MagicMock, patch
|
||||||
|
|
||||||
|
@ -13,7 +14,6 @@ from aiopyarr import (
|
||||||
SystemStatus,
|
SystemStatus,
|
||||||
)
|
)
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.sonarr.const import (
|
from homeassistant.components.sonarr.const import (
|
||||||
CONF_BASE_PATH,
|
CONF_BASE_PATH,
|
||||||
|
|
|
@ -2,12 +2,12 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
import datetime as dt
|
import datetime as dt
|
||||||
from unittest.mock import MagicMock, patch
|
from unittest.mock import MagicMock, patch
|
||||||
|
|
||||||
from freezegun.api import FrozenDateTimeFactory
|
from freezegun.api import FrozenDateTimeFactory
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.srp_energy.const import DOMAIN, PHOENIX_TIME_ZONE
|
from homeassistant.components.srp_energy.const import DOMAIN, PHOENIX_TIME_ZONE
|
||||||
from homeassistant.const import CONF_ID
|
from homeassistant.const import CONF_ID
|
||||||
|
|
|
@ -13,13 +13,13 @@ so that it can inspect the output.
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
import asyncio
|
import asyncio
|
||||||
|
from collections.abc import Generator
|
||||||
import logging
|
import logging
|
||||||
import threading
|
import threading
|
||||||
from unittest.mock import Mock, patch
|
from unittest.mock import Mock, patch
|
||||||
|
|
||||||
from aiohttp import web
|
from aiohttp import web
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.stream.core import StreamOutput
|
from homeassistant.components.stream.core import StreamOutput
|
||||||
from homeassistant.components.stream.worker import StreamState
|
from homeassistant.components.stream.worker import StreamState
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
"""Common fixtures for the StreamLabs tests."""
|
"""Common fixtures for the StreamLabs tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from streamlabswater.streamlabswater import StreamlabsClient
|
from streamlabswater.streamlabswater import StreamlabsClient
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.streamlabswater import DOMAIN
|
from homeassistant.components.streamlabswater import DOMAIN
|
||||||
from homeassistant.const import CONF_API_KEY
|
from homeassistant.const import CONF_API_KEY
|
||||||
|
|
|
@ -1,12 +1,11 @@
|
||||||
"""Test STT component setup."""
|
"""Test STT component setup."""
|
||||||
|
|
||||||
from collections.abc import AsyncIterable
|
from collections.abc import AsyncIterable, Generator
|
||||||
from http import HTTPStatus
|
from http import HTTPStatus
|
||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
from unittest.mock import AsyncMock
|
from unittest.mock import AsyncMock
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.stt import (
|
from homeassistant.components.stt import (
|
||||||
DOMAIN,
|
DOMAIN,
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
"""Common fixtures for the Suez Water tests."""
|
"""Common fixtures for the Suez Water tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture
|
@pytest.fixture
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
"""Common fixtures for the swiss_public_transport tests."""
|
"""Common fixtures for the swiss_public_transport tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture
|
@pytest.fixture
|
||||||
|
|
|
@ -2,10 +2,10 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.core import HomeAssistant
|
from homeassistant.core import HomeAssistant
|
||||||
from homeassistant.setup import async_setup_component
|
from homeassistant.setup import async_setup_component
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
"""Common fixtures for the SwitchBot via API tests."""
|
"""Common fixtures for the SwitchBot via API tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture
|
@pytest.fixture
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
"""Common fixtures and objects for the Switcher integration tests."""
|
"""Common fixtures and objects for the Switcher integration tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, MagicMock, Mock, patch
|
from unittest.mock import AsyncMock, MagicMock, Mock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture
|
@pytest.fixture
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
"""Configure Synology DSM tests."""
|
"""Configure Synology DSM tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.core import HomeAssistant
|
from homeassistant.core import HomeAssistant
|
||||||
from homeassistant.setup import async_setup_component
|
from homeassistant.setup import async_setup_component
|
||||||
|
|
|
@ -2,13 +2,13 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
import socket
|
import socket
|
||||||
from unittest.mock import AsyncMock, Mock, NonCallableMock, patch
|
from unittest.mock import AsyncMock, Mock, NonCallableMock, patch
|
||||||
|
|
||||||
from psutil import NoSuchProcess, Process
|
from psutil import NoSuchProcess, Process
|
||||||
from psutil._common import sdiskpart, sdiskusage, shwtemp, snetio, snicaddr, sswap
|
from psutil._common import sdiskpart, sdiskusage, shwtemp, snetio, snicaddr, sswap
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.systemmonitor.const import DOMAIN
|
from homeassistant.components.systemmonitor.const import DOMAIN
|
||||||
from homeassistant.components.systemmonitor.coordinator import VirtualMemory
|
from homeassistant.components.systemmonitor.coordinator import VirtualMemory
|
||||||
|
|
|
@ -2,11 +2,11 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, MagicMock, patch
|
from unittest.mock import AsyncMock, MagicMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from tailscale.models import Devices
|
from tailscale.models import Devices
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.tailscale.const import CONF_TAILNET, DOMAIN
|
from homeassistant.components.tailscale.const import CONF_TAILNET, DOMAIN
|
||||||
from homeassistant.const import CONF_API_KEY
|
from homeassistant.const import CONF_API_KEY
|
||||||
|
|
|
@ -2,11 +2,11 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, MagicMock, patch
|
from unittest.mock import AsyncMock, MagicMock, patch
|
||||||
|
|
||||||
from gotailwind import TailwindDeviceStatus
|
from gotailwind import TailwindDeviceStatus
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.tailwind.const import DOMAIN
|
from homeassistant.components.tailwind.const import DOMAIN
|
||||||
from homeassistant.const import CONF_HOST, CONF_TOKEN
|
from homeassistant.const import CONF_HOST, CONF_TOKEN
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
"""Common fixutres with default mocks as well as common test helper methods."""
|
"""Common fixutres with default mocks as well as common test helper methods."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from datetime import datetime
|
from datetime import datetime
|
||||||
from unittest.mock import AsyncMock, MagicMock, patch
|
from unittest.mock import AsyncMock, MagicMock, patch
|
||||||
|
|
||||||
|
@ -7,7 +8,6 @@ import pytest
|
||||||
from Tami4EdgeAPI.device import Device
|
from Tami4EdgeAPI.device import Device
|
||||||
from Tami4EdgeAPI.device_metadata import DeviceMetadata
|
from Tami4EdgeAPI.device_metadata import DeviceMetadata
|
||||||
from Tami4EdgeAPI.water_quality import UV, Filter, WaterQuality
|
from Tami4EdgeAPI.water_quality import UV, Filter, WaterQuality
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.tami4.const import CONF_REFRESH_TOKEN, DOMAIN
|
from homeassistant.components.tami4.const import CONF_REFRESH_TOKEN, DOMAIN
|
||||||
from homeassistant.core import HomeAssistant
|
from homeassistant.core import HomeAssistant
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
"""Fixtures for Tankerkoenig integration tests."""
|
"""Fixtures for Tankerkoenig integration tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.tankerkoenig import DOMAIN
|
from homeassistant.components.tankerkoenig import DOMAIN
|
||||||
from homeassistant.const import CONF_SHOW_ON_MAP
|
from homeassistant.const import CONF_SHOW_ON_MAP
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
"""Fixtures for TechnoVE integration tests."""
|
"""Fixtures for TechnoVE integration tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, MagicMock, patch
|
from unittest.mock import AsyncMock, MagicMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from technove import Station as TechnoVEStation
|
from technove import Station as TechnoVEStation
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.technove.const import DOMAIN
|
from homeassistant.components.technove.const import DOMAIN
|
||||||
from homeassistant.const import CONF_HOST
|
from homeassistant.const import CONF_HOST
|
||||||
|
|
|
@ -2,13 +2,13 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
import json
|
import json
|
||||||
from unittest.mock import AsyncMock, MagicMock, patch
|
from unittest.mock import AsyncMock, MagicMock, patch
|
||||||
|
|
||||||
from pytedee_async.bridge import TedeeBridge
|
from pytedee_async.bridge import TedeeBridge
|
||||||
from pytedee_async.lock import TedeeLock
|
from pytedee_async.lock import TedeeLock
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.tedee.const import CONF_LOCAL_ACCESS_TOKEN, DOMAIN
|
from homeassistant.components.tedee.const import CONF_LOCAL_ACCESS_TOKEN, DOMAIN
|
||||||
from homeassistant.const import CONF_HOST, CONF_WEBHOOK_ID
|
from homeassistant.const import CONF_HOST, CONF_WEBHOOK_ID
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
"""Fixtures for Time & Date integration tests."""
|
"""Fixtures for Time & Date integration tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture
|
@pytest.fixture
|
||||||
|
|
|
@ -1,12 +1,12 @@
|
||||||
"""Tests for the todo integration."""
|
"""Tests for the todo integration."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
import datetime
|
import datetime
|
||||||
from typing import Any
|
from typing import Any
|
||||||
from unittest.mock import AsyncMock
|
from unittest.mock import AsyncMock
|
||||||
import zoneinfo
|
import zoneinfo
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
import voluptuous as vol
|
import voluptuous as vol
|
||||||
|
|
||||||
from homeassistant.components import conversation
|
from homeassistant.components import conversation
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
"""Common fixtures for the todoist tests."""
|
"""Common fixtures for the todoist tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from http import HTTPStatus
|
from http import HTTPStatus
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
|
@ -7,7 +8,6 @@ import pytest
|
||||||
from requests.exceptions import HTTPError
|
from requests.exceptions import HTTPError
|
||||||
from requests.models import Response
|
from requests.models import Response
|
||||||
from todoist_api_python.models import Collaborator, Due, Label, Project, Task
|
from todoist_api_python.models import Collaborator, Due, Label, Project, Task
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.todoist import DOMAIN
|
from homeassistant.components.todoist import DOMAIN
|
||||||
from homeassistant.const import CONF_TOKEN, Platform
|
from homeassistant.const import CONF_TOKEN, Platform
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
"""tplink conftest."""
|
"""tplink conftest."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
import copy
|
import copy
|
||||||
from unittest.mock import DEFAULT, AsyncMock, patch
|
from unittest.mock import DEFAULT, AsyncMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.tplink import DOMAIN
|
from homeassistant.components.tplink import DOMAIN
|
||||||
from homeassistant.core import HomeAssistant
|
from homeassistant.core import HomeAssistant
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
"""Test fixtures for TP-Link Omada integration."""
|
"""Test fixtures for TP-Link Omada integration."""
|
||||||
|
|
||||||
from collections.abc import AsyncIterable
|
from collections.abc import AsyncIterable, Generator
|
||||||
import json
|
import json
|
||||||
from unittest.mock import AsyncMock, MagicMock, patch
|
from unittest.mock import AsyncMock, MagicMock, patch
|
||||||
|
|
||||||
|
@ -17,7 +17,6 @@ from tplink_omada_client.devices import (
|
||||||
OmadaSwitch,
|
OmadaSwitch,
|
||||||
OmadaSwitchPortDetails,
|
OmadaSwitchPortDetails,
|
||||||
)
|
)
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.tplink_omada.config_flow import CONF_SITE
|
from homeassistant.components.tplink_omada.config_flow import CONF_SITE
|
||||||
from homeassistant.components.tplink_omada.const import DOMAIN
|
from homeassistant.components.tplink_omada.const import DOMAIN
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
"""Common fixtures for the Traccar Server tests."""
|
"""Common fixtures for the Traccar Server tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from pytraccar import ApiClient, SubscriptionStatus
|
from pytraccar import ApiClient, SubscriptionStatus
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.traccar_server.const import (
|
from homeassistant.components.traccar_server.const import (
|
||||||
CONF_CUSTOM_ATTRIBUTES,
|
CONF_CUSTOM_ATTRIBUTES,
|
||||||
|
|
|
@ -1,11 +1,11 @@
|
||||||
"""Test the Traccar Server config flow."""
|
"""Test the Traccar Server config flow."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from typing import Any
|
from typing import Any
|
||||||
from unittest.mock import AsyncMock
|
from unittest.mock import AsyncMock
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from pytraccar import TraccarException
|
from pytraccar import TraccarException
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant import config_entries
|
from homeassistant import config_entries
|
||||||
from homeassistant.components.traccar.device_tracker import PLATFORM_SCHEMA
|
from homeassistant.components.traccar.device_tracker import PLATFORM_SCHEMA
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
"""Test Traccar Server diagnostics."""
|
"""Test Traccar Server diagnostics."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock
|
from unittest.mock import AsyncMock
|
||||||
|
|
||||||
from syrupy import SnapshotAssertion
|
from syrupy import SnapshotAssertion
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.core import HomeAssistant
|
from homeassistant.core import HomeAssistant
|
||||||
from homeassistant.helpers import device_registry as dr, entity_registry as er
|
from homeassistant.helpers import device_registry as dr, entity_registry as er
|
||||||
|
|
|
@ -1,12 +1,12 @@
|
||||||
"""Common fixtures for the Tractive tests."""
|
"""Common fixtures for the Tractive tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from typing import Any
|
from typing import Any
|
||||||
from unittest.mock import AsyncMock, Mock, patch
|
from unittest.mock import AsyncMock, Mock, patch
|
||||||
|
|
||||||
from aiotractive.trackable_object import TrackableObject
|
from aiotractive.trackable_object import TrackableObject
|
||||||
from aiotractive.tracker import Tracker
|
from aiotractive.tracker import Tracker
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.tractive.const import DOMAIN, SERVER_UNAVAILABLE
|
from homeassistant.components.tractive.const import DOMAIN, SERVER_UNAVAILABLE
|
||||||
from homeassistant.const import CONF_EMAIL, CONF_PASSWORD
|
from homeassistant.const import CONF_EMAIL, CONF_PASSWORD
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
from collections.abc import Callable
|
from collections.abc import Callable, Generator
|
||||||
import json
|
import json
|
||||||
from typing import Any
|
from typing import Any
|
||||||
from unittest.mock import AsyncMock, MagicMock, patch
|
from unittest.mock import AsyncMock, MagicMock, patch
|
||||||
|
@ -12,7 +12,6 @@ from pytradfri.command import Command
|
||||||
from pytradfri.const import ATTR_FIRMWARE_VERSION, ATTR_GATEWAY_ID
|
from pytradfri.const import ATTR_FIRMWARE_VERSION, ATTR_GATEWAY_ID
|
||||||
from pytradfri.device import Device
|
from pytradfri.device import Device
|
||||||
from pytradfri.gateway import Gateway
|
from pytradfri.gateway import Gateway
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.tradfri.const import DOMAIN
|
from homeassistant.components.tradfri.const import DOMAIN
|
||||||
|
|
||||||
|
|
|
@ -2,13 +2,13 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from http import HTTPStatus
|
from http import HTTPStatus
|
||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
from typing import Any
|
from typing import Any
|
||||||
from unittest.mock import MagicMock, patch
|
from unittest.mock import MagicMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
import voluptuous as vol
|
import voluptuous as vol
|
||||||
|
|
||||||
from homeassistant.components import media_source
|
from homeassistant.components import media_source
|
||||||
|
|
|
@ -3,11 +3,11 @@
|
||||||
From http://doc.pytest.org/en/latest/example/simple.html#making-test-result-information-available-in-fixtures
|
From http://doc.pytest.org/en/latest/example/simple.html#making-test-result-information-available-in-fixtures
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
from unittest.mock import MagicMock
|
from unittest.mock import MagicMock
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.config import async_process_ha_core_config
|
from homeassistant.config import async_process_ha_core_config
|
||||||
from homeassistant.config_entries import ConfigFlow
|
from homeassistant.config_entries import ConfigFlow
|
||||||
|
|
|
@ -2,10 +2,10 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, MagicMock, patch
|
from unittest.mock import AsyncMock, MagicMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.tuya.const import CONF_APP_TYPE, CONF_USER_CODE, DOMAIN
|
from homeassistant.components.tuya.const import CONF_APP_TYPE, CONF_USER_CODE, DOMAIN
|
||||||
|
|
||||||
|
|
|
@ -2,12 +2,12 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from datetime import date
|
from datetime import date
|
||||||
from unittest.mock import MagicMock, patch
|
from unittest.mock import MagicMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from twentemilieu import WasteType
|
from twentemilieu import WasteType
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.twentemilieu.const import (
|
from homeassistant.components.twentemilieu.const import (
|
||||||
CONF_HOUSE_LETTER,
|
CONF_HOUSE_LETTER,
|
||||||
|
|
|
@ -1,11 +1,11 @@
|
||||||
"""Configure tests for the Twitch integration."""
|
"""Configure tests for the Twitch integration."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
import time
|
import time
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from twitchAPI.object.api import FollowedChannel, Stream, TwitchUser, UserSubscription
|
from twitchAPI.object.api import FollowedChannel, Stream, TwitchUser, UserSubscription
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.application_credentials import (
|
from homeassistant.components.application_credentials import (
|
||||||
ClientCredential,
|
ClientCredential,
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
"""Test the Ukraine Alarm config flow."""
|
"""Test the Ukraine Alarm config flow."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
from aiohttp import ClientConnectionError, ClientError, ClientResponseError, RequestInfo
|
from aiohttp import ClientConnectionError, ClientError, ClientResponseError, RequestInfo
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
from yarl import URL
|
from yarl import URL
|
||||||
|
|
||||||
from homeassistant import config_entries
|
from homeassistant import config_entries
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
import asyncio
|
import asyncio
|
||||||
from collections.abc import Callable
|
from collections.abc import Callable, Generator
|
||||||
from datetime import timedelta
|
from datetime import timedelta
|
||||||
from types import MappingProxyType
|
from types import MappingProxyType
|
||||||
from typing import Any
|
from typing import Any
|
||||||
|
@ -12,7 +12,6 @@ from unittest.mock import AsyncMock, patch
|
||||||
from aiounifi.models.message import MessageKey
|
from aiounifi.models.message import MessageKey
|
||||||
import orjson
|
import orjson
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.unifi import STORAGE_KEY, STORAGE_VERSION
|
from homeassistant.components.unifi import STORAGE_KEY, STORAGE_VERSION
|
||||||
from homeassistant.components.unifi.const import CONF_SITE_ID, DOMAIN as UNIFI_DOMAIN
|
from homeassistant.components.unifi.const import CONF_SITE_ID, DOMAIN as UNIFI_DOMAIN
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
"""The tests for the Update component."""
|
"""The tests for the Update component."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import MagicMock, patch
|
from unittest.mock import MagicMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.update import (
|
from homeassistant.components.update import (
|
||||||
ATTR_BACKUP,
|
ATTR_BACKUP,
|
||||||
|
|
|
@ -2,10 +2,10 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import patch
|
from unittest.mock import patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.uptime.const import DOMAIN
|
from homeassistant.components.uptime.const import DOMAIN
|
||||||
from homeassistant.core import HomeAssistant
|
from homeassistant.core import HomeAssistant
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
"""Common fixtures for the V2C tests."""
|
"""Common fixtures for the V2C tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from pytrydan.models.trydan import TrydanData
|
from pytrydan.models.trydan import TrydanData
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.v2c.const import DOMAIN
|
from homeassistant.components.v2c.const import DOMAIN
|
||||||
from homeassistant.const import CONF_HOST
|
from homeassistant.const import CONF_HOST
|
||||||
|
|
|
@ -1,7 +1,8 @@
|
||||||
"""Fixtures for Vacuum platform tests."""
|
"""Fixtures for Vacuum platform tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.config_entries import ConfigFlow
|
from homeassistant.config_entries import ConfigFlow
|
||||||
from homeassistant.core import HomeAssistant
|
from homeassistant.core import HomeAssistant
|
||||||
|
|
|
@ -1,8 +1,9 @@
|
||||||
"""The tests for Valve."""
|
"""The tests for Valve."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from syrupy.assertion import SnapshotAssertion
|
from syrupy.assertion import SnapshotAssertion
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.valve import (
|
from homeassistant.components.valve import (
|
||||||
DOMAIN,
|
DOMAIN,
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
"""Fixtures for the Velbus tests."""
|
"""Fixtures for the Velbus tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import MagicMock, patch
|
from unittest.mock import MagicMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.velbus.const import DOMAIN
|
from homeassistant.components.velbus.const import DOMAIN
|
||||||
from homeassistant.config_entries import ConfigEntry
|
from homeassistant.config_entries import ConfigEntry
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
"""Tests for the Velbus config flow."""
|
"""Tests for the Velbus config flow."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, MagicMock, patch
|
from unittest.mock import AsyncMock, MagicMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
import serial.tools.list_ports
|
import serial.tools.list_ports
|
||||||
from typing_extensions import Generator
|
|
||||||
from velbusaio.exceptions import VelbusConnectionFailed
|
from velbusaio.exceptions import VelbusConnectionFailed
|
||||||
|
|
||||||
from homeassistant.components import usb
|
from homeassistant.components import usb
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
"""Configuration for Velux tests."""
|
"""Configuration for Velux tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture
|
@pytest.fixture
|
||||||
|
|
|
@ -2,10 +2,10 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, MagicMock, patch
|
from unittest.mock import AsyncMock, MagicMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.verisure.const import CONF_GIID, DOMAIN
|
from homeassistant.components.verisure.const import CONF_GIID, DOMAIN
|
||||||
from homeassistant.const import CONF_EMAIL, CONF_PASSWORD
|
from homeassistant.const import CONF_EMAIL, CONF_PASSWORD
|
||||||
|
|
|
@ -2,13 +2,13 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from collections.abc import AsyncGenerator, Generator
|
||||||
from dataclasses import dataclass
|
from dataclasses import dataclass
|
||||||
from unittest.mock import AsyncMock, Mock, patch
|
from unittest.mock import AsyncMock, Mock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from PyViCare.PyViCareDeviceConfig import PyViCareDeviceConfig
|
from PyViCare.PyViCareDeviceConfig import PyViCareDeviceConfig
|
||||||
from PyViCare.PyViCareService import ViCareDeviceAccessor, readFeature
|
from PyViCare.PyViCareService import ViCareDeviceAccessor, readFeature
|
||||||
from typing_extensions import AsyncGenerator, Generator
|
|
||||||
|
|
||||||
from homeassistant.components.vicare.const import DOMAIN
|
from homeassistant.components.vicare.const import DOMAIN
|
||||||
from homeassistant.core import HomeAssistant
|
from homeassistant.core import HomeAssistant
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
"""Vilfo tests conftest."""
|
"""Vilfo tests conftest."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.vilfo import DOMAIN
|
from homeassistant.components.vilfo import DOMAIN
|
||||||
from homeassistant.const import CONF_ACCESS_TOKEN, CONF_HOST
|
from homeassistant.const import CONF_ACCESS_TOKEN, CONF_HOST
|
||||||
|
|
|
@ -2,10 +2,10 @@
|
||||||
|
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, MagicMock, patch
|
from unittest.mock import AsyncMock, MagicMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture
|
@pytest.fixture
|
||||||
|
|
|
@ -1,14 +1,13 @@
|
||||||
"""Test wake_word component setup."""
|
"""Test wake_word component setup."""
|
||||||
|
|
||||||
import asyncio
|
import asyncio
|
||||||
from collections.abc import AsyncIterable
|
from collections.abc import AsyncIterable, Generator
|
||||||
from functools import partial
|
from functools import partial
|
||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
from unittest.mock import patch
|
from unittest.mock import patch
|
||||||
|
|
||||||
from freezegun import freeze_time
|
from freezegun import freeze_time
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components import wake_word
|
from homeassistant.components import wake_word
|
||||||
from homeassistant.config_entries import ConfigEntry, ConfigEntryState, ConfigFlow
|
from homeassistant.config_entries import ConfigEntry, ConfigEntryState, ConfigFlow
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
"""Common fixtures for the World Air Quality Index (WAQI) tests."""
|
"""Common fixtures for the World Air Quality Index (WAQI) tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.waqi.const import CONF_STATION_NUMBER, DOMAIN
|
from homeassistant.components.waqi.const import CONF_STATION_NUMBER, DOMAIN
|
||||||
from homeassistant.const import CONF_API_KEY
|
from homeassistant.const import CONF_API_KEY
|
||||||
|
|
|
@ -1,7 +1,8 @@
|
||||||
"""Fixtures for water heater platform tests."""
|
"""Fixtures for water heater platform tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.config_entries import ConfigFlow
|
from homeassistant.config_entries import ConfigFlow
|
||||||
from homeassistant.core import HomeAssistant
|
from homeassistant.core import HomeAssistant
|
||||||
|
|
|
@ -1,7 +1,8 @@
|
||||||
"""Fixtures for Weather platform tests."""
|
"""Fixtures for Weather platform tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.config_entries import ConfigFlow
|
from homeassistant.config_entries import ConfigFlow
|
||||||
from homeassistant.core import HomeAssistant
|
from homeassistant.core import HomeAssistant
|
||||||
|
|
|
@ -1,12 +1,12 @@
|
||||||
"""Fixtures for Weatherflow integration tests."""
|
"""Fixtures for Weatherflow integration tests."""
|
||||||
|
|
||||||
import asyncio
|
import asyncio
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, patch
|
from unittest.mock import AsyncMock, patch
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from pyweatherflowudp.client import EVENT_DEVICE_DISCOVERED
|
from pyweatherflowudp.client import EVENT_DEVICE_DISCOVERED
|
||||||
from pyweatherflowudp.device import WeatherFlowDevice
|
from pyweatherflowudp.device import WeatherFlowDevice
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
from homeassistant.components.weatherflow.const import DOMAIN
|
from homeassistant.components.weatherflow.const import DOMAIN
|
||||||
|
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
"""Common fixtures for the WeatherflowCloud tests."""
|
"""Common fixtures for the WeatherflowCloud tests."""
|
||||||
|
|
||||||
|
from collections.abc import Generator
|
||||||
from unittest.mock import AsyncMock, Mock, patch
|
from unittest.mock import AsyncMock, Mock, patch
|
||||||
|
|
||||||
from aiohttp import ClientResponseError
|
from aiohttp import ClientResponseError
|
||||||
import pytest
|
import pytest
|
||||||
from typing_extensions import Generator
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture
|
@pytest.fixture
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Reference in a new issue