Small cleanup for Vodafone Station (#142867)

This commit is contained in:
Simone Chemelli 2025-04-13 18:57:00 +02:00 committed by GitHub
parent 6d78c961d9
commit b25a0e2272
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 11 additions and 11 deletions

View File

@ -156,8 +156,6 @@ class VodafoneStationConfigFlow(ConfigFlow, domain=DOMAIN):
errors: dict[str, str] = {}
errors = {}
try:
await validate_input(self.hass, user_input)
except aiovodafone_exceptions.AlreadyLogged:

View File

@ -246,12 +246,14 @@ async def test_reconfigure_successful(
# original entry
assert mock_config_entry.data["host"] == "fake_host"
new_host = "192.168.100.60"
reconfigure_result = await hass.config_entries.flow.async_configure(
result["flow_id"],
{
"host": "192.168.100.60",
"password": "fake_password",
"username": "fake_username",
user_input={
CONF_HOST: new_host,
CONF_PASSWORD: "fake_password",
CONF_USERNAME: "fake_username",
},
)
@ -259,7 +261,7 @@ async def test_reconfigure_successful(
assert reconfigure_result["reason"] == "reconfigure_successful"
# changed entry
assert mock_config_entry.data["host"] == "192.168.100.60"
assert mock_config_entry.data["host"] == new_host
@pytest.mark.parametrize(
@ -290,10 +292,10 @@ async def test_reconfigure_fails(
reconfigure_result = await hass.config_entries.flow.async_configure(
result["flow_id"],
{
"host": "192.168.100.60",
"password": "fake_password",
"username": "fake_username",
user_input={
CONF_HOST: "192.168.100.60",
CONF_PASSWORD: "fake_password",
CONF_USERNAME: "fake_username",
},
)