Enable Ruff D212 (#87347)

This commit is contained in:
Franck Nijhof 2023-02-03 23:08:48 +01:00 committed by GitHub
parent 97de0c6d9a
commit ca1a12898c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
237 changed files with 353 additions and 707 deletions

View file

@ -78,8 +78,7 @@ class EntityTestInfo:
@dataclass
class DeviceTriggerInfo:
"""
Describe a automation trigger we expect to be created.
"""Describe a automation trigger we expect to be created.
We only use these for a stateless characteristic like a doorbell.
"""

View file

@ -1,5 +1,4 @@
"""
Regression tests for Aqara Gateway V3.
"""Regression tests for Aqara Gateway V3.
https://github.com/home-assistant/core/issues/20957
"""

View file

@ -1,5 +1,4 @@
"""
Regression tests for Aqara AR004.
"""Regression tests for Aqara AR004.
This device has a non-standard programmable stateless switch service that has a
service-label-index despite not being linked to a service-label.

View file

@ -1,5 +1,4 @@
"""
Regression tests for Ecobee 3.
"""Regression tests for Ecobee 3.
https://github.com/home-assistant/core/issues/15336
"""

View file

@ -1,5 +1,4 @@
"""
Regression tests for Ecobee occupancy.
"""Regression tests for Ecobee occupancy.
https://github.com/home-assistant/core/issues/31827
"""

View file

@ -65,8 +65,7 @@ async def test_koogeek_ls1_setup(hass):
@pytest.mark.parametrize("failure_cls", [AccessoryDisconnectedError, EncryptionError])
async def test_recover_from_failure(hass, utcnow, failure_cls):
"""
Test that entity actually recovers from a network connection drop.
"""Test that entity actually recovers from a network connection drop.
See https://github.com/home-assistant/core/issues/18949
"""

View file

@ -1,5 +1,4 @@
"""
Make sure that existing Koogeek SW2 is enumerated correctly.
"""Make sure that existing Koogeek SW2 is enumerated correctly.
This Koogeek device has a custom power sensor that extra handling.

View file

@ -1,5 +1,4 @@
"""
Regression tests for Aqara Gateway V3.
"""Regression tests for Aqara Gateway V3.
https://github.com/home-assistant/core/issues/20885
"""

View file

@ -1,5 +1,4 @@
"""
Regression tests for Netamo Doorbell.
"""Regression tests for Netamo Doorbell.
https://github.com/home-assistant/core/issues/44596
"""

View file

@ -1,5 +1,4 @@
"""
Regression tests for Netamo Smart CO Alarm.
"""Regression tests for Netamo Smart CO Alarm.
https://github.com/home-assistant/core/issues/78903
"""

View file

@ -1,5 +1,4 @@
"""
Regression tests for Netamo Healthy Home Coach.
"""Regression tests for Netamo Healthy Home Coach.
https://github.com/home-assistant/core/issues/73360
"""

View file

@ -1,5 +1,4 @@
"""
Make sure that existing RainMachine support isn't broken.
"""Make sure that existing RainMachine support isn't broken.
https://github.com/home-assistant/core/issues/31745
"""

View file

@ -1,5 +1,4 @@
"""
Test against characteristics captured from a SIMPLEconnect Fan.
"""Test against characteristics captured from a SIMPLEconnect Fan.
https://github.com/home-assistant/core/issues/26180
"""

View file

@ -1,5 +1,4 @@
"""
Test against characteristics captured from a Velux Gateway.
"""Test against characteristics captured from a Velux Gateway.
https://github.com/home-assistant/core/issues/44314
"""

View file

@ -761,8 +761,7 @@ async def test_heater_cooler_change_thermostat_state(hass, utcnow):
async def test_can_turn_on_after_off(hass, utcnow):
"""
Test that we always force device from inactive to active when setting mode.
"""Test that we always force device from inactive to active when setting mode.
This is a regression test for #81863.
"""

View file

@ -405,8 +405,7 @@ async def test_discovery_does_not_ignore_non_homekit(hass, controller):
async def test_discovery_broken_pairing_flag(hass, controller):
"""
There is already a config entry for the pairing and its pairing flag is wrong in zeroconf.
"""There is already a config entry for the pairing and its pairing flag is wrong in zeroconf.
We have seen this particular implementation error in 2 different devices.
"""

View file

@ -89,8 +89,7 @@ DEVICE_MIGRATION_TESTS = [
async def test_migrate_device_id_no_serial_skip_if_other_owner(
hass: HomeAssistant, variant: DeviceMigrationTest
):
"""
Don't migrate unrelated devices.
"""Don't migrate unrelated devices.
Create a device registry entry that needs migrate, but belongs to a different
config entry. It should be ignored.

View file

@ -8,8 +8,7 @@ from .common import get_next_aid, setup_test_component
def create_fan_service(accessory):
"""
Define fan v1 characteristics as per HAP spec.
"""Define fan v1 characteristics as per HAP spec.
This service is no longer documented in R2 of the public HAP spec but existing
devices out there use it (like the SIMPLEconnect fan)

View file

@ -12,8 +12,7 @@ from .common import get_next_aid, setup_test_component
def create_tv_service(accessory):
"""
Define tv characteristics.
"""Define tv characteristics.
The TV is not currently documented publicly - this is based on observing really TV's that have HomeKit support.
"""