Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove homeassistant from conversation dependencies #92170

Merged
merged 2 commits into from
Apr 28, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion homeassistant/components/conversation/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"domain": "conversation",
"name": "Conversation",
"codeowners": ["@home-assistant/core", "@synesthesiam"],
"dependencies": ["homeassistant", "http"],
"dependencies": ["http"],
"documentation": "https://www.home-assistant.io/integrations/conversation",
"integration_type": "system",
"iot_class": "local_push",
Expand Down
1 change: 1 addition & 0 deletions tests/components/assist_pipeline/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -243,6 +243,7 @@ async def async_setup_entry_stt_platform(
)
mock_platform(hass, "test.config_flow")

assert await async_setup_component(hass, "homeassistant", {})
assert await async_setup_component(hass, tts.DOMAIN, {"tts": {"platform": "test"}})
assert await async_setup_component(hass, stt.DOMAIN, {"stt": {"platform": "test"}})
assert await async_setup_component(hass, "media_source", {})
Expand Down
6 changes: 6 additions & 0 deletions tests/components/assist_pipeline/test_pipeline.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,12 @@
from tests.common import MockModule, flush_store, mock_integration, mock_platform


@pytest.fixture(autouse=True)
async def load_homeassistant(hass) -> None:
"""Load the homeassistant integration."""
assert await async_setup_component(hass, "homeassistant", {})


async def test_load_datasets(hass: HomeAssistant, init_components) -> None:
"""Make sure that we can load/save data correctly."""

Expand Down
5 changes: 5 additions & 0 deletions tests/components/conversation/test_init.py
Original file line number Diff line number Diff line change
Expand Up @@ -1162,6 +1162,7 @@ async def test_ws_api(
hass: HomeAssistant, hass_ws_client: WebSocketGenerator, payload
) -> None:
"""Test the Websocket conversation API."""
assert await async_setup_component(hass, "homeassistant", {})
assert await async_setup_component(hass, "conversation", {})
client = await hass_ws_client(hass)

Expand Down Expand Up @@ -1192,6 +1193,7 @@ async def test_ws_prepare(
hass: HomeAssistant, hass_ws_client: WebSocketGenerator, agent_id
) -> None:
"""Test the Websocket prepare conversation API."""
assert await async_setup_component(hass, "homeassistant", {})
assert await async_setup_component(hass, "conversation", {})
agent = await conversation._get_agent_manager(hass).async_get_agent()
assert isinstance(agent, conversation.DefaultAgent)
Expand Down Expand Up @@ -1320,6 +1322,7 @@ async def test_custom_sentences_config(
async def test_prepare_reload(hass: HomeAssistant) -> None:
"""Test calling the reload service."""
language = hass.config.language
assert await async_setup_component(hass, "homeassistant", {})
assert await async_setup_component(hass, "conversation", {})

# Load intents
Expand All @@ -1340,6 +1343,7 @@ async def test_prepare_reload(hass: HomeAssistant) -> None:

async def test_prepare_fail(hass: HomeAssistant) -> None:
"""Test calling prepare with a non-existent language."""
assert await async_setup_component(hass, "homeassistant", {})
assert await async_setup_component(hass, "conversation", {})

# Load intents
Expand Down Expand Up @@ -1387,6 +1391,7 @@ async def test_language_region(
async def test_reload_on_new_component(hass: HomeAssistant) -> None:
"""Test intents being reloaded when a new component is loaded."""
language = hass.config.language
assert await async_setup_component(hass, "homeassistant", {})
assert await async_setup_component(hass, "conversation", {})

# Load intents
Expand Down
7 changes: 7 additions & 0 deletions tests/components/esphome/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
)
from homeassistant.const import CONF_HOST, CONF_PASSWORD, CONF_PORT
from homeassistant.core import HomeAssistant
from homeassistant.setup import async_setup_component

from . import DASHBOARD_HOST, DASHBOARD_PORT, DASHBOARD_SLUG

Expand All @@ -31,6 +32,12 @@ def esphome_mock_async_zeroconf(mock_async_zeroconf):
"""Auto mock zeroconf."""


@pytest.fixture(autouse=True)
async def load_homeassistant(hass) -> None:
"""Load the homeassistant integration."""
assert await async_setup_component(hass, "homeassistant", {})


@pytest.fixture
def mock_config_entry(hass) -> MockConfigEntry:
"""Return the default mocked config entry."""
Expand Down
6 changes: 6 additions & 0 deletions tests/components/voip/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,12 @@
from tests.common import MockConfigEntry


@pytest.fixture(autouse=True)
async def load_homeassistant(hass) -> None:
"""Load the homeassistant integration."""
assert await async_setup_component(hass, "homeassistant", {})


@pytest.fixture
def config_entry(hass: HomeAssistant) -> MockConfigEntry:
"""Create a config entry."""
Expand Down