mirror of
https://github.com/home-assistant/core.git
synced 2025-07-11 15:27:08 +00:00
Fix more flaky translation checks (#131824)
This commit is contained in:
parent
d9832f8c3a
commit
c4e5b59326
@ -34,6 +34,7 @@ from tests.common import (
|
|||||||
mock_integration,
|
mock_integration,
|
||||||
mock_platform,
|
mock_platform,
|
||||||
mock_restore_cache,
|
mock_restore_cache,
|
||||||
|
reset_translation_cache,
|
||||||
)
|
)
|
||||||
from tests.typing import ClientSessionGenerator, WebSocketGenerator
|
from tests.typing import ClientSessionGenerator, WebSocketGenerator
|
||||||
|
|
||||||
@ -518,6 +519,9 @@ async def test_default_engine_prefer_cloud_entity(
|
|||||||
assert provider_engine.name == "test"
|
assert provider_engine.name == "test"
|
||||||
assert async_default_engine(hass) == "stt.cloud_stt_entity"
|
assert async_default_engine(hass) == "stt.cloud_stt_entity"
|
||||||
|
|
||||||
|
# Reset the `cloud` translations cache to avoid flaky translation checks
|
||||||
|
reset_translation_cache(hass, ["cloud"])
|
||||||
|
|
||||||
|
|
||||||
async def test_get_engine_legacy(
|
async def test_get_engine_legacy(
|
||||||
hass: HomeAssistant, tmp_path: Path, mock_provider: MockSTTProvider
|
hass: HomeAssistant, tmp_path: Path, mock_provider: MockSTTProvider
|
||||||
|
@ -1990,5 +1990,5 @@ async def test_default_engine_prefer_cloud_entity(
|
|||||||
assert provider_engine == "test"
|
assert provider_engine == "test"
|
||||||
assert tts.async_default_engine(hass) == "tts.cloud_tts_entity"
|
assert tts.async_default_engine(hass) == "tts.cloud_tts_entity"
|
||||||
|
|
||||||
# Reset the `cloud` translations cache
|
# Reset the `cloud` translations cache to avoid flaky translation checks
|
||||||
reset_translation_cache(hass, ["cloud"])
|
reset_translation_cache(hass, ["cloud"])
|
||||||
|
Loading…
x
Reference in New Issue
Block a user