Fix incorrect type hint in dremel_3d_printer tests (#118709)

pull/118736/head
epenet 2024-06-03 17:16:48 +02:00 committed by GitHub
parent 99e02fe2b2
commit dd90fb15e1
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 7 additions and 11 deletions

View File

@ -1,6 +1,6 @@
"""Binary sensor tests for the Dremel 3D Printer integration."""
from unittest.mock import AsyncMock
import pytest
from homeassistant.components.binary_sensor import BinarySensorDeviceClass
from homeassistant.components.dremel_3d_printer.const import DOMAIN
@ -11,11 +11,9 @@ from homeassistant.setup import async_setup_component
from tests.common import MockConfigEntry
@pytest.mark.usefixtures("connection", "entity_registry_enabled_by_default")
async def test_binary_sensors(
hass: HomeAssistant,
connection,
config_entry: MockConfigEntry,
entity_registry_enabled_by_default: AsyncMock,
hass: HomeAssistant, config_entry: MockConfigEntry
) -> None:
"""Test we get binary sensor data."""
await hass.config_entries.async_setup(config_entry.entry_id)

View File

@ -1,6 +1,6 @@
"""Button tests for the Dremel 3D Printer integration."""
from unittest.mock import AsyncMock, patch
from unittest.mock import patch
import pytest
@ -22,11 +22,10 @@ from tests.common import MockConfigEntry
("resume", "resume"),
],
)
@pytest.mark.usefixtures("connection", "entity_registry_enabled_by_default")
async def test_buttons(
hass: HomeAssistant,
connection: None,
config_entry: MockConfigEntry,
entity_registry_enabled_by_default: AsyncMock,
button: str,
function: str,
) -> None:

View File

@ -1,9 +1,9 @@
"""Sensor tests for the Dremel 3D Printer integration."""
from datetime import datetime
from unittest.mock import AsyncMock
from freezegun.api import FrozenDateTimeFactory
import pytest
from homeassistant.components.dremel_3d_printer.const import DOMAIN
from homeassistant.components.sensor import (
@ -26,11 +26,10 @@ from homeassistant.util.dt import UTC
from tests.common import MockConfigEntry
@pytest.mark.usefixtures("connection", "entity_registry_enabled_by_default")
async def test_sensors(
hass: HomeAssistant,
connection,
config_entry: MockConfigEntry,
entity_registry_enabled_by_default: AsyncMock,
freezer: FrozenDateTimeFactory,
) -> None:
"""Test we get sensor data."""