From 52bd3efad9f85154324f7a0906fa1257562b60f6 Mon Sep 17 00:00:00 2001 From: Paulus Schoutsen Date: Tue, 2 Apr 2024 11:30:41 -0400 Subject: [PATCH] Clean up unnecessary setup calls in tests (#114644) --- tests/components/google_generative_ai_conversation/conftest.py | 1 - tests/components/google_generative_ai_conversation/test_init.py | 2 -- 2 files changed, 3 deletions(-) diff --git a/tests/components/google_generative_ai_conversation/conftest.py b/tests/components/google_generative_ai_conversation/conftest.py index 5c979d3bc47..c377a469df0 100644 --- a/tests/components/google_generative_ai_conversation/conftest.py +++ b/tests/components/google_generative_ai_conversation/conftest.py @@ -27,7 +27,6 @@ def mock_config_entry(hass): @pytest.fixture async def mock_init_component(hass: HomeAssistant, mock_config_entry: ConfigEntry): """Initialize integration.""" - assert await async_setup_component(hass, "homeassistant", {}) with patch("google.generativeai.get_model"): assert await async_setup_component( hass, "google_generative_ai_conversation", {} diff --git a/tests/components/google_generative_ai_conversation/test_init.py b/tests/components/google_generative_ai_conversation/test_init.py index befe3b93d12..07254be9e3f 100644 --- a/tests/components/google_generative_ai_conversation/test_init.py +++ b/tests/components/google_generative_ai_conversation/test_init.py @@ -10,7 +10,6 @@ from homeassistant.components import conversation from homeassistant.core import Context, HomeAssistant from homeassistant.exceptions import HomeAssistantError from homeassistant.helpers import area_registry as ar, device_registry as dr, intent -from homeassistant.setup import async_setup_component from tests.common import MockConfigEntry @@ -125,7 +124,6 @@ async def test_template_error( hass: HomeAssistant, mock_config_entry: MockConfigEntry ) -> None: """Test that template error handling works.""" - assert await async_setup_component(hass, "homeassistant", {}) hass.config_entries.async_update_entry( mock_config_entry, options={