Use references in Neato translation strings (#41009)

* Replace unexpected_error with unknown key in Neato

* Replace string with reference

* Revert the specific language json files back to unexpected_error

* Use reference for already_configured

* Change invalid_credentials to invalid_auth key

* Use reference for invalid_auth

* Use invalid_auth in the neato test

* Replace abort.invalid_credentials with invalid_auth
This commit is contained in:
Melvin authored and GitHub committed 2020-10-03 02:42:07 +02:00
1 parent 3a266fa116
commit 414633a129
3 files changed
+10 -10

No files matched your search

+4 -4
View File
@@ -118,7 +118,7 @@ async def test_abort_on_invalid_credentials(hass):
}
)
assert result["type"] == data_entry_flow.RESULT_TYPE_FORM
assert result["errors"] == {"base": "invalid_credentials"}
assert result["errors"] == {"base": "invalid_auth"}
result = await flow.async_step_import(
{
@@ -128,7 +128,7 @@ async def test_abort_on_invalid_credentials(hass):
}
)
assert result["type"] == data_entry_flow.RESULT_TYPE_ABORT
assert result["reason"] == "invalid_credentials"
assert result["reason"] == "invalid_auth"
async def test_abort_on_unexpected_error(hass):
@@ -147,7 +147,7 @@ async def test_abort_on_unexpected_error(hass):
}
)
assert result["type"] == data_entry_flow.RESULT_TYPE_FORM
assert result["errors"] == {"base": "unexpected_error"}
assert result["errors"] == {"base": "unknown"}
result = await flow.async_step_import(
{
@@ -157,4 +157,4 @@ async def test_abort_on_unexpected_error(hass):
}
)
assert result["type"] == data_entry_flow.RESULT_TYPE_ABORT
assert result["reason"] == "unexpected_error"
assert result["reason"] == "unknown"