Skip to content
Snippets Groups Projects
Unverified Commit 4b225a87 authored by Davey Chu's avatar Davey Chu Committed by GitHub
Browse files

Use references in airvisual strings.json (#41005)

parent b45215f1
No related branches found
No related tags found
No related merge requests found
...@@ -166,7 +166,7 @@ class AirVisualFlowHandler(config_entries.ConfigFlow, domain=DOMAIN): ...@@ -166,7 +166,7 @@ class AirVisualFlowHandler(config_entries.ConfigFlow, domain=DOMAIN):
return self.async_show_form( return self.async_show_form(
step_id="node_pro", step_id="node_pro",
data_schema=self.node_pro_schema, data_schema=self.node_pro_schema,
errors={CONF_IP_ADDRESS: "unable_to_connect"}, errors={CONF_IP_ADDRESS: "cannot_connect"},
) )
await node.async_disconnect() await node.async_disconnect()
......
...@@ -29,9 +29,9 @@ ...@@ -29,9 +29,9 @@
} }
}, },
"error": { "error": {
"general_error": "There was an unknown error.", "general_error": "[%key:common::config_flow::error::unknown%]",
"invalid_api_key": "Invalid API key provided.", "invalid_api_key": "[%key:common::config_flow::error::invalid_api_key%]",
"unable_to_connect": "Unable to connect to Node/Pro unit." "cannot_connect": "[%key:common::config_flow::error::cannot_connect%]"
}, },
"abort": { "abort": {
"already_configured": "These coordinates or Node/Pro ID are already registered." "already_configured": "These coordinates or Node/Pro ID are already registered."
......
...@@ -140,7 +140,7 @@ async def test_node_pro_error(hass): ...@@ -140,7 +140,7 @@ async def test_node_pro_error(hass):
result["flow_id"], user_input=node_pro_conf result["flow_id"], user_input=node_pro_conf
) )
assert result["type"] == data_entry_flow.RESULT_TYPE_FORM assert result["type"] == data_entry_flow.RESULT_TYPE_FORM
assert result["errors"] == {CONF_IP_ADDRESS: "unable_to_connect"} assert result["errors"] == {CONF_IP_ADDRESS: "cannot_connect"}
async def test_options_flow(hass): async def test_options_flow(hass):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment