Use relative paths in configuration validation error messages (#104064)

This commit is contained in:
Erik Montnemery
2023-11-16 10:56:47 +01:00
committed by GitHub
parent 98030a9ce1
commit d8a49b14e5
6 changed files with 141 additions and 113 deletions

View File

@@ -82,9 +82,8 @@ async def test_bad_core_config(hass: HomeAssistant) -> None:
error = CheckConfigError(
(
"Invalid config for [homeassistant] at "
f"{hass.config.path(YAML_CONFIG_FILE)}, line 2: "
"not a valid value for dictionary value 'unit_system', got 'bad'."
f"Invalid config for [homeassistant] at {YAML_CONFIG_FILE}, line 2:"
" not a valid value for dictionary value 'unit_system', got 'bad'."
),
"homeassistant",
{"unit_system": "bad"},