Avoid waiting for integration platforms in the parent integration (#112467)

This commit is contained in:
J. Nick Koston
2024-03-05 21:16:42 -10:00
committed by GitHub
parent 87739bc072
commit f3a9756f81
29 changed files with 126 additions and 5 deletions

View File

@@ -89,6 +89,7 @@ async def test_save_preferences(
mock_energy_platform,
) -> None:
"""Test we can save preferences."""
await hass.async_block_till_done()
client = await hass_ws_client(hass)
# Test saving default prefs is also valid.
@@ -283,6 +284,7 @@ async def test_get_solar_forecast(
entry.add_to_hass(hass)
manager = await data.async_get_manager(hass)
manager.data = data.EnergyManager.default_preferences()
manager.data["energy_sources"].append(
{
@@ -292,6 +294,7 @@ async def test_get_solar_forecast(
}
)
client = await hass_ws_client(hass)
await hass.async_block_till_done()
await client.send_json({"id": 5, "type": "energy/solar_forecast"})