Rename "CO2 Signal" display name to Electricity Maps for consistency (#130242)

* Update strings.json for Electricity Maps

* Update strings.json

* Update config_flow.py

* Update test_config_flow.py

* Fix test
pull/130713/head
Olivier Corradi 2024-11-11 17:34:29 +01:00 committed by Franck Nijhof
parent c399d8f571
commit 9f447af468
No known key found for this signature in database
GPG Key ID: D62583BA8AB11CA3
2 changed files with 3 additions and 3 deletions

View File

@ -168,7 +168,7 @@ class ElectricityMapsConfigFlow(ConfigFlow, domain=DOMAIN):
)
return self.async_create_entry(
title=get_extra_name(data) or "CO2 Signal",
title=get_extra_name(data) or "Electricity Maps",
data=data,
)

View File

@ -44,7 +44,7 @@ async def test_form_home(hass: HomeAssistant) -> None:
await hass.async_block_till_done()
assert result2["type"] is FlowResultType.CREATE_ENTRY
assert result2["title"] == "CO2 Signal"
assert result2["title"] == "Electricity Maps"
assert result2["data"] == {
"api_key": "api_key",
}
@ -185,7 +185,7 @@ async def test_form_error_handling(
await hass.async_block_till_done()
assert result["type"] is FlowResultType.CREATE_ENTRY
assert result["title"] == "CO2 Signal"
assert result["title"] == "Electricity Maps"
assert result["data"] == {
"api_key": "api_key",
}