mirror of
https://github.com/home-assistant/core.git
synced 2026-04-20 16:39:02 +02:00
Fix untranslated button error in Tailwind (#168031)
This commit is contained in:
@@ -68,7 +68,6 @@ class TailwindButtonEntity(TailwindEntity, ButtonEntity):
|
||||
await self.entity_description.press_fn(self.coordinator.tailwind)
|
||||
except TailwindError as exc:
|
||||
raise HomeAssistantError(
|
||||
str(exc),
|
||||
translation_domain=DOMAIN,
|
||||
translation_key="communication_error",
|
||||
) from exc
|
||||
|
||||
@@ -54,7 +54,10 @@ async def test_number_entities(
|
||||
# Test error handling
|
||||
mock_tailwind.identify.side_effect = TailwindError("Some error")
|
||||
|
||||
with pytest.raises(HomeAssistantError, match="Some error") as excinfo:
|
||||
with pytest.raises(
|
||||
HomeAssistantError,
|
||||
match="An error occurred while communicating with the Tailwind device",
|
||||
) as excinfo:
|
||||
await hass.services.async_call(
|
||||
BUTTON_DOMAIN,
|
||||
SERVICE_PRESS,
|
||||
|
||||
Reference in New Issue
Block a user