Fix typing.Any spelling (#49673)
This commit is contained in:
parent
85438db1ec
commit
631ab367e2
17 changed files with 55 additions and 36 deletions
|
@ -1,6 +1,7 @@
|
|||
"""Test the MySensors config flow."""
|
||||
from __future__ import annotations
|
||||
|
||||
from typing import Any
|
||||
from unittest.mock import patch
|
||||
|
||||
import pytest
|
||||
|
@ -369,7 +370,7 @@ async def test_config_invalid(
|
|||
mqtt: config_entries.ConfigEntry,
|
||||
gateway_type: ConfGatewayType,
|
||||
expected_step_id: str,
|
||||
user_input: dict[str, any],
|
||||
user_input: dict[str, Any],
|
||||
err_field,
|
||||
err_string,
|
||||
) -> None:
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
"""Test function in __init__.py."""
|
||||
from __future__ import annotations
|
||||
|
||||
from typing import Any
|
||||
from unittest.mock import patch
|
||||
|
||||
import pytest
|
||||
|
@ -232,7 +233,7 @@ async def test_import(
|
|||
config: ConfigType,
|
||||
expected_calls: int,
|
||||
expected_to_succeed: bool,
|
||||
expected_config_flow_user_input: dict[str, any],
|
||||
expected_config_flow_user_input: dict[str, Any],
|
||||
) -> None:
|
||||
"""Test importing a gateway."""
|
||||
await async_setup_component(hass, "persistent_notification", {})
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
"""Mock device for testing purposes."""
|
||||
|
||||
from typing import Mapping
|
||||
from typing import Any, Mapping
|
||||
from unittest.mock import AsyncMock
|
||||
|
||||
from homeassistant.components.upnp.const import (
|
||||
|
@ -60,7 +60,7 @@ class MockDevice(Device):
|
|||
"""Get the hostname."""
|
||||
return "mock-hostname"
|
||||
|
||||
async def async_get_traffic_data(self) -> Mapping[str, any]:
|
||||
async def async_get_traffic_data(self) -> Mapping[str, Any]:
|
||||
"""Get traffic data."""
|
||||
self.times_polled += 1
|
||||
return {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue