mirror of
https://github.com/home-assistant/core.git
synced 2025-04-25 01:38:02 +00:00
Add BinarySensorEntity to pylint checks (#74131)
This commit is contained in:
parent
f2809262d5
commit
ebf21d1bd7
@ -678,6 +678,25 @@ _INHERITANCE_MATCH: dict[str, list[ClassTypeHintMatch]] = {
|
||||
],
|
||||
),
|
||||
],
|
||||
"binary_sensor": [
|
||||
ClassTypeHintMatch(
|
||||
base_class="Entity",
|
||||
matches=_ENTITY_MATCH,
|
||||
),
|
||||
ClassTypeHintMatch(
|
||||
base_class="BinarySensorEntity",
|
||||
matches=[
|
||||
TypeHintMatch(
|
||||
function_name="device_class",
|
||||
return_type=["BinarySensorDeviceClass", "str", None],
|
||||
),
|
||||
TypeHintMatch(
|
||||
function_name="is_on",
|
||||
return_type=["bool", None],
|
||||
),
|
||||
],
|
||||
),
|
||||
],
|
||||
"cover": [
|
||||
ClassTypeHintMatch(
|
||||
base_class="Entity",
|
||||
|
Loading…
x
Reference in New Issue
Block a user