diff --git a/tests/components/spotify/test_config_flow.py b/tests/components/spotify/test_config_flow.py index cd0be3f7cc8..fbc5bde9e58 100644 --- a/tests/components/spotify/test_config_flow.py +++ b/tests/components/spotify/test_config_flow.py @@ -93,7 +93,9 @@ async def test_full_flow( }, ) - with patch("homeassistant.components.spotify.config_flow.Spotify") as spotify_mock: + with patch( + "homeassistant.components.spotify.async_setup_entry", return_value=True + ), patch("homeassistant.components.spotify.config_flow.Spotify") as spotify_mock: spotify_mock.return_value.current_user.return_value = { "id": "fake_id", "display_name": "frenck", @@ -210,7 +212,9 @@ async def test_reauthentication( }, ) - with patch("homeassistant.components.spotify.config_flow.Spotify") as spotify_mock: + with patch( + "homeassistant.components.spotify.async_setup_entry", return_value=True + ), patch("homeassistant.components.spotify.config_flow.Spotify") as spotify_mock: spotify_mock.return_value.current_user.return_value = {"id": "frenck"} result = await hass.config_entries.flow.async_configure(result["flow_id"])