Improve lists in integrations [C-D] (#113072)

This commit is contained in:
Joost Lekkerkerker 2024-03-11 18:58:35 +01:00 committed by GitHub
parent 4d77bec681
commit c75342bd9a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
32 changed files with 276 additions and 311 deletions

View file

@ -140,10 +140,7 @@ def is_closing(hass, ent):
def _create_tuples(enum: Enum, constant_prefix: str) -> list[tuple[Enum, str]]:
result = []
for enum in enum:
result.append((enum, constant_prefix))
return result
return [(enum_field, constant_prefix) for enum_field in enum]
def test_all() -> None: