Files
homeassistant-core/tests/components/switchbot_cloud/conftest.py
T

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

17 lines
429 B
Python
Raw Normal View History

2023-09-16 23:00:41 +09:00
"""Common fixtures for the SwitchBot via API tests."""
2023-09-16 23:00:41 +09:00
from unittest.mock import AsyncMock, patch
import pytest
from typing_extensions import Generator
2023-09-16 23:00:41 +09:00
@pytest.fixture
def mock_setup_entry() -> Generator[AsyncMock]:
2023-09-16 23:00:41 +09:00
"""Override async_setup_entry."""
with patch(
"homeassistant.components.switchbot_cloud.async_setup_entry",
return_value=True,
) as mock_setup_entry:
yield mock_setup_entry