mirror of
https://github.com/home-assistant/core.git
synced 2026-09-05 02:25:07 -05:00
Fix missing description placeholders in MQTT subentry flow (#156684)
This commit is contained in:
@@ -4237,7 +4237,8 @@ class MQTTSubentryFlowHandler(ConfigSubentryFlow):
|
||||
return self.async_show_form(
|
||||
step_id="entity",
|
||||
data_schema=data_schema,
|
||||
description_placeholders={
|
||||
description_placeholders=TRANSLATION_DESCRIPTION_PLACEHOLDERS
|
||||
| {
|
||||
"mqtt_device": device_name,
|
||||
"entity_name_label": entity_name_label,
|
||||
"platform_label": platform_label,
|
||||
|
||||
@@ -3770,6 +3770,10 @@ async def test_subentry_configflow(
|
||||
assert result["type"] is FlowResultType.FORM
|
||||
assert result["step_id"] == "entity"
|
||||
assert result["errors"] == {}
|
||||
assert "description_placeholders" in result
|
||||
for placeholder, translation in TRANSLATION_DESCRIPTION_PLACEHOLDERS.items():
|
||||
assert placeholder in result["description_placeholders"]
|
||||
assert result["description_placeholders"][placeholder] == translation
|
||||
|
||||
# Process entity flow (initial step)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user