From 32f3f46542df303501db8153ccf242054c08fd2b Mon Sep 17 00:00:00 2001 From: Marc Mueller <30130371+cdce8p@users.noreply.github.com> Date: Fri, 8 Mar 2024 19:16:21 +0100 Subject: [PATCH] Add empty line after module docstring (2) [tests.components] (#112737) --- tests/components/accuweather/test_system_health.py | 1 + tests/components/adguard/test_config_flow.py | 1 + tests/components/aemet/test_weather.py | 1 + tests/components/agent_dvr/test_config_flow.py | 1 + tests/components/air_quality/test_air_quality.py | 1 + tests/components/airly/test_system_health.py | 1 + tests/components/airnow/conftest.py | 1 + tests/components/airthings_ble/test_sensor.py | 1 + tests/components/airzone/test_climate.py | 1 + tests/components/alarm_control_panel/test_device_action.py | 1 + tests/components/alarm_control_panel/test_device_condition.py | 1 + tests/components/alarm_control_panel/test_reproduce_state.py | 1 + tests/components/alarm_control_panel/test_significant_change.py | 1 + tests/components/alert/test_reproduce_state.py | 1 + tests/components/alexa/test_config.py | 1 + tests/components/alexa/test_state_report.py | 1 + tests/components/ambient_station/conftest.py | 1 + tests/components/apcupsd/test_init.py | 1 + tests/components/api/test_init.py | 1 + tests/components/arcam_fmj/test_device_trigger.py | 1 + tests/components/assist_pipeline/test_init.py | 1 + tests/components/assist_pipeline/test_vad.py | 1 + tests/components/assist_pipeline/test_websocket.py | 1 + tests/components/atag/conftest.py | 1 + tests/components/august/test_binary_sensor.py | 1 + tests/components/august/test_lock.py | 1 + tests/components/auth/conftest.py | 1 + tests/components/auth/test_indieauth.py | 1 + tests/components/automation/test_blueprint.py | 1 + tests/components/automation/test_init.py | 1 + tests/components/automation/test_reproduce_state.py | 1 + tests/components/aws/test_init.py | 1 + tests/components/axis/test_binary_sensor.py | 1 + tests/components/axis/test_diagnostics.py | 1 + tests/components/azure_event_hub/test_config_flow.py | 1 + tests/components/bayesian/test_binary_sensor.py | 1 + tests/components/blebox/test_button.py | 1 + tests/components/blebox/test_climate.py | 1 + tests/components/blebox/test_cover.py | 1 + tests/components/blebox/test_init.py | 1 + tests/components/blebox/test_light.py | 1 + tests/components/blebox/test_sensor.py | 1 + tests/components/blebox/test_switch.py | 1 + tests/components/blueprint/test_default_blueprints.py | 1 + tests/components/blueprint/test_importer.py | 1 + tests/components/blueprint/test_models.py | 1 + tests/components/blueprint/test_schemas.py | 1 + tests/components/bluetooth/test_api.py | 1 + tests/components/bluetooth/test_init.py | 1 + tests/components/bluetooth/test_scanner.py | 1 + tests/components/bmw_connected_drive/test_diagnostics.py | 1 + tests/components/broadlink/test_config_flow.py | 1 + tests/components/broadlink/test_helpers.py | 1 + tests/components/bthome/test_device_trigger.py | 1 + tests/components/buienradar/test_camera.py | 1 + tests/components/button/test_device_action.py | 1 + tests/components/cert_expiry/test_config_flow.py | 1 + tests/components/clicksend_tts/test_notify.py | 1 + tests/components/climate/test_device_action.py | 1 + tests/components/climate/test_device_condition.py | 1 + tests/components/climate/test_device_trigger.py | 1 + tests/components/climate/test_reproduce_state.py | 1 + tests/components/climate/test_significant_change.py | 1 + tests/components/cloud/test_account_link.py | 1 + tests/components/cloud/test_alexa_config.py | 1 + tests/components/cloud/test_assist_pipeline.py | 1 + tests/components/cloud/test_system_health.py | 1 + tests/components/cloudflare/test_config_flow.py | 1 + tests/components/coinbase/test_config_flow.py | 1 + tests/components/color_extractor/conftest.py | 1 + tests/components/color_extractor/test_service.py | 1 + tests/components/compensation/test_sensor.py | 1 + tests/components/config/test_area_registry.py | 1 + tests/components/config/test_auth.py | 1 + tests/components/config/test_device_registry.py | 1 + tests/components/config/test_entity_registry.py | 1 + tests/components/config/test_floor_registry.py | 1 + tests/components/config/test_label_registry.py | 1 + tests/components/counter/test_init.py | 1 + tests/components/counter/test_reproduce_state.py | 1 + tests/components/cover/test_device_action.py | 1 + tests/components/cover/test_device_condition.py | 1 + tests/components/cover/test_reproduce_state.py | 1 + tests/components/cover/test_significant_change.py | 1 + tests/components/deconz/test_config_flow.py | 1 + tests/components/deconz/test_init.py | 1 + tests/components/demo/test_init.py | 1 + tests/components/demo/test_notify.py | 1 + tests/components/demo/test_weather.py | 1 + tests/components/derivative/test_init.py | 1 + tests/components/devialet/test_diagnostics.py | 1 + tests/components/device_tracker/test_device_condition.py | 1 + tests/components/device_tracker/test_device_trigger.py | 1 + tests/components/dialogflow/test_init.py | 1 + tests/components/directv/test_config_flow.py | 1 + tests/components/discord/test_config_flow.py | 1 + tests/components/discord/test_notify.py | 1 + tests/components/discovergy/const.py | 1 + tests/components/discovergy/test_diagnostics.py | 1 + tests/components/discovergy/test_system_health.py | 1 + tests/components/dsmr/conftest.py | 1 + tests/components/dsmr/test_mbus_migration.py | 1 + tests/components/dsmr/test_sensor.py | 1 + tests/components/dte_energy_bridge/test_sensor.py | 1 + tests/components/eafm/test_sensor.py | 1 + tests/components/ecobee/test_climate.py | 1 + tests/components/ecobee/test_util.py | 1 + tests/components/ecovacs/util.py | 1 + tests/components/elgato/test_sensor.py | 1 + tests/components/elmax/conftest.py | 1 + tests/components/emulated_hue/test_hue_api.py | 1 + tests/components/emulated_kasa/test_init.py | 1 + tests/components/energy/test_sensor.py | 1 + tests/components/esphome/test_entity.py | 1 + tests/components/esphome/test_manager.py | 1 + tests/components/evil_genius_labs/conftest.py | 1 + tests/components/evil_genius_labs/test_diagnostics.py | 1 + tests/components/evil_genius_labs/test_init.py | 1 + tests/components/fan/test_device_action.py | 1 + tests/components/fan/test_device_condition.py | 1 + tests/components/fan/test_init.py | 1 + tests/components/fan/test_reproduce_state.py | 1 + tests/components/fan/test_significant_change.py | 1 + tests/components/fido/test_sensor.py | 1 + tests/components/file/test_notify.py | 1 + tests/components/filesize/test_sensor.py | 1 + tests/components/flexit_bacnet/test_config_flow.py | 1 + tests/components/flo/test_services.py | 1 + tests/components/folder/test_sensor.py | 1 + tests/components/folder_watcher/test_init.py | 1 + tests/components/freebox/conftest.py | 1 + tests/components/freebox/test_router.py | 1 + tests/components/freedns/test_init.py | 1 + tests/components/freedompro/test_init.py | 1 + tests/components/fritz/conftest.py | 1 + tests/components/fritz/test_config_flow.py | 1 + tests/components/fritzbox/test_config_flow.py | 1 + tests/components/fully_kiosk/test_init.py | 1 + tests/components/gdacs/conftest.py | 1 + tests/components/gdacs/test_geo_location.py | 1 + tests/components/generic/test_camera.py | 1 + tests/components/generic/test_config_flow.py | 1 + tests/components/generic/test_diagnostics.py | 1 + tests/components/generic_hygrostat/test_humidifier.py | 1 + tests/components/generic_thermostat/test_climate.py | 1 + tests/components/geo_location/test_init.py | 1 + tests/components/geo_location/test_trigger.py | 1 + tests/components/geonetnz_quakes/conftest.py | 1 + tests/components/geonetnz_quakes/test_geo_location.py | 1 + tests/components/geonetnz_quakes/test_sensor.py | 1 + tests/components/geonetnz_volcano/conftest.py | 1 + tests/components/gios/test_config_flow.py | 1 + tests/components/gios/test_init.py | 1 + tests/components/gios/test_system_health.py | 1 + tests/components/github/test_init.py | 1 + tests/components/github/test_sensor.py | 1 + tests/components/google_assistant/test_data_redaction.py | 1 + tests/components/google_assistant/test_smart_home.py | 1 + tests/components/google_mail/test_init.py | 1 + tests/components/google_travel_time/test_config_flow.py | 1 + tests/components/graphite/test_init.py | 1 + tests/components/gree/common.py | 1 + tests/components/group/conftest.py | 1 + tests/components/group/test_cover.py | 1 + tests/components/group/test_fan.py | 1 + tests/components/group/test_light.py | 1 + tests/components/group/test_media_player.py | 1 + tests/components/group/test_switch.py | 1 + tests/components/harmony/test_subscriber.py | 1 + tests/components/hassio/conftest.py | 1 + tests/components/hassio/test_binary_sensor.py | 1 + tests/components/hassio/test_system_health.py | 1 + tests/components/hassio/test_websocket_api.py | 1 + tests/components/hddtemp/test_sensor.py | 1 + tests/components/heos/test_init.py | 1 + tests/components/heos/test_media_player.py | 1 + tests/components/here_travel_time/conftest.py | 1 + tests/components/history/conftest.py | 1 + tests/components/history/test_websocket_api.py | 1 + tests/components/hko/conftest.py | 1 + tests/components/hlk_sw16/test_config_flow.py | 1 + tests/components/homeassistant/test_exposed_entities.py | 1 + tests/components/homeassistant/test_init.py | 1 + tests/components/homeassistant/triggers/test_event.py | 1 + tests/components/homekit/test_aidmanager.py | 1 + tests/components/homekit/test_type_cameras.py | 1 + tests/components/homekit/test_type_locks.py | 1 + tests/components/homekit/test_type_media_players.py | 1 + tests/components/homekit_controller/conftest.py | 1 + tests/components/homekit_controller/test_camera.py | 1 + tests/components/homekit_controller/test_config_flow.py | 1 + tests/components/homematic/test_notify.py | 1 + tests/components/homematicip_cloud/helper.py | 1 + tests/components/homematicip_cloud/test_climate.py | 1 + tests/components/honeywell/test_climate.py | 1 + tests/components/http/conftest.py | 1 + tests/components/http/test_init.py | 1 + tests/components/http/test_security_filter.py | 1 + tests/components/hue/conftest.py | 1 + tests/components/hue/test_bridge.py | 1 + tests/components/humidifier/test_device_action.py | 1 + tests/components/humidifier/test_device_condition.py | 1 + tests/components/humidifier/test_device_trigger.py | 1 + tests/components/humidifier/test_intent.py | 1 + tests/components/humidifier/test_reproduce_state.py | 1 + tests/components/humidifier/test_significant_change.py | 1 + tests/components/hvv_departures/test_config_flow.py | 1 + tests/components/iaqualink/conftest.py | 1 + tests/components/iaqualink/test_init.py | 1 + tests/components/ibeacon/test_init.py | 1 + tests/components/ign_sismologia/test_geo_location.py | 1 + tests/components/image/test_init.py | 1 + tests/components/image_upload/test_init.py | 1 + tests/components/imap/test_config_flow.py | 1 + tests/components/imap/test_init.py | 1 + tests/components/input_boolean/test_init.py | 1 + tests/components/input_button/test_init.py | 1 + tests/components/input_datetime/test_init.py | 1 + tests/components/input_datetime/test_reproduce_state.py | 1 + tests/components/input_number/test_reproduce_state.py | 1 + tests/components/input_select/test_reproduce_state.py | 1 + tests/components/input_text/test_reproduce_state.py | 1 + tests/components/insteon/test_api_aldb.py | 1 + tests/components/insteon/test_api_device.py | 1 + tests/components/insteon/test_api_properties.py | 1 + tests/components/insteon/test_api_scenes.py | 1 + tests/components/insteon/test_init.py | 1 + tests/components/integration/test_init.py | 1 + tests/components/iotawatt/test_init.py | 1 + tests/components/ipma/test_system_health.py | 1 + tests/components/ipma/test_weather.py | 1 + tests/components/ipp/test_config_flow.py | 1 + tests/components/iqvia/conftest.py | 1 + tests/components/isy994/test_config_flow.py | 1 + tests/components/isy994/test_system_health.py | 1 + tests/components/kira/test_init.py | 1 + tests/components/kitchen_sink/test_init.py | 1 + tests/components/knx/test_device_trigger.py | 1 + tests/components/knx/test_events.py | 1 + tests/components/knx/test_number.py | 1 + tests/components/knx/test_select.py | 1 + tests/components/kodi/test_device_trigger.py | 1 + tests/components/kraken/const.py | 1 + tests/components/lametric/test_sensor.py | 1 + tests/components/landisgyr_heat_meter/test_sensor.py | 1 + tests/components/laundrify/conftest.py | 1 + tests/components/lcn/conftest.py | 1 + tests/components/light/test_device_action.py | 1 + tests/components/light/test_reproduce_state.py | 1 + tests/components/lock/test_device_action.py | 1 + tests/components/lock/test_device_condition.py | 1 + tests/components/lock/test_reproduce_state.py | 1 + tests/components/logbook/test_init.py | 1 + tests/components/logbook/test_websocket_api.py | 1 + tests/components/logger/conftest.py | 1 + tests/components/logger/test_websocket_api.py | 1 + tests/components/logi_circle/test_config_flow.py | 1 + tests/components/lovelace/test_resources.py | 1 + tests/components/mailgun/test_init.py | 1 + tests/components/media_extractor/test_init.py | 1 + tests/components/media_player/test_async_helpers.py | 1 + tests/components/media_player/test_device_condition.py | 1 + tests/components/media_player/test_reproduce_state.py | 1 + tests/components/media_player/test_significant_change.py | 1 + tests/components/melissa/test_climate.py | 1 + tests/components/met/test_init.py | 1 + tests/components/met_eireann/test_weather.py | 1 + tests/components/metoffice/test_config_flow.py | 1 + tests/components/metoffice/test_sensor.py | 1 + tests/components/metoffice/test_weather.py | 1 + tests/components/mfi/test_switch.py | 1 + tests/components/microbees/conftest.py | 1 + tests/components/min_max/test_init.py | 1 + tests/components/min_max/test_sensor.py | 1 + tests/components/minecraft_server/conftest.py | 1 + tests/components/minio/test_minio.py | 1 + tests/components/mochad/test_light.py | 1 + tests/components/mochad/test_switch.py | 1 + tests/components/modbus/conftest.py | 1 + tests/components/modbus/test_binary_sensor.py | 1 + tests/components/modbus/test_climate.py | 1 + tests/components/modbus/test_sensor.py | 1 + tests/components/mold_indicator/test_sensor.py | 1 + tests/components/motion_blinds/test_config_flow.py | 1 + tests/components/motioneye/test_camera.py | 1 + tests/components/motioneye/test_media_source.py | 1 + tests/components/motioneye/test_sensor.py | 1 + tests/components/motioneye/test_switch.py | 1 + tests/components/motioneye/test_web_hooks.py | 1 + tests/components/motionmount/test_config_flow.py | 1 + tests/components/mqtt/test_alarm_control_panel.py | 1 + tests/components/mqtt/test_binary_sensor.py | 1 + tests/components/mqtt/test_button.py | 1 + tests/components/mqtt/test_climate.py | 1 + tests/components/mqtt/test_device_trigger.py | 1 + tests/components/mqtt/test_diagnostics.py | 1 + tests/components/mqtt/test_discovery.py | 1 + tests/components/mqtt/test_event.py | 1 + tests/components/mqtt/test_fan.py | 1 + tests/components/mqtt/test_humidifier.py | 1 + tests/components/mqtt/test_init.py | 1 + tests/components/mqtt/test_lawn_mower.py | 1 + tests/components/mqtt/test_light.py | 1 + tests/components/mqtt/test_light_json.py | 1 + tests/components/mqtt/test_light_template.py | 1 + tests/components/mqtt/test_number.py | 1 + tests/components/mqtt/test_scene.py | 1 + tests/components/mqtt/test_sensor.py | 1 + tests/components/mqtt/test_siren.py | 1 + tests/components/mqtt/test_switch.py | 1 + tests/components/mqtt/test_update.py | 1 + tests/components/mqtt/test_water_heater.py | 1 + tests/components/mqtt_eventstream/test_init.py | 1 + tests/components/mqtt_room/test_sensor.py | 1 + tests/components/mythicbeastsdns/test_init.py | 1 + tests/components/myuplink/test_init.py | 1 + tests/components/nam/test_diagnostics.py | 1 + tests/components/nest/test_api.py | 1 + tests/components/nest/test_camera.py | 1 + tests/components/nest/test_init.py | 1 + tests/components/netatmo/test_device_trigger.py | 1 + tests/components/netatmo/test_media_source.py | 1 + tests/components/nexia/test_init.py | 1 + tests/components/nextdns/test_system_health.py | 1 + tests/components/nibe_heatpump/test_coordinator.py | 1 + tests/components/notify/test_init.py | 1 + .../components/nsw_rural_fire_service_feed/test_geo_location.py | 1 + tests/components/number/test_device_action.py | 1 + tests/components/number/test_reproduce_state.py | 1 + tests/components/number/test_significant_change.py | 1 + tests/components/nws/test_sensor.py | 1 + tests/components/onboarding/test_views.py | 1 + tests/components/onvif/test_config_flow.py | 1 + tests/components/openexchangerates/test_config_flow.py | 1 + tests/components/openhardwaremonitor/test_sensor.py | 1 + tests/components/opower/conftest.py | 1 + tests/components/otbr/test_config_flow.py | 1 + tests/components/otbr/test_init.py | 1 + tests/components/owntracks/test_device_tracker.py | 1 + tests/components/owntracks/test_init.py | 1 + tests/components/p1_monitor/conftest.py | 1 + tests/components/panel_iframe/test_init.py | 1 + tests/components/person/conftest.py | 1 + tests/components/philips_js/test_binary_sensor.py | 1 + tests/components/philips_js/test_device_trigger.py | 1 + tests/components/pi_hole/test_init.py | 1 + tests/components/picnic/test_sensor.py | 1 + tests/components/pilight/test_sensor.py | 1 + tests/components/plex/test_config_flow.py | 1 + tests/components/plex/test_device_handling.py | 1 + tests/components/plex/test_init.py | 1 + tests/components/plex/test_server.py | 1 + tests/components/plex/test_update.py | 1 + tests/components/prosegur/test_camera.py | 1 + tests/components/proximity/conftest.py | 1 + tests/components/python_script/test_init.py | 1 + tests/components/qbittorrent/test_config_flow.py | 1 + tests/components/qld_bushfire/test_geo_location.py | 1 + tests/components/qwikswitch/test_init.py | 1 + tests/components/radarr/test_binary_sensor.py | 1 + tests/components/radarr/test_init.py | 1 + tests/components/radarr/test_sensor.py | 1 + tests/components/rainforest_raven/test_init.py | 1 + tests/components/rainforest_raven/test_sensor.py | 1 + tests/components/rainmachine/conftest.py | 1 + tests/components/recorder/test_filters_with_entityfilter.py | 1 + .../recorder/test_filters_with_entityfilter_schema_37.py | 1 + tests/components/recorder/test_migration_from_schema_32.py | 1 + tests/components/recorder/test_pool.py | 1 + tests/components/recorder/test_websocket_api.py | 1 + tests/components/reddit/test_sensor.py | 1 + tests/components/remote/test_device_action.py | 1 + tests/components/remote/test_init.py | 1 + tests/components/remote/test_reproduce_state.py | 1 + tests/components/renault/test_diagnostics.py | 1 + tests/components/rest_command/test_init.py | 1 + tests/components/rfxtrx/test_binary_sensor.py | 1 + tests/components/rfxtrx/test_config_flow.py | 1 + tests/components/rfxtrx/test_sensor.py | 1 + tests/components/ring/test_light.py | 1 + tests/components/ring/test_sensor.py | 1 + tests/components/ring/test_siren.py | 1 + tests/components/ring/test_switch.py | 1 + tests/components/risco/test_init.py | 1 + tests/components/rituals_perfume_genie/test_select.py | 1 + tests/components/rmvtransport/test_sensor.py | 1 + tests/components/roborock/test_image.py | 1 + tests/components/roku/test_config_flow.py | 1 + tests/components/samsungtv/test_device_trigger.py | 1 + tests/components/scene/test_init.py | 1 + tests/components/screenlogic/conftest.py | 1 + tests/components/script/test_blueprint.py | 1 + tests/components/script/test_init.py | 1 + tests/components/search/test_init.py | 1 + tests/components/select/test_device_action.py | 1 + tests/components/select/test_reproduce_state.py | 1 + tests/components/sensor/test_device_condition.py | 1 + tests/components/sensor/test_helpers.py | 1 + tests/components/sensor/test_significant_change.py | 1 + tests/components/sentry/test_config_flow.py | 1 + tests/components/sentry/test_init.py | 1 + tests/components/sfr_box/test_config_flow.py | 1 + tests/components/signal_messenger/test_notify.py | 1 + tests/components/simplisafe/conftest.py | 1 + tests/components/simplisafe/test_config_flow.py | 1 + tests/components/smartthings/conftest.py | 1 + tests/components/smarttub/test_climate.py | 1 + tests/components/smarttub/test_light.py | 1 + tests/components/smarttub/test_sensor.py | 1 + tests/components/smarttub/test_switch.py | 1 + tests/components/smhi/conftest.py | 1 + tests/components/snips/test_init.py | 1 + tests/components/songpal/test_config_flow.py | 1 + tests/components/sonos/test_init.py | 1 + tests/components/sonos/test_plex_playback.py | 1 + tests/components/soundtouch/conftest.py | 1 + tests/components/srp_energy/test_sensor.py | 1 + tests/components/starline/test_config_flow.py | 1 + tests/components/starlink/patchers.py | 1 + tests/components/steam_online/test_init.py | 1 + tests/components/stream/test_init.py | 1 + tests/components/stream/test_ll_hls.py | 1 + tests/components/stream/test_recorder.py | 1 + tests/components/stream/test_worker.py | 1 + tests/components/subaru/test_diagnostics.py | 1 + tests/components/surepetcare/test_lock.py | 1 + tests/components/switch/test_device_action.py | 1 + tests/components/switch/test_init.py | 1 + tests/components/switch/test_light.py | 1 + tests/components/switch/test_reproduce_state.py | 1 + tests/components/switchbee/test_config_flow.py | 1 + tests/components/switcher_kis/test_sensor.py | 1 + tests/components/syncthru/test_config_flow.py | 1 + tests/components/tado/test_service.py | 1 + tests/components/tag/test_trigger.py | 1 + tests/components/tami4/test_init.py | 1 + tests/components/tasmota/test_binary_sensor.py | 1 + tests/components/tasmota/test_common.py | 1 + tests/components/tasmota/test_cover.py | 1 + tests/components/tasmota/test_device_trigger.py | 1 + tests/components/tasmota/test_discovery.py | 1 + tests/components/tasmota/test_fan.py | 1 + tests/components/tasmota/test_init.py | 1 + tests/components/tasmota/test_light.py | 1 + tests/components/tasmota/test_mixins.py | 1 + tests/components/tasmota/test_sensor.py | 1 + tests/components/tasmota/test_switch.py | 1 + tests/components/template/conftest.py | 1 + tests/components/template/test_alarm_control_panel.py | 1 + tests/components/template/test_button.py | 1 + tests/components/template/test_fan.py | 1 + tests/components/template/test_light.py | 1 + tests/components/template/test_lock.py | 1 + tests/components/template/test_switch.py | 1 + tests/components/template/test_template_entity.py | 1 + tests/components/template/test_vacuum.py | 1 + tests/components/tessie/test_binary_sensors.py | 1 + tests/components/text/test_device_action.py | 1 + tests/components/text/test_reproduce_state.py | 1 + tests/components/thread/test_dataset_store.py | 1 + tests/components/threshold/test_init.py | 1 + tests/components/tibber/conftest.py | 1 + tests/components/tibber/test_common.py | 1 + tests/components/tile/conftest.py | 1 + tests/components/timer/test_reproduce_state.py | 1 + tests/components/tomorrowio/conftest.py | 1 + tests/components/tplink/test_diagnostics.py | 1 + tests/components/trace/test_websocket_api.py | 1 + tests/components/tradfri/test_util.py | 1 + tests/components/tts/test_init.py | 1 + tests/components/twentemilieu/test_sensor.py | 1 + tests/components/twitch/test_init.py | 1 + tests/components/uk_transport/test_sensor.py | 1 + tests/components/unifi/test_config_flow.py | 1 + tests/components/uptime/test_sensor.py | 1 + tests/components/uptimerobot/test_diagnostics.py | 1 + tests/components/usb/test_init.py | 1 + tests/components/usgs_earthquakes_feed/test_geo_location.py | 1 + tests/components/vacuum/test_device_action.py | 1 + tests/components/vacuum/test_device_condition.py | 1 + tests/components/vacuum/test_reproduce_state.py | 1 + tests/components/vacuum/test_significant_change.py | 1 + tests/components/vallox/test_number.py | 1 + tests/components/venstar/test_config_flow.py | 1 + tests/components/vesync/common.py | 1 + tests/components/vesync/test_fan.py | 1 + tests/components/vesync/test_light.py | 1 + tests/components/vesync/test_sensor.py | 1 + tests/components/vesync/test_switch.py | 1 + tests/components/vizio/test_config_flow.py | 1 + tests/components/voip/test_sip.py | 1 + tests/components/voip/test_voip.py | 1 + tests/components/vulcan/test_config_flow.py | 1 + tests/components/vultr/conftest.py | 1 + tests/components/vultr/test_binary_sensor.py | 1 + tests/components/vultr/test_sensor.py | 1 + tests/components/wallbox/conftest.py | 1 + tests/components/wallbox/test_init.py | 1 + tests/components/wallbox/test_lock.py | 1 + tests/components/wallbox/test_number.py | 1 + tests/components/wallbox/test_switch.py | 1 + tests/components/waqi/test_config_flow.py | 1 + tests/components/waqi/test_sensor.py | 1 + tests/components/water_heater/test_device_action.py | 1 + tests/components/water_heater/test_reproduce_state.py | 1 + tests/components/water_heater/test_significant_change.py | 1 + tests/components/watttime/conftest.py | 1 + tests/components/waze_travel_time/test_config_flow.py | 1 + tests/components/waze_travel_time/test_sensor.py | 1 + tests/components/weatherflow/conftest.py | 1 + tests/components/weatherflow_cloud/test_config_flow.py | 1 + tests/components/webmin/test_sensor.py | 1 + tests/components/webostv/test_config_flow.py | 1 + tests/components/webostv/test_device_trigger.py | 1 + tests/components/websocket_api/conftest.py | 1 + tests/components/websocket_api/test_commands.py | 1 + tests/components/websocket_api/test_connection.py | 1 + tests/components/websocket_api/test_http.py | 1 + tests/components/websocket_api/test_messages.py | 1 + tests/components/wemo/conftest.py | 1 + tests/components/wemo/entity_test_helpers.py | 1 + tests/components/wemo/test_device_trigger.py | 1 + tests/components/wemo/test_fan.py | 1 + tests/components/wemo/test_init.py | 1 + tests/components/wemo/test_light_dimmer.py | 1 + tests/components/wemo/test_switch.py | 1 + tests/components/wemo/test_wemo_device.py | 1 + tests/components/wiffi/test_config_flow.py | 1 + tests/components/wilight/test_config_flow.py | 1 + tests/components/wiz/test_init.py | 1 + tests/components/wled/test_binary_sensor.py | 1 + tests/components/wled/test_coordinator.py | 1 + tests/components/wled/test_init.py | 1 + tests/components/wled/test_light.py | 1 + tests/components/wled/test_number.py | 1 + tests/components/wled/test_select.py | 1 + tests/components/wled/test_switch.py | 1 + tests/components/worldclock/test_sensor.py | 1 + tests/components/xiaomi_ble/test_device_trigger.py | 1 + tests/components/xiaomi_ble/test_event.py | 1 + tests/components/yalexs_ble/test_config_flow.py | 1 + .../components/yandex_transport/test_yandex_transport_sensor.py | 1 + tests/components/yeelight/conftest.py | 1 + tests/components/yolink/test_device_trigger.py | 1 + tests/components/youtube/test_init.py | 1 + tests/components/zha/common.py | 1 + tests/components/zha/test_config_flow.py | 1 + tests/components/zha/test_cover.py | 1 + tests/components/zha/test_gateway.py | 1 + tests/components/zha/test_helpers.py | 1 + tests/components/zha/test_init.py | 1 + tests/components/zone/test_trigger.py | 1 + tests/components/zwave_js/conftest.py | 1 + .../scripts/test_convert_device_diagnostics_to_fixture.py | 1 + tests/components/zwave_js/test_button.py | 1 + tests/components/zwave_js/test_climate.py | 1 + tests/components/zwave_js/test_config_flow.py | 1 + tests/components/zwave_js/test_config_validation.py | 1 + tests/components/zwave_js/test_cover.py | 1 + tests/components/zwave_js/test_diagnostics.py | 1 + tests/components/zwave_js/test_discovery.py | 1 + tests/components/zwave_js/test_fan.py | 1 + tests/components/zwave_js/test_helpers.py | 1 + tests/components/zwave_js/test_init.py | 1 + tests/components/zwave_js/test_lock.py | 1 + tests/components/zwave_js/test_migrate.py | 1 + tests/components/zwave_js/test_sensor.py | 1 + tests/components/zwave_js/test_switch.py | 1 + tests/components/zwave_js/test_update.py | 1 + 569 files changed, 569 insertions(+) diff --git a/tests/components/accuweather/test_system_health.py b/tests/components/accuweather/test_system_health.py index 34f5b761ccb..6321071eaa5 100644 --- a/tests/components/accuweather/test_system_health.py +++ b/tests/components/accuweather/test_system_health.py @@ -1,4 +1,5 @@ """Test AccuWeather system health.""" + import asyncio from unittest.mock import Mock diff --git a/tests/components/adguard/test_config_flow.py b/tests/components/adguard/test_config_flow.py index f62172ebfad..3f12dd1508a 100644 --- a/tests/components/adguard/test_config_flow.py +++ b/tests/components/adguard/test_config_flow.py @@ -1,4 +1,5 @@ """Tests for the AdGuard Home config flow.""" + import aiohttp from homeassistant import config_entries, data_entry_flow diff --git a/tests/components/aemet/test_weather.py b/tests/components/aemet/test_weather.py index 595275427f4..88427a5a38f 100644 --- a/tests/components/aemet/test_weather.py +++ b/tests/components/aemet/test_weather.py @@ -1,4 +1,5 @@ """The sensor tests for the AEMET OpenData platform.""" + import datetime from unittest.mock import patch diff --git a/tests/components/agent_dvr/test_config_flow.py b/tests/components/agent_dvr/test_config_flow.py index 9d1be278ada..958ec97a3ca 100644 --- a/tests/components/agent_dvr/test_config_flow.py +++ b/tests/components/agent_dvr/test_config_flow.py @@ -1,4 +1,5 @@ """Tests for the Agent DVR config flow.""" + import pytest from homeassistant import data_entry_flow diff --git a/tests/components/air_quality/test_air_quality.py b/tests/components/air_quality/test_air_quality.py index faaebda0aae..7bc21dee03c 100644 --- a/tests/components/air_quality/test_air_quality.py +++ b/tests/components/air_quality/test_air_quality.py @@ -1,4 +1,5 @@ """The tests for the Air Quality component.""" + import pytest from homeassistant.components.air_quality import ATTR_N2O, ATTR_OZONE, ATTR_PM_10 diff --git a/tests/components/airly/test_system_health.py b/tests/components/airly/test_system_health.py index fa26f6ccd0c..4ae94ca280c 100644 --- a/tests/components/airly/test_system_health.py +++ b/tests/components/airly/test_system_health.py @@ -1,4 +1,5 @@ """Test Airly system health.""" + import asyncio from unittest.mock import Mock diff --git a/tests/components/airnow/conftest.py b/tests/components/airnow/conftest.py index 0356c6f3395..a374168df6a 100644 --- a/tests/components/airnow/conftest.py +++ b/tests/components/airnow/conftest.py @@ -1,4 +1,5 @@ """Define fixtures for AirNow tests.""" + import json from unittest.mock import AsyncMock, patch diff --git a/tests/components/airthings_ble/test_sensor.py b/tests/components/airthings_ble/test_sensor.py index 1bf036b735d..eee4de263d6 100644 --- a/tests/components/airthings_ble/test_sensor.py +++ b/tests/components/airthings_ble/test_sensor.py @@ -1,4 +1,5 @@ """Test the Airthings Wave sensor.""" + import logging from homeassistant.components.airthings_ble.const import DOMAIN diff --git a/tests/components/airzone/test_climate.py b/tests/components/airzone/test_climate.py index f33d1a8b28a..07d7f3127fa 100644 --- a/tests/components/airzone/test_climate.py +++ b/tests/components/airzone/test_climate.py @@ -1,4 +1,5 @@ """The climate tests for the Airzone platform.""" + import copy from unittest.mock import patch diff --git a/tests/components/alarm_control_panel/test_device_action.py b/tests/components/alarm_control_panel/test_device_action.py index 08ccef37336..ff999a0a273 100644 --- a/tests/components/alarm_control_panel/test_device_action.py +++ b/tests/components/alarm_control_panel/test_device_action.py @@ -1,4 +1,5 @@ """The tests for Alarm control panel device actions.""" + import pytest from pytest_unordered import unordered diff --git a/tests/components/alarm_control_panel/test_device_condition.py b/tests/components/alarm_control_panel/test_device_condition.py index 6e85c94379f..72ea9530fbd 100644 --- a/tests/components/alarm_control_panel/test_device_condition.py +++ b/tests/components/alarm_control_panel/test_device_condition.py @@ -1,4 +1,5 @@ """The tests for Alarm control panel device conditions.""" + import pytest from pytest_unordered import unordered diff --git a/tests/components/alarm_control_panel/test_reproduce_state.py b/tests/components/alarm_control_panel/test_reproduce_state.py index 61bb8f18397..c7984b0793e 100644 --- a/tests/components/alarm_control_panel/test_reproduce_state.py +++ b/tests/components/alarm_control_panel/test_reproduce_state.py @@ -1,4 +1,5 @@ """Test reproduce state for Alarm control panel.""" + import pytest from homeassistant.const import ( diff --git a/tests/components/alarm_control_panel/test_significant_change.py b/tests/components/alarm_control_panel/test_significant_change.py index d65a1d5cb00..e614467098a 100644 --- a/tests/components/alarm_control_panel/test_significant_change.py +++ b/tests/components/alarm_control_panel/test_significant_change.py @@ -1,4 +1,5 @@ """Test the Alarm Control Panel significant change platform.""" + import pytest from homeassistant.components.alarm_control_panel import ( diff --git a/tests/components/alert/test_reproduce_state.py b/tests/components/alert/test_reproduce_state.py index bca2a22ce7e..e0f817443dc 100644 --- a/tests/components/alert/test_reproduce_state.py +++ b/tests/components/alert/test_reproduce_state.py @@ -1,4 +1,5 @@ """Test reproduce state for Alert.""" + import pytest from homeassistant.core import HomeAssistant, State diff --git a/tests/components/alexa/test_config.py b/tests/components/alexa/test_config.py index 9536e3d471b..62330c8059c 100644 --- a/tests/components/alexa/test_config.py +++ b/tests/components/alexa/test_config.py @@ -1,4 +1,5 @@ """Test config.""" + import asyncio from unittest.mock import patch diff --git a/tests/components/alexa/test_state_report.py b/tests/components/alexa/test_state_report.py index 08d198145df..c851b7991ac 100644 --- a/tests/components/alexa/test_state_report.py +++ b/tests/components/alexa/test_state_report.py @@ -1,4 +1,5 @@ """Test report state.""" + import json from unittest.mock import AsyncMock, patch diff --git a/tests/components/ambient_station/conftest.py b/tests/components/ambient_station/conftest.py index ab5eb6239c8..25b11740db6 100644 --- a/tests/components/ambient_station/conftest.py +++ b/tests/components/ambient_station/conftest.py @@ -1,4 +1,5 @@ """Define test fixtures for Ambient PWS.""" + import json from unittest.mock import AsyncMock, Mock, patch diff --git a/tests/components/apcupsd/test_init.py b/tests/components/apcupsd/test_init.py index c65efe25bb9..e6db0adc4c7 100644 --- a/tests/components/apcupsd/test_init.py +++ b/tests/components/apcupsd/test_init.py @@ -1,4 +1,5 @@ """Test init of APCUPSd integration.""" + import asyncio from collections import OrderedDict from unittest.mock import patch diff --git a/tests/components/api/test_init.py b/tests/components/api/test_init.py index 49da0078229..0ac2e5973fe 100644 --- a/tests/components/api/test_init.py +++ b/tests/components/api/test_init.py @@ -1,4 +1,5 @@ """The tests for the Home Assistant API component.""" + import asyncio from http import HTTPStatus import json diff --git a/tests/components/arcam_fmj/test_device_trigger.py b/tests/components/arcam_fmj/test_device_trigger.py index d073e9c75da..a8510628b26 100644 --- a/tests/components/arcam_fmj/test_device_trigger.py +++ b/tests/components/arcam_fmj/test_device_trigger.py @@ -1,4 +1,5 @@ """The tests for Arcam FMJ Receiver control device triggers.""" + import pytest from homeassistant.components.arcam_fmj.const import DOMAIN diff --git a/tests/components/assist_pipeline/test_init.py b/tests/components/assist_pipeline/test_init.py index 882d3a80fb3..81347e96235 100644 --- a/tests/components/assist_pipeline/test_init.py +++ b/tests/components/assist_pipeline/test_init.py @@ -1,4 +1,5 @@ """Test Voice Assistant init.""" + import asyncio from dataclasses import asdict import itertools as it diff --git a/tests/components/assist_pipeline/test_vad.py b/tests/components/assist_pipeline/test_vad.py index 57b567c49df..139ae915263 100644 --- a/tests/components/assist_pipeline/test_vad.py +++ b/tests/components/assist_pipeline/test_vad.py @@ -1,4 +1,5 @@ """Tests for voice command segmenter.""" + import itertools as it from unittest.mock import patch diff --git a/tests/components/assist_pipeline/test_websocket.py b/tests/components/assist_pipeline/test_websocket.py index 9138819de12..91f07fc08c0 100644 --- a/tests/components/assist_pipeline/test_websocket.py +++ b/tests/components/assist_pipeline/test_websocket.py @@ -1,4 +1,5 @@ """Websocket tests for Voice Assistant integration.""" + import asyncio import base64 from typing import Any diff --git a/tests/components/atag/conftest.py b/tests/components/atag/conftest.py index a1270696540..567b835d8b4 100644 --- a/tests/components/atag/conftest.py +++ b/tests/components/atag/conftest.py @@ -1,4 +1,5 @@ """Provide common Atag fixtures.""" + import asyncio from collections.abc import Generator from unittest.mock import AsyncMock, patch diff --git a/tests/components/august/test_binary_sensor.py b/tests/components/august/test_binary_sensor.py index 72352477b4a..377a5bf2897 100644 --- a/tests/components/august/test_binary_sensor.py +++ b/tests/components/august/test_binary_sensor.py @@ -1,4 +1,5 @@ """The binary_sensor tests for the august platform.""" + import datetime import time from unittest.mock import Mock, patch diff --git a/tests/components/august/test_lock.py b/tests/components/august/test_lock.py index bc2cd23b23d..39c1745d967 100644 --- a/tests/components/august/test_lock.py +++ b/tests/components/august/test_lock.py @@ -1,4 +1,5 @@ """The lock tests for the august platform.""" + import datetime from unittest.mock import Mock diff --git a/tests/components/auth/conftest.py b/tests/components/auth/conftest.py index b7e69a44a0d..a17661f5635 100644 --- a/tests/components/auth/conftest.py +++ b/tests/components/auth/conftest.py @@ -1,4 +1,5 @@ """Test configuration for auth.""" + import pytest diff --git a/tests/components/auth/test_indieauth.py b/tests/components/auth/test_indieauth.py index 612d97808a7..2a8d6894dc6 100644 --- a/tests/components/auth/test_indieauth.py +++ b/tests/components/auth/test_indieauth.py @@ -1,4 +1,5 @@ """Tests for the client validator.""" + import asyncio from unittest.mock import patch diff --git a/tests/components/automation/test_blueprint.py b/tests/components/automation/test_blueprint.py index 5df33f9b4b8..24d77800508 100644 --- a/tests/components/automation/test_blueprint.py +++ b/tests/components/automation/test_blueprint.py @@ -1,4 +1,5 @@ """Test built-in blueprints.""" + import asyncio import contextlib from datetime import timedelta diff --git a/tests/components/automation/test_init.py b/tests/components/automation/test_init.py index e613a997939..e099c25f58f 100644 --- a/tests/components/automation/test_init.py +++ b/tests/components/automation/test_init.py @@ -1,4 +1,5 @@ """The tests for the automation component.""" + import asyncio from datetime import timedelta import logging diff --git a/tests/components/automation/test_reproduce_state.py b/tests/components/automation/test_reproduce_state.py index 88ed26b564c..2b987572ae4 100644 --- a/tests/components/automation/test_reproduce_state.py +++ b/tests/components/automation/test_reproduce_state.py @@ -1,4 +1,5 @@ """Test reproduce state for Automation.""" + import pytest from homeassistant.core import HomeAssistant, State diff --git a/tests/components/aws/test_init.py b/tests/components/aws/test_init.py index 2a69f02e35d..9cf8966483b 100644 --- a/tests/components/aws/test_init.py +++ b/tests/components/aws/test_init.py @@ -1,4 +1,5 @@ """Tests for the aws component config and setup.""" + import json from unittest.mock import AsyncMock, MagicMock, call, patch as async_patch diff --git a/tests/components/axis/test_binary_sensor.py b/tests/components/axis/test_binary_sensor.py index d928d3beaa9..64e567889f1 100644 --- a/tests/components/axis/test_binary_sensor.py +++ b/tests/components/axis/test_binary_sensor.py @@ -1,4 +1,5 @@ """Axis binary sensor platform tests.""" + import pytest from homeassistant.components.axis.const import DOMAIN as AXIS_DOMAIN diff --git a/tests/components/axis/test_diagnostics.py b/tests/components/axis/test_diagnostics.py index af11fdc388a..026e1ae4d22 100644 --- a/tests/components/axis/test_diagnostics.py +++ b/tests/components/axis/test_diagnostics.py @@ -1,4 +1,5 @@ """Test Axis diagnostics.""" + import pytest from syrupy import SnapshotAssertion diff --git a/tests/components/azure_event_hub/test_config_flow.py b/tests/components/azure_event_hub/test_config_flow.py index 8cebbe6fbd4..38454e46dd1 100644 --- a/tests/components/azure_event_hub/test_config_flow.py +++ b/tests/components/azure_event_hub/test_config_flow.py @@ -1,4 +1,5 @@ """Test the AEH config flow.""" + import logging from unittest.mock import AsyncMock diff --git a/tests/components/bayesian/test_binary_sensor.py b/tests/components/bayesian/test_binary_sensor.py index dba0769bc82..2c94da10ce8 100644 --- a/tests/components/bayesian/test_binary_sensor.py +++ b/tests/components/bayesian/test_binary_sensor.py @@ -1,4 +1,5 @@ """The test for the bayesian sensor platform.""" + import json from unittest.mock import patch diff --git a/tests/components/blebox/test_button.py b/tests/components/blebox/test_button.py index cc5ab769853..fe596c41e33 100644 --- a/tests/components/blebox/test_button.py +++ b/tests/components/blebox/test_button.py @@ -1,4 +1,5 @@ """Blebox button entities tests.""" + import logging from unittest.mock import PropertyMock diff --git a/tests/components/blebox/test_climate.py b/tests/components/blebox/test_climate.py index 6ea6d995900..8ba0c3f630e 100644 --- a/tests/components/blebox/test_climate.py +++ b/tests/components/blebox/test_climate.py @@ -1,4 +1,5 @@ """BleBox climate entities tests.""" + import logging from unittest.mock import AsyncMock, PropertyMock diff --git a/tests/components/blebox/test_cover.py b/tests/components/blebox/test_cover.py index 8691c886faa..1596de134c0 100644 --- a/tests/components/blebox/test_cover.py +++ b/tests/components/blebox/test_cover.py @@ -1,4 +1,5 @@ """BleBox cover entities tests.""" + import logging from unittest.mock import AsyncMock, PropertyMock diff --git a/tests/components/blebox/test_init.py b/tests/components/blebox/test_init.py index 00ee62568a5..f406df51bd4 100644 --- a/tests/components/blebox/test_init.py +++ b/tests/components/blebox/test_init.py @@ -1,4 +1,5 @@ """BleBox devices setup tests.""" + import logging import blebox_uniapi diff --git a/tests/components/blebox/test_light.py b/tests/components/blebox/test_light.py index 47f38ba815b..bfa5478265b 100644 --- a/tests/components/blebox/test_light.py +++ b/tests/components/blebox/test_light.py @@ -1,4 +1,5 @@ """BleBox light entities tests.""" + import logging from unittest.mock import AsyncMock, PropertyMock diff --git a/tests/components/blebox/test_sensor.py b/tests/components/blebox/test_sensor.py index 68990a09a32..56c240705b0 100644 --- a/tests/components/blebox/test_sensor.py +++ b/tests/components/blebox/test_sensor.py @@ -1,4 +1,5 @@ """Blebox sensors tests.""" + import logging from unittest.mock import AsyncMock, PropertyMock diff --git a/tests/components/blebox/test_switch.py b/tests/components/blebox/test_switch.py index db98a2705b2..7d1da7ba4c7 100644 --- a/tests/components/blebox/test_switch.py +++ b/tests/components/blebox/test_switch.py @@ -1,4 +1,5 @@ """Blebox switch tests.""" + import logging from unittest.mock import AsyncMock, PropertyMock diff --git a/tests/components/blueprint/test_default_blueprints.py b/tests/components/blueprint/test_default_blueprints.py index 28047e0a41e..9bd60a7cb6b 100644 --- a/tests/components/blueprint/test_default_blueprints.py +++ b/tests/components/blueprint/test_default_blueprints.py @@ -1,4 +1,5 @@ """Test default blueprints.""" + import importlib import logging import pathlib diff --git a/tests/components/blueprint/test_importer.py b/tests/components/blueprint/test_importer.py index d41c8417b57..78a70a57fe2 100644 --- a/tests/components/blueprint/test_importer.py +++ b/tests/components/blueprint/test_importer.py @@ -1,4 +1,5 @@ """Test blueprint importing.""" + import json from pathlib import Path diff --git a/tests/components/blueprint/test_models.py b/tests/components/blueprint/test_models.py index c11a467de9b..2bc6d60ccda 100644 --- a/tests/components/blueprint/test_models.py +++ b/tests/components/blueprint/test_models.py @@ -1,4 +1,5 @@ """Test blueprint models.""" + import logging from unittest.mock import AsyncMock, patch diff --git a/tests/components/blueprint/test_schemas.py b/tests/components/blueprint/test_schemas.py index 4c941b56744..0afe9e780f5 100644 --- a/tests/components/blueprint/test_schemas.py +++ b/tests/components/blueprint/test_schemas.py @@ -1,4 +1,5 @@ """Test schemas.""" + import logging import pytest diff --git a/tests/components/bluetooth/test_api.py b/tests/components/bluetooth/test_api.py index bc65874b0cc..a3ec3814a92 100644 --- a/tests/components/bluetooth/test_api.py +++ b/tests/components/bluetooth/test_api.py @@ -1,4 +1,5 @@ """Tests for the Bluetooth integration API.""" + import time from bleak.backends.scanner import AdvertisementData, BLEDevice diff --git a/tests/components/bluetooth/test_init.py b/tests/components/bluetooth/test_init.py index e2003229213..2130e883af4 100644 --- a/tests/components/bluetooth/test_init.py +++ b/tests/components/bluetooth/test_init.py @@ -1,4 +1,5 @@ """Tests for the Bluetooth integration.""" + import asyncio from datetime import timedelta import time diff --git a/tests/components/bluetooth/test_scanner.py b/tests/components/bluetooth/test_scanner.py index 837c058fa6b..aefc36fe6eb 100644 --- a/tests/components/bluetooth/test_scanner.py +++ b/tests/components/bluetooth/test_scanner.py @@ -1,4 +1,5 @@ """Tests for the Bluetooth integration scanners.""" + import asyncio from datetime import timedelta import time diff --git a/tests/components/bmw_connected_drive/test_diagnostics.py b/tests/components/bmw_connected_drive/test_diagnostics.py index 11c2b055f6d..5b22fdcf71d 100644 --- a/tests/components/bmw_connected_drive/test_diagnostics.py +++ b/tests/components/bmw_connected_drive/test_diagnostics.py @@ -1,4 +1,5 @@ """Test BMW diagnostics.""" + import datetime import os import time diff --git a/tests/components/broadlink/test_config_flow.py b/tests/components/broadlink/test_config_flow.py index 09365b8f5f4..6eb87966082 100644 --- a/tests/components/broadlink/test_config_flow.py +++ b/tests/components/broadlink/test_config_flow.py @@ -1,4 +1,5 @@ """Test the Broadlink config flow.""" + import errno import socket from unittest.mock import call, patch diff --git a/tests/components/broadlink/test_helpers.py b/tests/components/broadlink/test_helpers.py index 937615d7e51..e3ca11a3e2d 100644 --- a/tests/components/broadlink/test_helpers.py +++ b/tests/components/broadlink/test_helpers.py @@ -1,4 +1,5 @@ """Tests for Broadlink helper functions.""" + import pytest import voluptuous as vol diff --git a/tests/components/bthome/test_device_trigger.py b/tests/components/bthome/test_device_trigger.py index 85169e80394..ec45ae25150 100644 --- a/tests/components/bthome/test_device_trigger.py +++ b/tests/components/bthome/test_device_trigger.py @@ -1,4 +1,5 @@ """Test BTHome BLE events.""" + import pytest from homeassistant.components import automation diff --git a/tests/components/buienradar/test_camera.py b/tests/components/buienradar/test_camera.py index f048f8d69a7..799fa37c7e3 100644 --- a/tests/components/buienradar/test_camera.py +++ b/tests/components/buienradar/test_camera.py @@ -1,4 +1,5 @@ """The tests for generic camera component.""" + import asyncio from contextlib import suppress import copy diff --git a/tests/components/button/test_device_action.py b/tests/components/button/test_device_action.py index 3fefa580724..3e05052f978 100644 --- a/tests/components/button/test_device_action.py +++ b/tests/components/button/test_device_action.py @@ -1,4 +1,5 @@ """The tests for Button device actions.""" + import pytest from pytest_unordered import unordered diff --git a/tests/components/cert_expiry/test_config_flow.py b/tests/components/cert_expiry/test_config_flow.py index 1e72e708d44..64afed59d5a 100644 --- a/tests/components/cert_expiry/test_config_flow.py +++ b/tests/components/cert_expiry/test_config_flow.py @@ -1,4 +1,5 @@ """Tests for the Cert Expiry config flow.""" + import socket import ssl from unittest.mock import patch diff --git a/tests/components/clicksend_tts/test_notify.py b/tests/components/clicksend_tts/test_notify.py index ae814aa1332..e73f0576d9e 100644 --- a/tests/components/clicksend_tts/test_notify.py +++ b/tests/components/clicksend_tts/test_notify.py @@ -1,4 +1,5 @@ """The test for the Facebook notify module.""" + import base64 from http import HTTPStatus import logging diff --git a/tests/components/climate/test_device_action.py b/tests/components/climate/test_device_action.py index 1fc379487ed..f15ee3817e7 100644 --- a/tests/components/climate/test_device_action.py +++ b/tests/components/climate/test_device_action.py @@ -1,4 +1,5 @@ """The tests for Climate device actions.""" + import pytest from pytest_unordered import unordered import voluptuous_serialize diff --git a/tests/components/climate/test_device_condition.py b/tests/components/climate/test_device_condition.py index 4dc365e59ee..0d6767c374c 100644 --- a/tests/components/climate/test_device_condition.py +++ b/tests/components/climate/test_device_condition.py @@ -1,4 +1,5 @@ """The tests for Climate device conditions.""" + import pytest from pytest_unordered import unordered import voluptuous_serialize diff --git a/tests/components/climate/test_device_trigger.py b/tests/components/climate/test_device_trigger.py index 59efb66ff65..13426ba02a2 100644 --- a/tests/components/climate/test_device_trigger.py +++ b/tests/components/climate/test_device_trigger.py @@ -1,4 +1,5 @@ """The tests for Climate device triggers.""" + import pytest from pytest_unordered import unordered import voluptuous_serialize diff --git a/tests/components/climate/test_reproduce_state.py b/tests/components/climate/test_reproduce_state.py index b8719fd8fd0..636ab326a2b 100644 --- a/tests/components/climate/test_reproduce_state.py +++ b/tests/components/climate/test_reproduce_state.py @@ -1,4 +1,5 @@ """The tests for reproduction of state.""" + import pytest from homeassistant.components.climate import ( diff --git a/tests/components/climate/test_significant_change.py b/tests/components/climate/test_significant_change.py index 369e5e67004..f060344722a 100644 --- a/tests/components/climate/test_significant_change.py +++ b/tests/components/climate/test_significant_change.py @@ -1,4 +1,5 @@ """Test the Climate significant change platform.""" + import pytest from homeassistant.components.climate import ( diff --git a/tests/components/cloud/test_account_link.py b/tests/components/cloud/test_account_link.py index 14f99fe0fb1..0708c952ca5 100644 --- a/tests/components/cloud/test_account_link.py +++ b/tests/components/cloud/test_account_link.py @@ -1,4 +1,5 @@ """Test account link services.""" + import asyncio import logging from time import time diff --git a/tests/components/cloud/test_alexa_config.py b/tests/components/cloud/test_alexa_config.py index 3ac2417247c..21fe75b9494 100644 --- a/tests/components/cloud/test_alexa_config.py +++ b/tests/components/cloud/test_alexa_config.py @@ -1,4 +1,5 @@ """Test Alexa config.""" + import contextlib from unittest.mock import AsyncMock, Mock, patch diff --git a/tests/components/cloud/test_assist_pipeline.py b/tests/components/cloud/test_assist_pipeline.py index 7f1411dab45..5c2fc074898 100644 --- a/tests/components/cloud/test_assist_pipeline.py +++ b/tests/components/cloud/test_assist_pipeline.py @@ -1,4 +1,5 @@ """Test the cloud assist pipeline.""" + import pytest from homeassistant.components.cloud.assist_pipeline import ( diff --git a/tests/components/cloud/test_system_health.py b/tests/components/cloud/test_system_health.py index 5480cd557fd..c6e738011d6 100644 --- a/tests/components/cloud/test_system_health.py +++ b/tests/components/cloud/test_system_health.py @@ -1,4 +1,5 @@ """Test cloud system health.""" + import asyncio from collections.abc import Callable, Coroutine from typing import Any diff --git a/tests/components/cloudflare/test_config_flow.py b/tests/components/cloudflare/test_config_flow.py index 21ee364eca3..142eab621e5 100644 --- a/tests/components/cloudflare/test_config_flow.py +++ b/tests/components/cloudflare/test_config_flow.py @@ -1,4 +1,5 @@ """Test the Cloudflare config flow.""" + import pycfdns from homeassistant.components.cloudflare.const import CONF_RECORDS, DOMAIN diff --git a/tests/components/coinbase/test_config_flow.py b/tests/components/coinbase/test_config_flow.py index 592481df129..971b6565d00 100644 --- a/tests/components/coinbase/test_config_flow.py +++ b/tests/components/coinbase/test_config_flow.py @@ -1,4 +1,5 @@ """Test the Coinbase config flow.""" + import logging from unittest.mock import patch diff --git a/tests/components/color_extractor/conftest.py b/tests/components/color_extractor/conftest.py index 299c8019f94..5c7d1136088 100644 --- a/tests/components/color_extractor/conftest.py +++ b/tests/components/color_extractor/conftest.py @@ -1,4 +1,5 @@ """Common fixtures for the Color extractor tests.""" + import pytest from homeassistant.components.color_extractor.const import DOMAIN diff --git a/tests/components/color_extractor/test_service.py b/tests/components/color_extractor/test_service.py index 647d945f158..6ad4830c2c4 100644 --- a/tests/components/color_extractor/test_service.py +++ b/tests/components/color_extractor/test_service.py @@ -1,4 +1,5 @@ """Tests for color_extractor component service calls.""" + import base64 import io from typing import Any diff --git a/tests/components/compensation/test_sensor.py b/tests/components/compensation/test_sensor.py index 5bc5a5e1c39..877a4f972a9 100644 --- a/tests/components/compensation/test_sensor.py +++ b/tests/components/compensation/test_sensor.py @@ -1,4 +1,5 @@ """The tests for the integration sensor platform.""" + import pytest from homeassistant.components.compensation.const import CONF_PRECISION, DOMAIN diff --git a/tests/components/config/test_area_registry.py b/tests/components/config/test_area_registry.py index c4e275651ff..fb9c5fd453b 100644 --- a/tests/components/config/test_area_registry.py +++ b/tests/components/config/test_area_registry.py @@ -1,4 +1,5 @@ """Test area_registry API.""" + import pytest from pytest_unordered import unordered diff --git a/tests/components/config/test_auth.py b/tests/components/config/test_auth.py index 21ca81e74ac..b839d2de7a0 100644 --- a/tests/components/config/test_auth.py +++ b/tests/components/config/test_auth.py @@ -1,4 +1,5 @@ """Test config entries API.""" + import pytest from homeassistant.auth import models as auth_models diff --git a/tests/components/config/test_device_registry.py b/tests/components/config/test_device_registry.py index 53746d2aa34..19c30a43858 100644 --- a/tests/components/config/test_device_registry.py +++ b/tests/components/config/test_device_registry.py @@ -1,4 +1,5 @@ """Test device_registry API.""" + import pytest from homeassistant.components.config import device_registry diff --git a/tests/components/config/test_entity_registry.py b/tests/components/config/test_entity_registry.py index 7069b22bf09..36e3b8b46ff 100644 --- a/tests/components/config/test_entity_registry.py +++ b/tests/components/config/test_entity_registry.py @@ -1,4 +1,5 @@ """Test entity_registry API.""" + import pytest from pytest_unordered import unordered diff --git a/tests/components/config/test_floor_registry.py b/tests/components/config/test_floor_registry.py index 6928a82898e..a3866c88ffa 100644 --- a/tests/components/config/test_floor_registry.py +++ b/tests/components/config/test_floor_registry.py @@ -1,4 +1,5 @@ """Test floor registry API.""" + import pytest from homeassistant.components.config import floor_registry diff --git a/tests/components/config/test_label_registry.py b/tests/components/config/test_label_registry.py index f65654462b9..aa082a3de38 100644 --- a/tests/components/config/test_label_registry.py +++ b/tests/components/config/test_label_registry.py @@ -1,4 +1,5 @@ """Test label registry API.""" + import pytest from homeassistant.components.config import label_registry diff --git a/tests/components/counter/test_init.py b/tests/components/counter/test_init.py index a52c083d10f..c0bd6344adb 100644 --- a/tests/components/counter/test_init.py +++ b/tests/components/counter/test_init.py @@ -1,4 +1,5 @@ """The tests for the counter component.""" + import logging import pytest diff --git a/tests/components/counter/test_reproduce_state.py b/tests/components/counter/test_reproduce_state.py index 44d0eca4d72..420c9b8907d 100644 --- a/tests/components/counter/test_reproduce_state.py +++ b/tests/components/counter/test_reproduce_state.py @@ -1,4 +1,5 @@ """Test reproduce state for Counter.""" + import pytest from homeassistant.core import HomeAssistant, State diff --git a/tests/components/cover/test_device_action.py b/tests/components/cover/test_device_action.py index c476f78702e..814d70e5c43 100644 --- a/tests/components/cover/test_device_action.py +++ b/tests/components/cover/test_device_action.py @@ -1,4 +1,5 @@ """The tests for Cover device actions.""" + import pytest from pytest_unordered import unordered diff --git a/tests/components/cover/test_device_condition.py b/tests/components/cover/test_device_condition.py index 2dcc719f35f..dc92b209e57 100644 --- a/tests/components/cover/test_device_condition.py +++ b/tests/components/cover/test_device_condition.py @@ -1,4 +1,5 @@ """The tests for Cover device conditions.""" + import pytest from pytest_unordered import unordered diff --git a/tests/components/cover/test_reproduce_state.py b/tests/components/cover/test_reproduce_state.py index 70f8201fedc..f5dd01745d3 100644 --- a/tests/components/cover/test_reproduce_state.py +++ b/tests/components/cover/test_reproduce_state.py @@ -1,4 +1,5 @@ """Test reproduce state for Cover.""" + import pytest from homeassistant.components.cover import ( diff --git a/tests/components/cover/test_significant_change.py b/tests/components/cover/test_significant_change.py index 9ddb2cb9498..5e5032dce3f 100644 --- a/tests/components/cover/test_significant_change.py +++ b/tests/components/cover/test_significant_change.py @@ -1,4 +1,5 @@ """Test the Cover significant change platform.""" + import pytest from homeassistant.components.cover import ( diff --git a/tests/components/deconz/test_config_flow.py b/tests/components/deconz/test_config_flow.py index 7874b7899c8..a6910ef4b55 100644 --- a/tests/components/deconz/test_config_flow.py +++ b/tests/components/deconz/test_config_flow.py @@ -1,4 +1,5 @@ """Tests for deCONZ config flow.""" + import logging from unittest.mock import patch diff --git a/tests/components/deconz/test_init.py b/tests/components/deconz/test_init.py index fe364779059..278a137bb89 100644 --- a/tests/components/deconz/test_init.py +++ b/tests/components/deconz/test_init.py @@ -1,4 +1,5 @@ """Test deCONZ component setup process.""" + import asyncio from unittest.mock import patch diff --git a/tests/components/demo/test_init.py b/tests/components/demo/test_init.py index fdf72c7fd34..05532d7503b 100644 --- a/tests/components/demo/test_init.py +++ b/tests/components/demo/test_init.py @@ -1,4 +1,5 @@ """The tests for the Demo component.""" + import json from unittest.mock import patch diff --git a/tests/components/demo/test_notify.py b/tests/components/demo/test_notify.py index 96ffcdec96b..54eadc3bd91 100644 --- a/tests/components/demo/test_notify.py +++ b/tests/components/demo/test_notify.py @@ -1,4 +1,5 @@ """The tests for the notify demo platform.""" + import logging from unittest.mock import patch diff --git a/tests/components/demo/test_weather.py b/tests/components/demo/test_weather.py index bb91535192c..403b8b1d346 100644 --- a/tests/components/demo/test_weather.py +++ b/tests/components/demo/test_weather.py @@ -1,4 +1,5 @@ """The tests for the demo weather component.""" + import datetime from typing import Any from unittest.mock import patch diff --git a/tests/components/derivative/test_init.py b/tests/components/derivative/test_init.py index eab8ca67be7..8d387c4ecab 100644 --- a/tests/components/derivative/test_init.py +++ b/tests/components/derivative/test_init.py @@ -1,4 +1,5 @@ """Test the Derivative integration.""" + import pytest from homeassistant.components.derivative.const import DOMAIN diff --git a/tests/components/devialet/test_diagnostics.py b/tests/components/devialet/test_diagnostics.py index 82600de7cf5..97c23efe713 100644 --- a/tests/components/devialet/test_diagnostics.py +++ b/tests/components/devialet/test_diagnostics.py @@ -1,4 +1,5 @@ """Test the Devialet diagnostics.""" + import json from homeassistant.core import HomeAssistant diff --git a/tests/components/device_tracker/test_device_condition.py b/tests/components/device_tracker/test_device_condition.py index f550b803fda..c5abff2e517 100644 --- a/tests/components/device_tracker/test_device_condition.py +++ b/tests/components/device_tracker/test_device_condition.py @@ -1,4 +1,5 @@ """The tests for Device tracker device conditions.""" + import pytest from pytest_unordered import unordered diff --git a/tests/components/device_tracker/test_device_trigger.py b/tests/components/device_tracker/test_device_trigger.py index 3e19570ebcb..217f7641a58 100644 --- a/tests/components/device_tracker/test_device_trigger.py +++ b/tests/components/device_tracker/test_device_trigger.py @@ -1,4 +1,5 @@ """The tests for Device Tracker device triggers.""" + import pytest from pytest_unordered import unordered import voluptuous_serialize diff --git a/tests/components/dialogflow/test_init.py b/tests/components/dialogflow/test_init.py index 3e90856fc12..7f5fe79d146 100644 --- a/tests/components/dialogflow/test_init.py +++ b/tests/components/dialogflow/test_init.py @@ -1,4 +1,5 @@ """The tests for the Dialogflow component.""" + import copy from http import HTTPStatus import json diff --git a/tests/components/directv/test_config_flow.py b/tests/components/directv/test_config_flow.py index 8017dc290c9..569e165a0a6 100644 --- a/tests/components/directv/test_config_flow.py +++ b/tests/components/directv/test_config_flow.py @@ -1,4 +1,5 @@ """Test the DirecTV config flow.""" + import dataclasses from unittest.mock import patch diff --git a/tests/components/discord/test_config_flow.py b/tests/components/discord/test_config_flow.py index b6504e851ca..ba1909c48c8 100644 --- a/tests/components/discord/test_config_flow.py +++ b/tests/components/discord/test_config_flow.py @@ -1,4 +1,5 @@ """Test Discord config flow.""" + import nextcord from homeassistant import config_entries, data_entry_flow diff --git a/tests/components/discord/test_notify.py b/tests/components/discord/test_notify.py index 810898cdf73..011698867a8 100644 --- a/tests/components/discord/test_notify.py +++ b/tests/components/discord/test_notify.py @@ -1,4 +1,5 @@ """Test Discord notify.""" + import logging import pytest diff --git a/tests/components/discovergy/const.py b/tests/components/discovergy/const.py index 3c9f696fb02..700d001814d 100644 --- a/tests/components/discovergy/const.py +++ b/tests/components/discovergy/const.py @@ -1,4 +1,5 @@ """Constants for Discovergy integration tests.""" + import datetime from pydiscovergy.models import Location, Meter, Reading diff --git a/tests/components/discovergy/test_diagnostics.py b/tests/components/discovergy/test_diagnostics.py index f2db5fb854d..5c231c3d221 100644 --- a/tests/components/discovergy/test_diagnostics.py +++ b/tests/components/discovergy/test_diagnostics.py @@ -1,4 +1,5 @@ """Test Discovergy diagnostics.""" + import pytest from syrupy import SnapshotAssertion diff --git a/tests/components/discovergy/test_system_health.py b/tests/components/discovergy/test_system_health.py index e64072f1023..af8d9dde5b4 100644 --- a/tests/components/discovergy/test_system_health.py +++ b/tests/components/discovergy/test_system_health.py @@ -1,4 +1,5 @@ """Test Discovergy system health.""" + import asyncio from aiohttp import ClientError diff --git a/tests/components/dsmr/conftest.py b/tests/components/dsmr/conftest.py index 01aff5ae48e..7b9e583253b 100644 --- a/tests/components/dsmr/conftest.py +++ b/tests/components/dsmr/conftest.py @@ -1,4 +1,5 @@ """Common test tools.""" + import asyncio from unittest.mock import MagicMock, patch diff --git a/tests/components/dsmr/test_mbus_migration.py b/tests/components/dsmr/test_mbus_migration.py index 5e31fa7a82e..95def2f66cf 100644 --- a/tests/components/dsmr/test_mbus_migration.py +++ b/tests/components/dsmr/test_mbus_migration.py @@ -1,4 +1,5 @@ """Tests for the DSMR integration.""" + import datetime from decimal import Decimal diff --git a/tests/components/dsmr/test_sensor.py b/tests/components/dsmr/test_sensor.py index cd3e60c7aeb..f63422e0543 100644 --- a/tests/components/dsmr/test_sensor.py +++ b/tests/components/dsmr/test_sensor.py @@ -4,6 +4,7 @@ Tests setup of the DSMR component and ensure incoming telegrams cause Entity to be updated with new values. """ + import asyncio import datetime from decimal import Decimal diff --git a/tests/components/dte_energy_bridge/test_sensor.py b/tests/components/dte_energy_bridge/test_sensor.py index f62520701bd..244bec4e270 100644 --- a/tests/components/dte_energy_bridge/test_sensor.py +++ b/tests/components/dte_energy_bridge/test_sensor.py @@ -1,4 +1,5 @@ """The tests for the DTE Energy Bridge.""" + import requests_mock from homeassistant.core import HomeAssistant diff --git a/tests/components/eafm/test_sensor.py b/tests/components/eafm/test_sensor.py index 04659a79d1c..380e1df5f37 100644 --- a/tests/components/eafm/test_sensor.py +++ b/tests/components/eafm/test_sensor.py @@ -1,4 +1,5 @@ """Tests for polling measures.""" + import datetime import aiohttp diff --git a/tests/components/ecobee/test_climate.py b/tests/components/ecobee/test_climate.py index 642e4830016..7b9a31739dc 100644 --- a/tests/components/ecobee/test_climate.py +++ b/tests/components/ecobee/test_climate.py @@ -1,4 +1,5 @@ """The test for the Ecobee thermostat module.""" + import copy from http import HTTPStatus from unittest import mock diff --git a/tests/components/ecobee/test_util.py b/tests/components/ecobee/test_util.py index 368721f71c0..88032362af0 100644 --- a/tests/components/ecobee/test_util.py +++ b/tests/components/ecobee/test_util.py @@ -1,4 +1,5 @@ """Tests for the ecobee.util module.""" + import pytest import voluptuous as vol diff --git a/tests/components/ecovacs/util.py b/tests/components/ecovacs/util.py index 73762128202..c587494f5e2 100644 --- a/tests/components/ecovacs/util.py +++ b/tests/components/ecovacs/util.py @@ -1,4 +1,5 @@ """Ecovacs test util.""" + import asyncio from deebot_client.event_bus import EventBus diff --git a/tests/components/elgato/test_sensor.py b/tests/components/elgato/test_sensor.py index f53e2e43156..1ad37d938e7 100644 --- a/tests/components/elgato/test_sensor.py +++ b/tests/components/elgato/test_sensor.py @@ -1,4 +1,5 @@ """Tests for the Elgato sensor platform.""" + import pytest from syrupy.assertion import SnapshotAssertion diff --git a/tests/components/elmax/conftest.py b/tests/components/elmax/conftest.py index 85e4902b010..e69f52f4cad 100644 --- a/tests/components/elmax/conftest.py +++ b/tests/components/elmax/conftest.py @@ -1,4 +1,5 @@ """Configuration for Elmax tests.""" + import json from unittest.mock import patch diff --git a/tests/components/emulated_hue/test_hue_api.py b/tests/components/emulated_hue/test_hue_api.py index 167562578f2..08974b36215 100644 --- a/tests/components/emulated_hue/test_hue_api.py +++ b/tests/components/emulated_hue/test_hue_api.py @@ -1,4 +1,5 @@ """The tests for the emulated Hue component.""" + import asyncio from datetime import timedelta from http import HTTPStatus diff --git a/tests/components/emulated_kasa/test_init.py b/tests/components/emulated_kasa/test_init.py index 5d294ec3bba..36eaa749f11 100644 --- a/tests/components/emulated_kasa/test_init.py +++ b/tests/components/emulated_kasa/test_init.py @@ -1,4 +1,5 @@ """Tests for emulated_kasa library bindings.""" + import math from unittest.mock import AsyncMock, Mock, patch diff --git a/tests/components/energy/test_sensor.py b/tests/components/energy/test_sensor.py index 522bbe5af06..c51a228f7f0 100644 --- a/tests/components/energy/test_sensor.py +++ b/tests/components/energy/test_sensor.py @@ -1,4 +1,5 @@ """Test the Energy sensors.""" + import copy from datetime import timedelta from typing import Any diff --git a/tests/components/esphome/test_entity.py b/tests/components/esphome/test_entity.py index 609af788ceb..4056c286b51 100644 --- a/tests/components/esphome/test_entity.py +++ b/tests/components/esphome/test_entity.py @@ -1,4 +1,5 @@ """Test ESPHome binary sensors.""" + import asyncio from collections.abc import Awaitable, Callable from typing import Any diff --git a/tests/components/esphome/test_manager.py b/tests/components/esphome/test_manager.py index 424ab7338aa..55369e54b53 100644 --- a/tests/components/esphome/test_manager.py +++ b/tests/components/esphome/test_manager.py @@ -1,4 +1,5 @@ """Test ESPHome manager.""" + import asyncio from collections.abc import Awaitable, Callable from unittest.mock import AsyncMock, call diff --git a/tests/components/evil_genius_labs/conftest.py b/tests/components/evil_genius_labs/conftest.py index a4f10fe97c4..dd3f5fe24f4 100644 --- a/tests/components/evil_genius_labs/conftest.py +++ b/tests/components/evil_genius_labs/conftest.py @@ -1,4 +1,5 @@ """Test helpers for Evil Genius Labs.""" + import json from unittest.mock import patch diff --git a/tests/components/evil_genius_labs/test_diagnostics.py b/tests/components/evil_genius_labs/test_diagnostics.py index 2435244d3c5..0ad7f6e27f3 100644 --- a/tests/components/evil_genius_labs/test_diagnostics.py +++ b/tests/components/evil_genius_labs/test_diagnostics.py @@ -1,4 +1,5 @@ """Test evil genius labs diagnostics.""" + import pytest from homeassistant.components.diagnostics import REDACTED diff --git a/tests/components/evil_genius_labs/test_init.py b/tests/components/evil_genius_labs/test_init.py index 85055c0a73c..71b8a6164a6 100644 --- a/tests/components/evil_genius_labs/test_init.py +++ b/tests/components/evil_genius_labs/test_init.py @@ -1,4 +1,5 @@ """Test evil genius labs init.""" + import pytest from homeassistant import config_entries diff --git a/tests/components/fan/test_device_action.py b/tests/components/fan/test_device_action.py index b8756d9ace5..49d6f441b1e 100644 --- a/tests/components/fan/test_device_action.py +++ b/tests/components/fan/test_device_action.py @@ -1,4 +1,5 @@ """The tests for Fan device actions.""" + import pytest from pytest_unordered import unordered diff --git a/tests/components/fan/test_device_condition.py b/tests/components/fan/test_device_condition.py index 1ee168f28ab..18744155f91 100644 --- a/tests/components/fan/test_device_condition.py +++ b/tests/components/fan/test_device_condition.py @@ -1,4 +1,5 @@ """The tests for Fan device conditions.""" + import pytest from pytest_unordered import unordered diff --git a/tests/components/fan/test_init.py b/tests/components/fan/test_init.py index 1beea47c6fa..911954d1ecd 100644 --- a/tests/components/fan/test_init.py +++ b/tests/components/fan/test_init.py @@ -1,4 +1,5 @@ """Tests for fan platforms.""" + import pytest from homeassistant.components import fan diff --git a/tests/components/fan/test_reproduce_state.py b/tests/components/fan/test_reproduce_state.py index 3d9ea90e735..e1904b34769 100644 --- a/tests/components/fan/test_reproduce_state.py +++ b/tests/components/fan/test_reproduce_state.py @@ -1,4 +1,5 @@ """Test reproduce state for Fan.""" + import pytest from homeassistant.components.fan import ( diff --git a/tests/components/fan/test_significant_change.py b/tests/components/fan/test_significant_change.py index 764abb6e8ee..9b940e33138 100644 --- a/tests/components/fan/test_significant_change.py +++ b/tests/components/fan/test_significant_change.py @@ -1,4 +1,5 @@ """Test the Fan significant change platform.""" + import pytest from homeassistant.components.fan import ( diff --git a/tests/components/fido/test_sensor.py b/tests/components/fido/test_sensor.py index 81ae54174ca..a067f060af8 100644 --- a/tests/components/fido/test_sensor.py +++ b/tests/components/fido/test_sensor.py @@ -1,4 +1,5 @@ """The test for the fido sensor platform.""" + import logging from unittest.mock import MagicMock, patch diff --git a/tests/components/file/test_notify.py b/tests/components/file/test_notify.py index 9cde648d27c..071c68caea3 100644 --- a/tests/components/file/test_notify.py +++ b/tests/components/file/test_notify.py @@ -1,4 +1,5 @@ """The tests for the notify file platform.""" + import os from unittest.mock import call, mock_open, patch diff --git a/tests/components/filesize/test_sensor.py b/tests/components/filesize/test_sensor.py index 20354df13bd..880563f0ad8 100644 --- a/tests/components/filesize/test_sensor.py +++ b/tests/components/filesize/test_sensor.py @@ -1,4 +1,5 @@ """The tests for the filesize sensor.""" + import os from pathlib import Path diff --git a/tests/components/flexit_bacnet/test_config_flow.py b/tests/components/flexit_bacnet/test_config_flow.py index 860d25e4b75..7d864a80c2d 100644 --- a/tests/components/flexit_bacnet/test_config_flow.py +++ b/tests/components/flexit_bacnet/test_config_flow.py @@ -1,4 +1,5 @@ """Test the Flexit Nordic (BACnet) config flow.""" + import asyncio.exceptions from flexit_bacnet import DecodingError diff --git a/tests/components/flo/test_services.py b/tests/components/flo/test_services.py index d38c5c45031..c65aa7937ee 100644 --- a/tests/components/flo/test_services.py +++ b/tests/components/flo/test_services.py @@ -1,4 +1,5 @@ """Test the services for the Flo by Moen integration.""" + import pytest from voluptuous.error import MultipleInvalid diff --git a/tests/components/folder/test_sensor.py b/tests/components/folder/test_sensor.py index c45fe2ae5f5..ad0969c6a0f 100644 --- a/tests/components/folder/test_sensor.py +++ b/tests/components/folder/test_sensor.py @@ -1,4 +1,5 @@ """The tests for the folder sensor.""" + import os from homeassistant.components.folder.sensor import CONF_FOLDER_PATHS diff --git a/tests/components/folder_watcher/test_init.py b/tests/components/folder_watcher/test_init.py index b09e060725f..2e9eb99f678 100644 --- a/tests/components/folder_watcher/test_init.py +++ b/tests/components/folder_watcher/test_init.py @@ -1,4 +1,5 @@ """The tests for the folder_watcher component.""" + import os from types import SimpleNamespace from unittest.mock import Mock, patch diff --git a/tests/components/freebox/conftest.py b/tests/components/freebox/conftest.py index 6042248561c..e223e868d83 100644 --- a/tests/components/freebox/conftest.py +++ b/tests/components/freebox/conftest.py @@ -1,4 +1,5 @@ """Test helpers for Freebox.""" + import json from unittest.mock import AsyncMock, PropertyMock, patch diff --git a/tests/components/freebox/test_router.py b/tests/components/freebox/test_router.py index 88cf56de2bb..623f595e1ad 100644 --- a/tests/components/freebox/test_router.py +++ b/tests/components/freebox/test_router.py @@ -1,4 +1,5 @@ """Tests for the Freebox utility methods.""" + import json from unittest.mock import Mock diff --git a/tests/components/freedns/test_init.py b/tests/components/freedns/test_init.py index 9163a8faf2d..bdb60933a19 100644 --- a/tests/components/freedns/test_init.py +++ b/tests/components/freedns/test_init.py @@ -1,4 +1,5 @@ """Test the FreeDNS component.""" + import pytest from homeassistant.components import freedns diff --git a/tests/components/freedompro/test_init.py b/tests/components/freedompro/test_init.py index 5e1b050a4e7..18bf6d41ae2 100644 --- a/tests/components/freedompro/test_init.py +++ b/tests/components/freedompro/test_init.py @@ -1,4 +1,5 @@ """Freedompro component tests.""" + import logging from unittest.mock import patch diff --git a/tests/components/fritz/conftest.py b/tests/components/fritz/conftest.py index 08dce14f18d..2e26f67c1eb 100644 --- a/tests/components/fritz/conftest.py +++ b/tests/components/fritz/conftest.py @@ -1,4 +1,5 @@ """Common stuff for Fritz!Tools tests.""" + import logging from unittest.mock import MagicMock, patch diff --git a/tests/components/fritz/test_config_flow.py b/tests/components/fritz/test_config_flow.py index 5b87d897dd9..5db70e348dd 100644 --- a/tests/components/fritz/test_config_flow.py +++ b/tests/components/fritz/test_config_flow.py @@ -1,4 +1,5 @@ """Tests for Fritz!Tools config flow.""" + import dataclasses from unittest.mock import patch diff --git a/tests/components/fritzbox/test_config_flow.py b/tests/components/fritzbox/test_config_flow.py index 674beda13ee..cf93e74edac 100644 --- a/tests/components/fritzbox/test_config_flow.py +++ b/tests/components/fritzbox/test_config_flow.py @@ -1,4 +1,5 @@ """Tests for AVM Fritz!Box config flow.""" + import dataclasses from unittest import mock from unittest.mock import Mock, patch diff --git a/tests/components/fully_kiosk/test_init.py b/tests/components/fully_kiosk/test_init.py index e74da6434cd..f3fb945c8f0 100644 --- a/tests/components/fully_kiosk/test_init.py +++ b/tests/components/fully_kiosk/test_init.py @@ -1,4 +1,5 @@ """Tests for the Fully Kiosk Browser integration.""" + import json from unittest.mock import MagicMock, patch diff --git a/tests/components/gdacs/conftest.py b/tests/components/gdacs/conftest.py index ee82a3131b1..9d9a91aa407 100644 --- a/tests/components/gdacs/conftest.py +++ b/tests/components/gdacs/conftest.py @@ -1,4 +1,5 @@ """Configuration for GDACS tests.""" + import pytest from homeassistant.components.gdacs import CONF_CATEGORIES, DOMAIN diff --git a/tests/components/gdacs/test_geo_location.py b/tests/components/gdacs/test_geo_location.py index c7f5a0f72e3..467b6dc2fc4 100644 --- a/tests/components/gdacs/test_geo_location.py +++ b/tests/components/gdacs/test_geo_location.py @@ -1,4 +1,5 @@ """The tests for the GDACS Feed integration.""" + import datetime from unittest.mock import patch diff --git a/tests/components/generic/test_camera.py b/tests/components/generic/test_camera.py index 608b8666027..ac882716103 100644 --- a/tests/components/generic/test_camera.py +++ b/tests/components/generic/test_camera.py @@ -1,4 +1,5 @@ """The tests for generic camera component.""" + import asyncio from datetime import timedelta from http import HTTPStatus diff --git a/tests/components/generic/test_config_flow.py b/tests/components/generic/test_config_flow.py index 86bd552bcf3..6ced5086282 100644 --- a/tests/components/generic/test_config_flow.py +++ b/tests/components/generic/test_config_flow.py @@ -1,4 +1,5 @@ """Test The generic (IP Camera) config flow.""" + import contextlib import errno from http import HTTPStatus diff --git a/tests/components/generic/test_diagnostics.py b/tests/components/generic/test_diagnostics.py index 99dc3e22a0b..f68c3ba4bc6 100644 --- a/tests/components/generic/test_diagnostics.py +++ b/tests/components/generic/test_diagnostics.py @@ -1,4 +1,5 @@ """Test generic (IP camera) diagnostics.""" + import pytest from homeassistant.components.diagnostics import REDACTED diff --git a/tests/components/generic_hygrostat/test_humidifier.py b/tests/components/generic_hygrostat/test_humidifier.py index e1a33a19834..fdad20f5b2d 100644 --- a/tests/components/generic_hygrostat/test_humidifier.py +++ b/tests/components/generic_hygrostat/test_humidifier.py @@ -1,4 +1,5 @@ """The tests for the generic_hygrostat.""" + import datetime from freezegun import freeze_time diff --git a/tests/components/generic_thermostat/test_climate.py b/tests/components/generic_thermostat/test_climate.py index e181b14efb0..c7b6c03a2c5 100644 --- a/tests/components/generic_thermostat/test_climate.py +++ b/tests/components/generic_thermostat/test_climate.py @@ -1,4 +1,5 @@ """The tests for the generic_thermostat.""" + import datetime from unittest.mock import patch diff --git a/tests/components/geo_location/test_init.py b/tests/components/geo_location/test_init.py index 0861cd7cba1..747135def9b 100644 --- a/tests/components/geo_location/test_init.py +++ b/tests/components/geo_location/test_init.py @@ -1,4 +1,5 @@ """The tests for the geolocation component.""" + import pytest from homeassistant.components import geo_location diff --git a/tests/components/geo_location/test_trigger.py b/tests/components/geo_location/test_trigger.py index a5e0f99c5c2..85461d60aac 100644 --- a/tests/components/geo_location/test_trigger.py +++ b/tests/components/geo_location/test_trigger.py @@ -1,4 +1,5 @@ """The tests for the geolocation trigger.""" + import logging import pytest diff --git a/tests/components/geonetnz_quakes/conftest.py b/tests/components/geonetnz_quakes/conftest.py index 7715b17796b..c93d4a2e50c 100644 --- a/tests/components/geonetnz_quakes/conftest.py +++ b/tests/components/geonetnz_quakes/conftest.py @@ -1,4 +1,5 @@ """Configuration for GeoNet NZ Quakes tests.""" + import pytest from homeassistant.components.geonetnz_quakes import ( diff --git a/tests/components/geonetnz_quakes/test_geo_location.py b/tests/components/geonetnz_quakes/test_geo_location.py index afc6ada75cd..19f1954d06a 100644 --- a/tests/components/geonetnz_quakes/test_geo_location.py +++ b/tests/components/geonetnz_quakes/test_geo_location.py @@ -1,4 +1,5 @@ """The tests for the GeoNet NZ Quakes Feed integration.""" + import datetime from unittest.mock import patch diff --git a/tests/components/geonetnz_quakes/test_sensor.py b/tests/components/geonetnz_quakes/test_sensor.py index 27f67dad322..02edfc910b2 100644 --- a/tests/components/geonetnz_quakes/test_sensor.py +++ b/tests/components/geonetnz_quakes/test_sensor.py @@ -1,4 +1,5 @@ """The tests for the GeoNet NZ Quakes Feed integration.""" + import datetime from unittest.mock import patch diff --git a/tests/components/geonetnz_volcano/conftest.py b/tests/components/geonetnz_volcano/conftest.py index 33a299eeb79..3df67e91c95 100644 --- a/tests/components/geonetnz_volcano/conftest.py +++ b/tests/components/geonetnz_volcano/conftest.py @@ -1,4 +1,5 @@ """Configuration for GeoNet NZ Volcano tests.""" + import pytest from homeassistant.components.geonetnz_volcano import DOMAIN diff --git a/tests/components/gios/test_config_flow.py b/tests/components/gios/test_config_flow.py index efe46be9b8d..a735b45975a 100644 --- a/tests/components/gios/test_config_flow.py +++ b/tests/components/gios/test_config_flow.py @@ -1,4 +1,5 @@ """Define tests for the GIOS config flow.""" + import json from unittest.mock import patch diff --git a/tests/components/gios/test_init.py b/tests/components/gios/test_init.py index d20aecad3df..6082fa8c522 100644 --- a/tests/components/gios/test_init.py +++ b/tests/components/gios/test_init.py @@ -1,4 +1,5 @@ """Test init of GIOS integration.""" + import json from unittest.mock import patch diff --git a/tests/components/gios/test_system_health.py b/tests/components/gios/test_system_health.py index 571614ed1de..896f3cca04a 100644 --- a/tests/components/gios/test_system_health.py +++ b/tests/components/gios/test_system_health.py @@ -1,4 +1,5 @@ """Test GIOS system health.""" + import asyncio from aiohttp import ClientError diff --git a/tests/components/github/test_init.py b/tests/components/github/test_init.py index 03cc2e92720..a25e27df835 100644 --- a/tests/components/github/test_init.py +++ b/tests/components/github/test_init.py @@ -1,4 +1,5 @@ """Test the GitHub init file.""" + import pytest from homeassistant.components.github import CONF_REPOSITORIES diff --git a/tests/components/github/test_sensor.py b/tests/components/github/test_sensor.py index f81f59e88c9..b0eaed3ae0e 100644 --- a/tests/components/github/test_sensor.py +++ b/tests/components/github/test_sensor.py @@ -1,4 +1,5 @@ """Test GitHub sensor.""" + import json import pytest diff --git a/tests/components/google_assistant/test_data_redaction.py b/tests/components/google_assistant/test_data_redaction.py index 86b15782fe5..d650a223e15 100644 --- a/tests/components/google_assistant/test_data_redaction.py +++ b/tests/components/google_assistant/test_data_redaction.py @@ -1,4 +1,5 @@ """Test data redaction helpers.""" + import json from homeassistant.components.google_assistant.data_redaction import async_redact_msg diff --git a/tests/components/google_assistant/test_smart_home.py b/tests/components/google_assistant/test_smart_home.py index 587d89a1d8a..04ceafb004a 100644 --- a/tests/components/google_assistant/test_smart_home.py +++ b/tests/components/google_assistant/test_smart_home.py @@ -1,4 +1,5 @@ """Test Google Smart Home.""" + import asyncio from types import SimpleNamespace from unittest.mock import ANY, patch diff --git a/tests/components/google_mail/test_init.py b/tests/components/google_mail/test_init.py index ef2f1475dad..6e7def716a9 100644 --- a/tests/components/google_mail/test_init.py +++ b/tests/components/google_mail/test_init.py @@ -1,4 +1,5 @@ """Tests for Google Mail.""" + import http import time from unittest.mock import patch diff --git a/tests/components/google_travel_time/test_config_flow.py b/tests/components/google_travel_time/test_config_flow.py index b701fcb2143..24e9cb1297a 100644 --- a/tests/components/google_travel_time/test_config_flow.py +++ b/tests/components/google_travel_time/test_config_flow.py @@ -1,4 +1,5 @@ """Test the Google Maps Travel Time config flow.""" + import pytest from homeassistant import config_entries, data_entry_flow diff --git a/tests/components/graphite/test_init.py b/tests/components/graphite/test_init.py index fec75bf5fcc..738f8eda333 100644 --- a/tests/components/graphite/test_init.py +++ b/tests/components/graphite/test_init.py @@ -1,4 +1,5 @@ """The tests for the Graphite component.""" + import socket from unittest import mock from unittest.mock import patch diff --git a/tests/components/gree/common.py b/tests/components/gree/common.py index aa88688486c..97656596ce6 100644 --- a/tests/components/gree/common.py +++ b/tests/components/gree/common.py @@ -1,4 +1,5 @@ """Common helpers for gree test cases.""" + import asyncio import logging from unittest.mock import AsyncMock, Mock diff --git a/tests/components/group/conftest.py b/tests/components/group/conftest.py index 3aefbfacdf8..5d332f8d904 100644 --- a/tests/components/group/conftest.py +++ b/tests/components/group/conftest.py @@ -1,4 +1,5 @@ """group conftest.""" + import pytest from homeassistant.core import HomeAssistant diff --git a/tests/components/group/test_cover.py b/tests/components/group/test_cover.py index d0eb3788763..5b5d8fa873c 100644 --- a/tests/components/group/test_cover.py +++ b/tests/components/group/test_cover.py @@ -1,4 +1,5 @@ """The tests for the group cover platform.""" + import asyncio from datetime import timedelta diff --git a/tests/components/group/test_fan.py b/tests/components/group/test_fan.py index ecc21ab0cd2..6aa6fc2933d 100644 --- a/tests/components/group/test_fan.py +++ b/tests/components/group/test_fan.py @@ -1,4 +1,5 @@ """The tests for the group fan platform.""" + import asyncio from unittest.mock import patch diff --git a/tests/components/group/test_light.py b/tests/components/group/test_light.py index 63f21456066..b279c38d169 100644 --- a/tests/components/group/test_light.py +++ b/tests/components/group/test_light.py @@ -1,4 +1,5 @@ """The tests for the Group Light platform.""" + import asyncio from unittest.mock import MagicMock, patch diff --git a/tests/components/group/test_media_player.py b/tests/components/group/test_media_player.py index 9f36693d9ef..451aae200b3 100644 --- a/tests/components/group/test_media_player.py +++ b/tests/components/group/test_media_player.py @@ -1,4 +1,5 @@ """The tests for the Media group platform.""" + import asyncio from unittest.mock import Mock, patch diff --git a/tests/components/group/test_switch.py b/tests/components/group/test_switch.py index 86f6eb43ed9..32b21fcb0d7 100644 --- a/tests/components/group/test_switch.py +++ b/tests/components/group/test_switch.py @@ -1,4 +1,5 @@ """The tests for the Group Switch platform.""" + import asyncio from unittest.mock import patch diff --git a/tests/components/harmony/test_subscriber.py b/tests/components/harmony/test_subscriber.py index bdc57385852..94a8ffbc37a 100644 --- a/tests/components/harmony/test_subscriber.py +++ b/tests/components/harmony/test_subscriber.py @@ -1,4 +1,5 @@ """Test the HarmonySubscriberMixin class.""" + import asyncio from unittest.mock import AsyncMock, MagicMock diff --git a/tests/components/hassio/conftest.py b/tests/components/hassio/conftest.py index e54fdcafd1d..f795e19d91f 100644 --- a/tests/components/hassio/conftest.py +++ b/tests/components/hassio/conftest.py @@ -1,4 +1,5 @@ """Fixtures for Hass.io.""" + import os import re from unittest.mock import Mock, patch diff --git a/tests/components/hassio/test_binary_sensor.py b/tests/components/hassio/test_binary_sensor.py index 854a6782b1a..d502d6ea730 100644 --- a/tests/components/hassio/test_binary_sensor.py +++ b/tests/components/hassio/test_binary_sensor.py @@ -1,4 +1,5 @@ """The tests for the hassio binary sensors.""" + import os from unittest.mock import patch diff --git a/tests/components/hassio/test_system_health.py b/tests/components/hassio/test_system_health.py index bce3e5991fb..873365aa3a0 100644 --- a/tests/components/hassio/test_system_health.py +++ b/tests/components/hassio/test_system_health.py @@ -1,4 +1,5 @@ """Test hassio system health.""" + import asyncio import os from unittest.mock import patch diff --git a/tests/components/hassio/test_websocket_api.py b/tests/components/hassio/test_websocket_api.py index b2f9e06cb43..7152b248336 100644 --- a/tests/components/hassio/test_websocket_api.py +++ b/tests/components/hassio/test_websocket_api.py @@ -1,4 +1,5 @@ """Test websocket API.""" + import pytest from homeassistant.components.hassio.const import ( diff --git a/tests/components/hddtemp/test_sensor.py b/tests/components/hddtemp/test_sensor.py index 70a9910595c..170f30eae37 100644 --- a/tests/components/hddtemp/test_sensor.py +++ b/tests/components/hddtemp/test_sensor.py @@ -1,4 +1,5 @@ """The tests for the hddtemp platform.""" + import socket from unittest.mock import patch diff --git a/tests/components/heos/test_init.py b/tests/components/heos/test_init.py index 761ab45dabc..4aca77fd90f 100644 --- a/tests/components/heos/test_init.py +++ b/tests/components/heos/test_init.py @@ -1,4 +1,5 @@ """Tests for the init module.""" + import asyncio from unittest.mock import Mock, patch diff --git a/tests/components/heos/test_media_player.py b/tests/components/heos/test_media_player.py index 70d96a0d5cb..99d09cfb7b1 100644 --- a/tests/components/heos/test_media_player.py +++ b/tests/components/heos/test_media_player.py @@ -1,4 +1,5 @@ """Tests for the Heos Media Player platform.""" + import asyncio from pyheos import CommandFailedError, const diff --git a/tests/components/here_travel_time/conftest.py b/tests/components/here_travel_time/conftest.py index dff91a4e1fb..3cbbc6d8c78 100644 --- a/tests/components/here_travel_time/conftest.py +++ b/tests/components/here_travel_time/conftest.py @@ -1,4 +1,5 @@ """Fixtures for HERE Travel Time tests.""" + import json from unittest.mock import patch diff --git a/tests/components/history/conftest.py b/tests/components/history/conftest.py index 86d8d2a9421..0ce6a190f55 100644 --- a/tests/components/history/conftest.py +++ b/tests/components/history/conftest.py @@ -1,4 +1,5 @@ """Fixtures for history tests.""" + import pytest from homeassistant.components import history diff --git a/tests/components/history/test_websocket_api.py b/tests/components/history/test_websocket_api.py index 9ba47303e53..72fd9420a61 100644 --- a/tests/components/history/test_websocket_api.py +++ b/tests/components/history/test_websocket_api.py @@ -1,4 +1,5 @@ """The tests the History component websocket_api.""" + import asyncio from datetime import timedelta from unittest.mock import patch diff --git a/tests/components/hko/conftest.py b/tests/components/hko/conftest.py index fd2181ddfc9..853eca6507b 100644 --- a/tests/components/hko/conftest.py +++ b/tests/components/hko/conftest.py @@ -1,4 +1,5 @@ """Configure py.test.""" + import json from unittest.mock import patch diff --git a/tests/components/hlk_sw16/test_config_flow.py b/tests/components/hlk_sw16/test_config_flow.py index d390bcc6c79..3079d72baf8 100644 --- a/tests/components/hlk_sw16/test_config_flow.py +++ b/tests/components/hlk_sw16/test_config_flow.py @@ -1,4 +1,5 @@ """Test the Hi-Link HLK-SW16 config flow.""" + import asyncio from unittest.mock import patch diff --git a/tests/components/homeassistant/test_exposed_entities.py b/tests/components/homeassistant/test_exposed_entities.py index fd09bcee45a..e20fcb69d00 100644 --- a/tests/components/homeassistant/test_exposed_entities.py +++ b/tests/components/homeassistant/test_exposed_entities.py @@ -1,4 +1,5 @@ """Test Home Assistant exposed entities helper.""" + import pytest from syrupy.assertion import SnapshotAssertion diff --git a/tests/components/homeassistant/test_init.py b/tests/components/homeassistant/test_init.py index 09a9ffc58b8..2294e7a8f75 100644 --- a/tests/components/homeassistant/test_init.py +++ b/tests/components/homeassistant/test_init.py @@ -1,4 +1,5 @@ """The tests for Core components.""" + import asyncio import unittest from unittest.mock import Mock, patch diff --git a/tests/components/homeassistant/triggers/test_event.py b/tests/components/homeassistant/triggers/test_event.py index d996cd74da7..af781bd1802 100644 --- a/tests/components/homeassistant/triggers/test_event.py +++ b/tests/components/homeassistant/triggers/test_event.py @@ -1,4 +1,5 @@ """The tests for the Event automation.""" + import pytest import homeassistant.components.automation as automation diff --git a/tests/components/homekit/test_aidmanager.py b/tests/components/homekit/test_aidmanager.py index 64c5cd9cc74..9cd618e307c 100644 --- a/tests/components/homekit/test_aidmanager.py +++ b/tests/components/homekit/test_aidmanager.py @@ -1,4 +1,5 @@ """Tests for the HomeKit AID manager.""" + import os from unittest.mock import patch diff --git a/tests/components/homekit/test_type_cameras.py b/tests/components/homekit/test_type_cameras.py index db2e6c6e8ea..34770428d89 100644 --- a/tests/components/homekit/test_type_cameras.py +++ b/tests/components/homekit/test_type_cameras.py @@ -1,4 +1,5 @@ """Test different accessory types: Camera.""" + import asyncio from unittest.mock import AsyncMock, MagicMock, PropertyMock, patch from uuid import UUID diff --git a/tests/components/homekit/test_type_locks.py b/tests/components/homekit/test_type_locks.py index 3a9f7d93d88..4d83fe41f48 100644 --- a/tests/components/homekit/test_type_locks.py +++ b/tests/components/homekit/test_type_locks.py @@ -1,4 +1,5 @@ """Test different accessory types: Locks.""" + import pytest from homeassistant.components.homekit.const import ATTR_VALUE diff --git a/tests/components/homekit/test_type_media_players.py b/tests/components/homekit/test_type_media_players.py index 33eb1e6c4ee..b17f16231af 100644 --- a/tests/components/homekit/test_type_media_players.py +++ b/tests/components/homekit/test_type_media_players.py @@ -1,4 +1,5 @@ """Test different accessory types: Media Players.""" + import pytest from homeassistant.components.homekit.accessories import HomeDriver diff --git a/tests/components/homekit_controller/conftest.py b/tests/components/homekit_controller/conftest.py index 904b752205e..ae2ca721cfa 100644 --- a/tests/components/homekit_controller/conftest.py +++ b/tests/components/homekit_controller/conftest.py @@ -1,4 +1,5 @@ """HomeKit controller session fixtures.""" + import datetime import unittest.mock diff --git a/tests/components/homekit_controller/test_camera.py b/tests/components/homekit_controller/test_camera.py index f74f2e62772..de64ee95d74 100644 --- a/tests/components/homekit_controller/test_camera.py +++ b/tests/components/homekit_controller/test_camera.py @@ -1,4 +1,5 @@ """Basic checks for HomeKit cameras.""" + import base64 from aiohomekit.model.services import ServicesTypes diff --git a/tests/components/homekit_controller/test_config_flow.py b/tests/components/homekit_controller/test_config_flow.py index 2b375566b5b..6b658e9eef4 100644 --- a/tests/components/homekit_controller/test_config_flow.py +++ b/tests/components/homekit_controller/test_config_flow.py @@ -1,4 +1,5 @@ """Tests for homekit_controller config flow.""" + import asyncio from ipaddress import ip_address import unittest.mock diff --git a/tests/components/homematic/test_notify.py b/tests/components/homematic/test_notify.py index bccf5884d35..33c9b0f359e 100644 --- a/tests/components/homematic/test_notify.py +++ b/tests/components/homematic/test_notify.py @@ -1,4 +1,5 @@ """The tests for the Homematic notification platform.""" + import homeassistant.components.notify as notify_comp from homeassistant.core import HomeAssistant from homeassistant.setup import async_setup_component diff --git a/tests/components/homematicip_cloud/helper.py b/tests/components/homematicip_cloud/helper.py index 7b4071e9808..d073cfc4e3d 100644 --- a/tests/components/homematicip_cloud/helper.py +++ b/tests/components/homematicip_cloud/helper.py @@ -1,4 +1,5 @@ """Helper for HomematicIP Cloud Tests.""" + import json from unittest.mock import Mock, patch diff --git a/tests/components/homematicip_cloud/test_climate.py b/tests/components/homematicip_cloud/test_climate.py index 20193d91239..9ede89859dc 100644 --- a/tests/components/homematicip_cloud/test_climate.py +++ b/tests/components/homematicip_cloud/test_climate.py @@ -1,4 +1,5 @@ """Tests for HomematicIP Cloud climate.""" + import datetime from homematicip.base.enums import AbsenceType diff --git a/tests/components/honeywell/test_climate.py b/tests/components/honeywell/test_climate.py index 743689da43d..751ba8aa288 100644 --- a/tests/components/honeywell/test_climate.py +++ b/tests/components/honeywell/test_climate.py @@ -1,4 +1,5 @@ """Test the Whirlpool Sixth Sense climate domain.""" + import datetime from unittest.mock import MagicMock diff --git a/tests/components/http/conftest.py b/tests/components/http/conftest.py index ed2c78bafd7..60b1b73ff83 100644 --- a/tests/components/http/conftest.py +++ b/tests/components/http/conftest.py @@ -1,4 +1,5 @@ """Test configuration for http.""" + import pytest diff --git a/tests/components/http/test_init.py b/tests/components/http/test_init.py index a1be00e3a2b..4ed2e56f1a5 100644 --- a/tests/components/http/test_init.py +++ b/tests/components/http/test_init.py @@ -1,4 +1,5 @@ """The tests for the Home Assistant HTTP component.""" + import asyncio from datetime import timedelta from http import HTTPStatus diff --git a/tests/components/http/test_security_filter.py b/tests/components/http/test_security_filter.py index 0cd85b48b06..c5b928b426f 100644 --- a/tests/components/http/test_security_filter.py +++ b/tests/components/http/test_security_filter.py @@ -1,4 +1,5 @@ """Test security filter middleware.""" + import asyncio from http import HTTPStatus diff --git a/tests/components/hue/conftest.py b/tests/components/hue/conftest.py index 3350ea15185..f87faf6294b 100644 --- a/tests/components/hue/conftest.py +++ b/tests/components/hue/conftest.py @@ -1,4 +1,5 @@ """Test helpers for Hue.""" + import asyncio from collections import deque import json diff --git a/tests/components/hue/test_bridge.py b/tests/components/hue/test_bridge.py index 5c27b532570..946240116d8 100644 --- a/tests/components/hue/test_bridge.py +++ b/tests/components/hue/test_bridge.py @@ -1,4 +1,5 @@ """Test Hue bridge.""" + import asyncio from unittest.mock import patch diff --git a/tests/components/humidifier/test_device_action.py b/tests/components/humidifier/test_device_action.py index ff508bd3a67..e8ac6006451 100644 --- a/tests/components/humidifier/test_device_action.py +++ b/tests/components/humidifier/test_device_action.py @@ -1,4 +1,5 @@ """The tests for Humidifier device actions.""" + import pytest from pytest_unordered import unordered import voluptuous_serialize diff --git a/tests/components/humidifier/test_device_condition.py b/tests/components/humidifier/test_device_condition.py index 224c69b9fb5..7864a119393 100644 --- a/tests/components/humidifier/test_device_condition.py +++ b/tests/components/humidifier/test_device_condition.py @@ -1,4 +1,5 @@ """The tests for Humidifier device conditions.""" + import pytest from pytest_unordered import unordered import voluptuous_serialize diff --git a/tests/components/humidifier/test_device_trigger.py b/tests/components/humidifier/test_device_trigger.py index 34067d96ff2..f6fcd450768 100644 --- a/tests/components/humidifier/test_device_trigger.py +++ b/tests/components/humidifier/test_device_trigger.py @@ -1,4 +1,5 @@ """The tests for Humidifier device triggers.""" + import datetime import pytest diff --git a/tests/components/humidifier/test_intent.py b/tests/components/humidifier/test_intent.py index d8c9f199f57..20e23b14605 100644 --- a/tests/components/humidifier/test_intent.py +++ b/tests/components/humidifier/test_intent.py @@ -1,4 +1,5 @@ """Tests for the humidifier intents.""" + import pytest from homeassistant.components.humidifier import ( diff --git a/tests/components/humidifier/test_reproduce_state.py b/tests/components/humidifier/test_reproduce_state.py index cedb0284104..cab3a11e609 100644 --- a/tests/components/humidifier/test_reproduce_state.py +++ b/tests/components/humidifier/test_reproduce_state.py @@ -1,4 +1,5 @@ """The tests for reproduction of state.""" + import pytest from homeassistant.components.humidifier.const import ( diff --git a/tests/components/humidifier/test_significant_change.py b/tests/components/humidifier/test_significant_change.py index 3d1b2a7e1ab..93e22d7ddaa 100644 --- a/tests/components/humidifier/test_significant_change.py +++ b/tests/components/humidifier/test_significant_change.py @@ -1,4 +1,5 @@ """Test the Humidifier significant change platform.""" + import pytest from homeassistant.components.humidifier import ( diff --git a/tests/components/hvv_departures/test_config_flow.py b/tests/components/hvv_departures/test_config_flow.py index 0d885febb3c..11e5da00d11 100644 --- a/tests/components/hvv_departures/test_config_flow.py +++ b/tests/components/hvv_departures/test_config_flow.py @@ -1,4 +1,5 @@ """Test the HVV Departures config flow.""" + import json from unittest.mock import patch diff --git a/tests/components/iaqualink/conftest.py b/tests/components/iaqualink/conftest.py index b4db99dbe40..c7e7373f4c2 100644 --- a/tests/components/iaqualink/conftest.py +++ b/tests/components/iaqualink/conftest.py @@ -1,4 +1,5 @@ """Configuration for iAqualink tests.""" + import random from unittest.mock import AsyncMock, PropertyMock, patch diff --git a/tests/components/iaqualink/test_init.py b/tests/components/iaqualink/test_init.py index a1e3ee6ac35..8c64b1072d6 100644 --- a/tests/components/iaqualink/test_init.py +++ b/tests/components/iaqualink/test_init.py @@ -1,4 +1,5 @@ """Tests for iAqualink integration.""" + import logging from unittest.mock import AsyncMock, patch diff --git a/tests/components/ibeacon/test_init.py b/tests/components/ibeacon/test_init.py index b29cc3a4b2e..99c45b3dfe7 100644 --- a/tests/components/ibeacon/test_init.py +++ b/tests/components/ibeacon/test_init.py @@ -1,4 +1,5 @@ """Test the ibeacon init.""" + import pytest from homeassistant.components.ibeacon.const import DOMAIN diff --git a/tests/components/ign_sismologia/test_geo_location.py b/tests/components/ign_sismologia/test_geo_location.py index fd3c34a506c..d208a1d42ae 100644 --- a/tests/components/ign_sismologia/test_geo_location.py +++ b/tests/components/ign_sismologia/test_geo_location.py @@ -1,4 +1,5 @@ """The tests for the IGN Sismologia (Earthquakes) Feed platform.""" + import datetime from unittest.mock import MagicMock, call, patch diff --git a/tests/components/image/test_init.py b/tests/components/image/test_init.py index e68a58d7298..e407b142c52 100644 --- a/tests/components/image/test_init.py +++ b/tests/components/image/test_init.py @@ -1,4 +1,5 @@ """The tests for the image component.""" + import datetime from http import HTTPStatus import ssl diff --git a/tests/components/image_upload/test_init.py b/tests/components/image_upload/test_init.py index 9f842d25b64..394c0672485 100644 --- a/tests/components/image_upload/test_init.py +++ b/tests/components/image_upload/test_init.py @@ -1,4 +1,5 @@ """Test that we can upload images.""" + import pathlib import tempfile from unittest.mock import patch diff --git a/tests/components/imap/test_config_flow.py b/tests/components/imap/test_config_flow.py index 177aba04950..9d9edae5b14 100644 --- a/tests/components/imap/test_config_flow.py +++ b/tests/components/imap/test_config_flow.py @@ -1,4 +1,5 @@ """Test the imap config flow.""" + import ssl from unittest.mock import AsyncMock, patch diff --git a/tests/components/imap/test_init.py b/tests/components/imap/test_init.py index 9c194bf08a0..8608963413a 100644 --- a/tests/components/imap/test_init.py +++ b/tests/components/imap/test_init.py @@ -1,4 +1,5 @@ """Test the imap entry initialization.""" + import asyncio from datetime import datetime, timedelta, timezone from typing import Any diff --git a/tests/components/input_boolean/test_init.py b/tests/components/input_boolean/test_init.py index 65d7fb93d19..2a616691e62 100644 --- a/tests/components/input_boolean/test_init.py +++ b/tests/components/input_boolean/test_init.py @@ -1,4 +1,5 @@ """The tests for the input_boolean component.""" + import logging from unittest.mock import patch diff --git a/tests/components/input_button/test_init.py b/tests/components/input_button/test_init.py index 2f9b677e134..568d0076318 100644 --- a/tests/components/input_button/test_init.py +++ b/tests/components/input_button/test_init.py @@ -1,4 +1,5 @@ """The tests for the input_test component.""" + import logging from unittest.mock import patch diff --git a/tests/components/input_datetime/test_init.py b/tests/components/input_datetime/test_init.py index 0a3f9b3ed6c..9d218e6d6ec 100644 --- a/tests/components/input_datetime/test_init.py +++ b/tests/components/input_datetime/test_init.py @@ -1,4 +1,5 @@ """Tests for the Input slider component.""" + import datetime from unittest.mock import patch diff --git a/tests/components/input_datetime/test_reproduce_state.py b/tests/components/input_datetime/test_reproduce_state.py index b5f75b81068..323849bc882 100644 --- a/tests/components/input_datetime/test_reproduce_state.py +++ b/tests/components/input_datetime/test_reproduce_state.py @@ -1,4 +1,5 @@ """Test reproduce state for Input datetime.""" + import pytest from homeassistant.core import HomeAssistant, State diff --git a/tests/components/input_number/test_reproduce_state.py b/tests/components/input_number/test_reproduce_state.py index 087b2fe1001..6c8c61a0b58 100644 --- a/tests/components/input_number/test_reproduce_state.py +++ b/tests/components/input_number/test_reproduce_state.py @@ -1,4 +1,5 @@ """Test reproduce state for Input number.""" + import pytest from homeassistant.core import HomeAssistant, State diff --git a/tests/components/input_select/test_reproduce_state.py b/tests/components/input_select/test_reproduce_state.py index a00b6b02ade..13672ebc708 100644 --- a/tests/components/input_select/test_reproduce_state.py +++ b/tests/components/input_select/test_reproduce_state.py @@ -1,4 +1,5 @@ """Test reproduce state for Input select.""" + import pytest from homeassistant.core import HomeAssistant, State diff --git a/tests/components/input_text/test_reproduce_state.py b/tests/components/input_text/test_reproduce_state.py index 877a784853a..88b8131000b 100644 --- a/tests/components/input_text/test_reproduce_state.py +++ b/tests/components/input_text/test_reproduce_state.py @@ -1,4 +1,5 @@ """Test reproduce state for Input text.""" + import pytest from homeassistant.core import HomeAssistant, State diff --git a/tests/components/insteon/test_api_aldb.py b/tests/components/insteon/test_api_aldb.py index 4bd299d3d05..4e0df12c6f1 100644 --- a/tests/components/insteon/test_api_aldb.py +++ b/tests/components/insteon/test_api_aldb.py @@ -1,4 +1,5 @@ """Test the Insteon All-Link Database APIs.""" + import json from unittest.mock import patch diff --git a/tests/components/insteon/test_api_device.py b/tests/components/insteon/test_api_device.py index 7485914026a..f3c67d479d0 100644 --- a/tests/components/insteon/test_api_device.py +++ b/tests/components/insteon/test_api_device.py @@ -1,4 +1,5 @@ """Test the device level APIs.""" + import asyncio from unittest.mock import patch diff --git a/tests/components/insteon/test_api_properties.py b/tests/components/insteon/test_api_properties.py index 850ccc85411..d2a388929b5 100644 --- a/tests/components/insteon/test_api_properties.py +++ b/tests/components/insteon/test_api_properties.py @@ -1,4 +1,5 @@ """Test the Insteon properties APIs.""" + import json from unittest.mock import AsyncMock, patch diff --git a/tests/components/insteon/test_api_scenes.py b/tests/components/insteon/test_api_scenes.py index cc9b11f4632..aa4eb774229 100644 --- a/tests/components/insteon/test_api_scenes.py +++ b/tests/components/insteon/test_api_scenes.py @@ -1,4 +1,5 @@ """Test the Insteon Scenes APIs.""" + import json import os from unittest.mock import AsyncMock, patch diff --git a/tests/components/insteon/test_init.py b/tests/components/insteon/test_init.py index f772eed2d26..bfc8a8b8cc1 100644 --- a/tests/components/insteon/test_init.py +++ b/tests/components/insteon/test_init.py @@ -1,4 +1,5 @@ """Test the init file for the Insteon component.""" + import asyncio from unittest.mock import patch diff --git a/tests/components/integration/test_init.py b/tests/components/integration/test_init.py index 885c10277f8..9f9decaef45 100644 --- a/tests/components/integration/test_init.py +++ b/tests/components/integration/test_init.py @@ -1,4 +1,5 @@ """Test the Integration - Riemann sum integral integration.""" + import pytest from homeassistant.components.integration.const import DOMAIN diff --git a/tests/components/iotawatt/test_init.py b/tests/components/iotawatt/test_init.py index cdf58a0a2d2..c185fec0e4d 100644 --- a/tests/components/iotawatt/test_init.py +++ b/tests/components/iotawatt/test_init.py @@ -1,4 +1,5 @@ """Test init.""" + import httpx from homeassistant.config_entries import ConfigEntryState diff --git a/tests/components/ipma/test_system_health.py b/tests/components/ipma/test_system_health.py index b4cefad80c0..5d532611969 100644 --- a/tests/components/ipma/test_system_health.py +++ b/tests/components/ipma/test_system_health.py @@ -1,4 +1,5 @@ """Test ipma system health.""" + import asyncio from homeassistant.components.ipma.system_health import IPMA_API_URL diff --git a/tests/components/ipma/test_weather.py b/tests/components/ipma/test_weather.py index 9e0262733a3..06f15922a2e 100644 --- a/tests/components/ipma/test_weather.py +++ b/tests/components/ipma/test_weather.py @@ -1,4 +1,5 @@ """The tests for the IPMA weather component.""" + import datetime from unittest.mock import patch diff --git a/tests/components/ipp/test_config_flow.py b/tests/components/ipp/test_config_flow.py index 5dd6c1af5bf..1ea75ecf167 100644 --- a/tests/components/ipp/test_config_flow.py +++ b/tests/components/ipp/test_config_flow.py @@ -1,4 +1,5 @@ """Tests for the IPP config flow.""" + import dataclasses from ipaddress import ip_address import json diff --git a/tests/components/iqvia/conftest.py b/tests/components/iqvia/conftest.py index b24d473c7df..c1d0341aaa6 100644 --- a/tests/components/iqvia/conftest.py +++ b/tests/components/iqvia/conftest.py @@ -1,4 +1,5 @@ """Define test fixtures for IQVIA.""" + import json from unittest.mock import patch diff --git a/tests/components/isy994/test_config_flow.py b/tests/components/isy994/test_config_flow.py index 4a5bfb007f0..e20c4f0b185 100644 --- a/tests/components/isy994/test_config_flow.py +++ b/tests/components/isy994/test_config_flow.py @@ -1,4 +1,5 @@ """Test the Universal Devices ISY/IoX config flow.""" + import re from unittest.mock import patch diff --git a/tests/components/isy994/test_system_health.py b/tests/components/isy994/test_system_health.py index fa5bab0025c..5f472189513 100644 --- a/tests/components/isy994/test_system_health.py +++ b/tests/components/isy994/test_system_health.py @@ -1,4 +1,5 @@ """Test ISY system health.""" + import asyncio from unittest.mock import Mock diff --git a/tests/components/kira/test_init.py b/tests/components/kira/test_init.py index 50c2f4f4651..6b6ad4c1fcf 100644 --- a/tests/components/kira/test_init.py +++ b/tests/components/kira/test_init.py @@ -1,4 +1,5 @@ """The tests for Kira.""" + import os import shutil import tempfile diff --git a/tests/components/kitchen_sink/test_init.py b/tests/components/kitchen_sink/test_init.py index fb81c87008e..1547a10bd2b 100644 --- a/tests/components/kitchen_sink/test_init.py +++ b/tests/components/kitchen_sink/test_init.py @@ -1,4 +1,5 @@ """The tests for the Everything but the Kitchen Sink integration.""" + import datetime from http import HTTPStatus from unittest.mock import ANY diff --git a/tests/components/knx/test_device_trigger.py b/tests/components/knx/test_device_trigger.py index f3448947cf8..3c8bf58169b 100644 --- a/tests/components/knx/test_device_trigger.py +++ b/tests/components/knx/test_device_trigger.py @@ -1,4 +1,5 @@ """Tests for KNX device triggers.""" + import pytest import voluptuous_serialize diff --git a/tests/components/knx/test_events.py b/tests/components/knx/test_events.py index f5c1aed7fde..ddb9d50240c 100644 --- a/tests/components/knx/test_events.py +++ b/tests/components/knx/test_events.py @@ -1,4 +1,5 @@ """Test KNX events.""" + import logging import pytest diff --git a/tests/components/knx/test_number.py b/tests/components/knx/test_number.py index a0ef514f5f7..be3fe070c10 100644 --- a/tests/components/knx/test_number.py +++ b/tests/components/knx/test_number.py @@ -1,4 +1,5 @@ """Test KNX number.""" + import pytest from homeassistant.components.knx.const import CONF_RESPOND_TO_READ, KNX_ADDRESS diff --git a/tests/components/knx/test_select.py b/tests/components/knx/test_select.py index 1b408a298a2..b53dfae2658 100644 --- a/tests/components/knx/test_select.py +++ b/tests/components/knx/test_select.py @@ -1,4 +1,5 @@ """Test KNX select.""" + import pytest from homeassistant.components.knx.const import ( diff --git a/tests/components/kodi/test_device_trigger.py b/tests/components/kodi/test_device_trigger.py index 4dbfe3abb57..1737fe5d7c9 100644 --- a/tests/components/kodi/test_device_trigger.py +++ b/tests/components/kodi/test_device_trigger.py @@ -1,4 +1,5 @@ """The tests for Kodi device triggers.""" + import pytest import homeassistant.components.automation as automation diff --git a/tests/components/kraken/const.py b/tests/components/kraken/const.py index 263618dfd2d..9afd2d84007 100644 --- a/tests/components/kraken/const.py +++ b/tests/components/kraken/const.py @@ -1,4 +1,5 @@ """Constants for kraken tests.""" + import pandas as pd TRADEABLE_ASSET_PAIR_RESPONSE = pd.DataFrame( diff --git a/tests/components/lametric/test_sensor.py b/tests/components/lametric/test_sensor.py index 743ed0e8bde..bb15ebd5aa4 100644 --- a/tests/components/lametric/test_sensor.py +++ b/tests/components/lametric/test_sensor.py @@ -1,4 +1,5 @@ """Tests for the LaMetric sensor platform.""" + import pytest from homeassistant.components.lametric.const import DOMAIN diff --git a/tests/components/landisgyr_heat_meter/test_sensor.py b/tests/components/landisgyr_heat_meter/test_sensor.py index f05d12e49a2..1578c67432d 100644 --- a/tests/components/landisgyr_heat_meter/test_sensor.py +++ b/tests/components/landisgyr_heat_meter/test_sensor.py @@ -1,4 +1,5 @@ """The tests for the Landis+Gyr Heat Meter sensor platform.""" + import datetime from unittest.mock import patch diff --git a/tests/components/laundrify/conftest.py b/tests/components/laundrify/conftest.py index 13e408b61a9..18884cdfb7b 100644 --- a/tests/components/laundrify/conftest.py +++ b/tests/components/laundrify/conftest.py @@ -1,4 +1,5 @@ """Configure py.test.""" + import json from unittest.mock import patch diff --git a/tests/components/lcn/conftest.py b/tests/components/lcn/conftest.py index a6bcdf63950..2e50f20561e 100644 --- a/tests/components/lcn/conftest.py +++ b/tests/components/lcn/conftest.py @@ -1,4 +1,5 @@ """Test configuration and mocks for LCN component.""" + import json from unittest.mock import AsyncMock, patch diff --git a/tests/components/light/test_device_action.py b/tests/components/light/test_device_action.py index 3b60b886b02..6fd83d9c29a 100644 --- a/tests/components/light/test_device_action.py +++ b/tests/components/light/test_device_action.py @@ -1,4 +1,5 @@ """The test for light device automation.""" + import pytest from pytest_unordered import unordered diff --git a/tests/components/light/test_reproduce_state.py b/tests/components/light/test_reproduce_state.py index 65b83aa0269..ed02ad891e2 100644 --- a/tests/components/light/test_reproduce_state.py +++ b/tests/components/light/test_reproduce_state.py @@ -1,4 +1,5 @@ """Test reproduce state for Light.""" + import pytest from homeassistant.components import light diff --git a/tests/components/lock/test_device_action.py b/tests/components/lock/test_device_action.py index 1e451920baf..0356bc206cc 100644 --- a/tests/components/lock/test_device_action.py +++ b/tests/components/lock/test_device_action.py @@ -1,4 +1,5 @@ """The tests for Lock device actions.""" + import pytest from pytest_unordered import unordered diff --git a/tests/components/lock/test_device_condition.py b/tests/components/lock/test_device_condition.py index 59dcbcb4629..31aa9aab143 100644 --- a/tests/components/lock/test_device_condition.py +++ b/tests/components/lock/test_device_condition.py @@ -1,4 +1,5 @@ """The tests for Lock device conditions.""" + import pytest from pytest_unordered import unordered diff --git a/tests/components/lock/test_reproduce_state.py b/tests/components/lock/test_reproduce_state.py index 4f3c94f0b90..4fa06d9320b 100644 --- a/tests/components/lock/test_reproduce_state.py +++ b/tests/components/lock/test_reproduce_state.py @@ -1,4 +1,5 @@ """Test reproduce state for Lock.""" + import pytest from homeassistant.core import HomeAssistant, State diff --git a/tests/components/logbook/test_init.py b/tests/components/logbook/test_init.py index 803aaba346a..732437107de 100644 --- a/tests/components/logbook/test_init.py +++ b/tests/components/logbook/test_init.py @@ -1,4 +1,5 @@ """The tests for the logbook component.""" + import asyncio import collections from collections.abc import Callable diff --git a/tests/components/logbook/test_websocket_api.py b/tests/components/logbook/test_websocket_api.py index 7100f914ff4..d17ed34cda4 100644 --- a/tests/components/logbook/test_websocket_api.py +++ b/tests/components/logbook/test_websocket_api.py @@ -1,4 +1,5 @@ """The tests for the logbook component.""" + import asyncio from collections.abc import Callable from datetime import timedelta diff --git a/tests/components/logger/conftest.py b/tests/components/logger/conftest.py index 00d27753a61..76fbde68e78 100644 --- a/tests/components/logger/conftest.py +++ b/tests/components/logger/conftest.py @@ -1,4 +1,5 @@ """Test fixtures for the Logger component.""" + import logging import pytest diff --git a/tests/components/logger/test_websocket_api.py b/tests/components/logger/test_websocket_api.py index 10c1ceb2f20..15252ad2661 100644 --- a/tests/components/logger/test_websocket_api.py +++ b/tests/components/logger/test_websocket_api.py @@ -1,4 +1,5 @@ """Tests for Logger Websocket API commands.""" + import logging from unittest.mock import patch diff --git a/tests/components/logi_circle/test_config_flow.py b/tests/components/logi_circle/test_config_flow.py index 2c1642aefba..f0de828c186 100644 --- a/tests/components/logi_circle/test_config_flow.py +++ b/tests/components/logi_circle/test_config_flow.py @@ -1,4 +1,5 @@ """Tests for Logi Circle config flow.""" + import asyncio from http import HTTPStatus from unittest.mock import AsyncMock, Mock, patch diff --git a/tests/components/lovelace/test_resources.py b/tests/components/lovelace/test_resources.py index 4a280eccfda..7591960b589 100644 --- a/tests/components/lovelace/test_resources.py +++ b/tests/components/lovelace/test_resources.py @@ -1,4 +1,5 @@ """Test Lovelace resources.""" + import copy from typing import Any from unittest.mock import patch diff --git a/tests/components/mailgun/test_init.py b/tests/components/mailgun/test_init.py index 03bbfd80287..a36051bd102 100644 --- a/tests/components/mailgun/test_init.py +++ b/tests/components/mailgun/test_init.py @@ -1,4 +1,5 @@ """Test the init file of Mailgun.""" + import hashlib import hmac diff --git a/tests/components/media_extractor/test_init.py b/tests/components/media_extractor/test_init.py index d32ad90d87c..4a979b6aec6 100644 --- a/tests/components/media_extractor/test_init.py +++ b/tests/components/media_extractor/test_init.py @@ -1,4 +1,5 @@ """The tests for Media Extractor integration.""" + import os import os.path from typing import Any diff --git a/tests/components/media_player/test_async_helpers.py b/tests/components/media_player/test_async_helpers.py index f3b70187f33..e3d89a9ca2e 100644 --- a/tests/components/media_player/test_async_helpers.py +++ b/tests/components/media_player/test_async_helpers.py @@ -1,4 +1,5 @@ """The tests for the Async Media player helper functions.""" + import pytest import homeassistant.components.media_player as mp diff --git a/tests/components/media_player/test_device_condition.py b/tests/components/media_player/test_device_condition.py index ea1f65eab95..8e085152954 100644 --- a/tests/components/media_player/test_device_condition.py +++ b/tests/components/media_player/test_device_condition.py @@ -1,4 +1,5 @@ """The tests for Media player device conditions.""" + import pytest from pytest_unordered import unordered diff --git a/tests/components/media_player/test_reproduce_state.py b/tests/components/media_player/test_reproduce_state.py index 0ff930dbdbd..0759296ce35 100644 --- a/tests/components/media_player/test_reproduce_state.py +++ b/tests/components/media_player/test_reproduce_state.py @@ -1,4 +1,5 @@ """The tests for reproduction of state.""" + import pytest from homeassistant.components.media_player import ( diff --git a/tests/components/media_player/test_significant_change.py b/tests/components/media_player/test_significant_change.py index 233f133c342..e0635391042 100644 --- a/tests/components/media_player/test_significant_change.py +++ b/tests/components/media_player/test_significant_change.py @@ -1,4 +1,5 @@ """Test the Media Player significant change platform.""" + import pytest from homeassistant.components.media_player import ( diff --git a/tests/components/melissa/test_climate.py b/tests/components/melissa/test_climate.py index dc2ca4391f1..7903744ff13 100644 --- a/tests/components/melissa/test_climate.py +++ b/tests/components/melissa/test_climate.py @@ -1,4 +1,5 @@ """Test for Melissa climate component.""" + import json from unittest.mock import AsyncMock, Mock, patch diff --git a/tests/components/met/test_init.py b/tests/components/met/test_init.py index 0e4e46b09da..b329e2ff01c 100644 --- a/tests/components/met/test_init.py +++ b/tests/components/met/test_init.py @@ -1,4 +1,5 @@ """Test the Met integration init.""" + import pytest from homeassistant.components.met.const import ( diff --git a/tests/components/met_eireann/test_weather.py b/tests/components/met_eireann/test_weather.py index e5c2c66b626..1c938f97574 100644 --- a/tests/components/met_eireann/test_weather.py +++ b/tests/components/met_eireann/test_weather.py @@ -1,4 +1,5 @@ """Test Met Éireann weather entity.""" + import datetime from freezegun.api import FrozenDateTimeFactory diff --git a/tests/components/metoffice/test_config_flow.py b/tests/components/metoffice/test_config_flow.py index 020f5ff154b..d5749dad035 100644 --- a/tests/components/metoffice/test_config_flow.py +++ b/tests/components/metoffice/test_config_flow.py @@ -1,4 +1,5 @@ """Test the National Weather Service (NWS) config flow.""" + import json from unittest.mock import patch diff --git a/tests/components/metoffice/test_sensor.py b/tests/components/metoffice/test_sensor.py index 6e40dd66efe..87d3f66aeb5 100644 --- a/tests/components/metoffice/test_sensor.py +++ b/tests/components/metoffice/test_sensor.py @@ -1,4 +1,5 @@ """The tests for the Met Office sensor component.""" + import datetime import json diff --git a/tests/components/metoffice/test_weather.py b/tests/components/metoffice/test_weather.py index 19c27873d5e..85d66bf7686 100644 --- a/tests/components/metoffice/test_weather.py +++ b/tests/components/metoffice/test_weather.py @@ -1,4 +1,5 @@ """The tests for the Met Office sensor component.""" + import datetime from datetime import timedelta import json diff --git a/tests/components/mfi/test_switch.py b/tests/components/mfi/test_switch.py index 00daa4c353d..fb4e42fb137 100644 --- a/tests/components/mfi/test_switch.py +++ b/tests/components/mfi/test_switch.py @@ -1,4 +1,5 @@ """The tests for the mFi switch platform.""" + import unittest.mock as mock import pytest diff --git a/tests/components/microbees/conftest.py b/tests/components/microbees/conftest.py index a27d1e01194..e89d4780ad9 100644 --- a/tests/components/microbees/conftest.py +++ b/tests/components/microbees/conftest.py @@ -1,4 +1,5 @@ """Conftest for microBees tests.""" + import time from unittest.mock import AsyncMock, patch diff --git a/tests/components/min_max/test_init.py b/tests/components/min_max/test_init.py index cd07f7060f6..f6c67e60326 100644 --- a/tests/components/min_max/test_init.py +++ b/tests/components/min_max/test_init.py @@ -1,4 +1,5 @@ """Test the Min/Max integration.""" + import pytest from homeassistant.components.min_max.const import DOMAIN diff --git a/tests/components/min_max/test_sensor.py b/tests/components/min_max/test_sensor.py index acd42f9355e..4d86ee72cc6 100644 --- a/tests/components/min_max/test_sensor.py +++ b/tests/components/min_max/test_sensor.py @@ -1,4 +1,5 @@ """The test for the min/max sensor platform.""" + import statistics from unittest.mock import patch diff --git a/tests/components/minecraft_server/conftest.py b/tests/components/minecraft_server/conftest.py index b118b15d08a..ef8a9d960f6 100644 --- a/tests/components/minecraft_server/conftest.py +++ b/tests/components/minecraft_server/conftest.py @@ -1,4 +1,5 @@ """Fixtures for Minecraft Server integration tests.""" + import pytest from homeassistant.components.minecraft_server.api import MinecraftServerType diff --git a/tests/components/minio/test_minio.py b/tests/components/minio/test_minio.py index 7455ede2994..746085fafc2 100644 --- a/tests/components/minio/test_minio.py +++ b/tests/components/minio/test_minio.py @@ -1,4 +1,5 @@ """Tests for Minio Hass related code.""" + import asyncio import json from unittest.mock import MagicMock, call, patch diff --git a/tests/components/mochad/test_light.py b/tests/components/mochad/test_light.py index 8bd4e1e2a59..b04f9a13933 100644 --- a/tests/components/mochad/test_light.py +++ b/tests/components/mochad/test_light.py @@ -1,4 +1,5 @@ """The tests for the mochad light platform.""" + import unittest.mock as mock import pytest diff --git a/tests/components/mochad/test_switch.py b/tests/components/mochad/test_switch.py index 9780ac3a481..e89a9ec6269 100644 --- a/tests/components/mochad/test_switch.py +++ b/tests/components/mochad/test_switch.py @@ -1,4 +1,5 @@ """The tests for the mochad switch platform.""" + import unittest.mock as mock import pytest diff --git a/tests/components/modbus/conftest.py b/tests/components/modbus/conftest.py index d7e4556f746..4fdda5d9aea 100644 --- a/tests/components/modbus/conftest.py +++ b/tests/components/modbus/conftest.py @@ -1,4 +1,5 @@ """The tests for the Modbus sensor component.""" + import copy from dataclasses import dataclass from datetime import timedelta diff --git a/tests/components/modbus/test_binary_sensor.py b/tests/components/modbus/test_binary_sensor.py index e47a6165b30..567618de3c6 100644 --- a/tests/components/modbus/test_binary_sensor.py +++ b/tests/components/modbus/test_binary_sensor.py @@ -1,4 +1,5 @@ """Thetests for the Modbus sensor component.""" + import pytest from homeassistant.components.binary_sensor import DOMAIN as SENSOR_DOMAIN diff --git a/tests/components/modbus/test_climate.py b/tests/components/modbus/test_climate.py index 47d468ee1d8..3752358c071 100644 --- a/tests/components/modbus/test_climate.py +++ b/tests/components/modbus/test_climate.py @@ -1,4 +1,5 @@ """The tests for the Modbus climate component.""" + import pytest from homeassistant.components.climate import DOMAIN as CLIMATE_DOMAIN diff --git a/tests/components/modbus/test_sensor.py b/tests/components/modbus/test_sensor.py index aa8b15585dc..1c6b332d391 100644 --- a/tests/components/modbus/test_sensor.py +++ b/tests/components/modbus/test_sensor.py @@ -1,4 +1,5 @@ """The tests for the Modbus sensor component.""" + import struct import pytest diff --git a/tests/components/mold_indicator/test_sensor.py b/tests/components/mold_indicator/test_sensor.py index bfea5bccde4..0acea3d03e6 100644 --- a/tests/components/mold_indicator/test_sensor.py +++ b/tests/components/mold_indicator/test_sensor.py @@ -1,4 +1,5 @@ """The tests for the MoldIndicator sensor.""" + import pytest from homeassistant.components.mold_indicator.sensor import ( diff --git a/tests/components/motion_blinds/test_config_flow.py b/tests/components/motion_blinds/test_config_flow.py index 43051e88562..5ffb0b356ad 100644 --- a/tests/components/motion_blinds/test_config_flow.py +++ b/tests/components/motion_blinds/test_config_flow.py @@ -1,4 +1,5 @@ """Test the Motionblinds config flow.""" + import socket from unittest.mock import Mock, patch diff --git a/tests/components/motioneye/test_camera.py b/tests/components/motioneye/test_camera.py index 5af8d4139eb..32763fbed3a 100644 --- a/tests/components/motioneye/test_camera.py +++ b/tests/components/motioneye/test_camera.py @@ -1,4 +1,5 @@ """Test the motionEye camera.""" + import copy from typing import Any, cast from unittest.mock import AsyncMock, Mock, call diff --git a/tests/components/motioneye/test_media_source.py b/tests/components/motioneye/test_media_source.py index 6b90870c4da..f895ed7fcb2 100644 --- a/tests/components/motioneye/test_media_source.py +++ b/tests/components/motioneye/test_media_source.py @@ -1,4 +1,5 @@ """Test Local Media Source.""" + import logging from unittest.mock import AsyncMock, Mock, call diff --git a/tests/components/motioneye/test_sensor.py b/tests/components/motioneye/test_sensor.py index 0892c0dead0..02e34c16c30 100644 --- a/tests/components/motioneye/test_sensor.py +++ b/tests/components/motioneye/test_sensor.py @@ -1,4 +1,5 @@ """Tests for the motionEye switch platform.""" + import copy from datetime import timedelta from unittest.mock import AsyncMock, patch diff --git a/tests/components/motioneye/test_switch.py b/tests/components/motioneye/test_switch.py index a6fbcc49052..56401e7a28d 100644 --- a/tests/components/motioneye/test_switch.py +++ b/tests/components/motioneye/test_switch.py @@ -1,4 +1,5 @@ """Tests for the motionEye switch platform.""" + import copy from datetime import timedelta from unittest.mock import AsyncMock, call, patch diff --git a/tests/components/motioneye/test_web_hooks.py b/tests/components/motioneye/test_web_hooks.py index 7c66645bb44..a828e5964d0 100644 --- a/tests/components/motioneye/test_web_hooks.py +++ b/tests/components/motioneye/test_web_hooks.py @@ -1,4 +1,5 @@ """Test the motionEye camera web hooks.""" + import copy from http import HTTPStatus from unittest.mock import AsyncMock, Mock, call, patch diff --git a/tests/components/motionmount/test_config_flow.py b/tests/components/motionmount/test_config_flow.py index aa7ea73b577..f24c4e7a2e4 100644 --- a/tests/components/motionmount/test_config_flow.py +++ b/tests/components/motionmount/test_config_flow.py @@ -1,4 +1,5 @@ """Tests for the Vogel's MotionMount config flow.""" + import dataclasses import socket from unittest.mock import MagicMock, PropertyMock diff --git a/tests/components/mqtt/test_alarm_control_panel.py b/tests/components/mqtt/test_alarm_control_panel.py index 89c5d2ffd91..dfe8d21a23b 100644 --- a/tests/components/mqtt/test_alarm_control_panel.py +++ b/tests/components/mqtt/test_alarm_control_panel.py @@ -1,4 +1,5 @@ """The tests the MQTT alarm control panel component.""" + import copy import json from typing import Any diff --git a/tests/components/mqtt/test_binary_sensor.py b/tests/components/mqtt/test_binary_sensor.py index 033026226e2..c9c76bff67c 100644 --- a/tests/components/mqtt/test_binary_sensor.py +++ b/tests/components/mqtt/test_binary_sensor.py @@ -1,4 +1,5 @@ """The tests for the MQTT binary sensor platform.""" + import copy from datetime import datetime, timedelta import json diff --git a/tests/components/mqtt/test_button.py b/tests/components/mqtt/test_button.py index f2f91c5ca75..fd070e0dd11 100644 --- a/tests/components/mqtt/test_button.py +++ b/tests/components/mqtt/test_button.py @@ -1,4 +1,5 @@ """The tests for the MQTT button platform.""" + import copy from typing import Any from unittest.mock import patch diff --git a/tests/components/mqtt/test_climate.py b/tests/components/mqtt/test_climate.py index 8d513b98179..249715a9085 100644 --- a/tests/components/mqtt/test_climate.py +++ b/tests/components/mqtt/test_climate.py @@ -1,4 +1,5 @@ """The tests for the mqtt climate component.""" + import copy import json from typing import Any diff --git a/tests/components/mqtt/test_device_trigger.py b/tests/components/mqtt/test_device_trigger.py index bb8d973b9ed..e4e3149559a 100644 --- a/tests/components/mqtt/test_device_trigger.py +++ b/tests/components/mqtt/test_device_trigger.py @@ -1,4 +1,5 @@ """The tests for MQTT device triggers.""" + import json from unittest.mock import patch diff --git a/tests/components/mqtt/test_diagnostics.py b/tests/components/mqtt/test_diagnostics.py index eb923ac2f07..e09b32de2d4 100644 --- a/tests/components/mqtt/test_diagnostics.py +++ b/tests/components/mqtt/test_diagnostics.py @@ -1,4 +1,5 @@ """Test MQTT diagnostics.""" + import json from unittest.mock import ANY, patch diff --git a/tests/components/mqtt/test_discovery.py b/tests/components/mqtt/test_discovery.py index f86800fd95f..6121e1dc15e 100644 --- a/tests/components/mqtt/test_discovery.py +++ b/tests/components/mqtt/test_discovery.py @@ -1,4 +1,5 @@ """The tests for the MQTT discovery.""" + import asyncio import copy import json diff --git a/tests/components/mqtt/test_event.py b/tests/components/mqtt/test_event.py index bd00120d098..bcfbb1d8d40 100644 --- a/tests/components/mqtt/test_event.py +++ b/tests/components/mqtt/test_event.py @@ -1,4 +1,5 @@ """The tests for the MQTT event platform.""" + import copy import json from unittest.mock import patch diff --git a/tests/components/mqtt/test_fan.py b/tests/components/mqtt/test_fan.py index 8980d6951e5..493e1e5ddf7 100644 --- a/tests/components/mqtt/test_fan.py +++ b/tests/components/mqtt/test_fan.py @@ -1,4 +1,5 @@ """Test MQTT fans.""" + import copy from typing import Any from unittest.mock import patch diff --git a/tests/components/mqtt/test_humidifier.py b/tests/components/mqtt/test_humidifier.py index d76fe84d0a9..0778d36f873 100644 --- a/tests/components/mqtt/test_humidifier.py +++ b/tests/components/mqtt/test_humidifier.py @@ -1,4 +1,5 @@ """Test MQTT humidifiers.""" + import copy from typing import Any from unittest.mock import patch diff --git a/tests/components/mqtt/test_init.py b/tests/components/mqtt/test_init.py index 16fa06ccd27..3188f17feff 100644 --- a/tests/components/mqtt/test_init.py +++ b/tests/components/mqtt/test_init.py @@ -1,4 +1,5 @@ """The tests for the MQTT component.""" + import asyncio from collections.abc import Generator from datetime import datetime, timedelta diff --git a/tests/components/mqtt/test_lawn_mower.py b/tests/components/mqtt/test_lawn_mower.py index d2680824fcd..a6e338c17da 100644 --- a/tests/components/mqtt/test_lawn_mower.py +++ b/tests/components/mqtt/test_lawn_mower.py @@ -1,4 +1,5 @@ """The tests for mqtt lawn_mower component.""" + import copy import json from typing import Any diff --git a/tests/components/mqtt/test_light.py b/tests/components/mqtt/test_light.py index aac79ae1893..749b5c5403a 100644 --- a/tests/components/mqtt/test_light.py +++ b/tests/components/mqtt/test_light.py @@ -168,6 +168,7 @@ mqtt: payload_off: "off" """ + import copy from typing import Any from unittest.mock import call, patch diff --git a/tests/components/mqtt/test_light_json.py b/tests/components/mqtt/test_light_json.py index 1d154f7eb26..796ee9ef9d2 100644 --- a/tests/components/mqtt/test_light_json.py +++ b/tests/components/mqtt/test_light_json.py @@ -78,6 +78,7 @@ light: brightness: true brightness_scale: 99 """ + import copy from typing import Any from unittest.mock import call, patch diff --git a/tests/components/mqtt/test_light_template.py b/tests/components/mqtt/test_light_template.py index 69e6b52de17..f562a11bb95 100644 --- a/tests/components/mqtt/test_light_template.py +++ b/tests/components/mqtt/test_light_template.py @@ -24,6 +24,7 @@ If your light doesn't support color temp feature, omit `color_temp_template`. If your light doesn't support RGB feature, omit `(red|green|blue)_template`. """ + import copy from typing import Any from unittest.mock import patch diff --git a/tests/components/mqtt/test_number.py b/tests/components/mqtt/test_number.py index bf4e51dc519..40d7cd60df5 100644 --- a/tests/components/mqtt/test_number.py +++ b/tests/components/mqtt/test_number.py @@ -1,4 +1,5 @@ """The tests for mqtt number component.""" + import json from typing import Any from unittest.mock import patch diff --git a/tests/components/mqtt/test_scene.py b/tests/components/mqtt/test_scene.py index 141bfc526d3..67fd794c906 100644 --- a/tests/components/mqtt/test_scene.py +++ b/tests/components/mqtt/test_scene.py @@ -1,4 +1,5 @@ """The tests for the MQTT scene platform.""" + import copy from typing import Any from unittest.mock import patch diff --git a/tests/components/mqtt/test_sensor.py b/tests/components/mqtt/test_sensor.py index faa48012514..0345b76c241 100644 --- a/tests/components/mqtt/test_sensor.py +++ b/tests/components/mqtt/test_sensor.py @@ -1,4 +1,5 @@ """The tests for the MQTT sensor platform.""" + import copy from datetime import datetime, timedelta import json diff --git a/tests/components/mqtt/test_siren.py b/tests/components/mqtt/test_siren.py index 8d319d3a80b..c583c4dfe68 100644 --- a/tests/components/mqtt/test_siren.py +++ b/tests/components/mqtt/test_siren.py @@ -1,4 +1,5 @@ """The tests for the MQTT siren platform.""" + import copy from typing import Any from unittest.mock import patch diff --git a/tests/components/mqtt/test_switch.py b/tests/components/mqtt/test_switch.py index 46a7ebb2060..fff96b290ff 100644 --- a/tests/components/mqtt/test_switch.py +++ b/tests/components/mqtt/test_switch.py @@ -1,4 +1,5 @@ """The tests for the MQTT switch platform.""" + import copy from typing import Any from unittest.mock import patch diff --git a/tests/components/mqtt/test_update.py b/tests/components/mqtt/test_update.py index 6a80e18ff23..2fcfbb59952 100644 --- a/tests/components/mqtt/test_update.py +++ b/tests/components/mqtt/test_update.py @@ -1,4 +1,5 @@ """The tests for mqtt update component.""" + import json from unittest.mock import patch diff --git a/tests/components/mqtt/test_water_heater.py b/tests/components/mqtt/test_water_heater.py index 61f430b34f8..945a2296435 100644 --- a/tests/components/mqtt/test_water_heater.py +++ b/tests/components/mqtt/test_water_heater.py @@ -1,4 +1,5 @@ """The tests for the mqtt water heater component.""" + import copy import json from typing import Any diff --git a/tests/components/mqtt_eventstream/test_init.py b/tests/components/mqtt_eventstream/test_init.py index 5eabb2202aa..2045a14bf1f 100644 --- a/tests/components/mqtt_eventstream/test_init.py +++ b/tests/components/mqtt_eventstream/test_init.py @@ -1,4 +1,5 @@ """The tests for the MQTT eventstream component.""" + import json from unittest.mock import ANY, patch diff --git a/tests/components/mqtt_room/test_sensor.py b/tests/components/mqtt_room/test_sensor.py index 822e028f4f6..bc1890f08fa 100644 --- a/tests/components/mqtt_room/test_sensor.py +++ b/tests/components/mqtt_room/test_sensor.py @@ -1,4 +1,5 @@ """The tests for the MQTT room presence sensor.""" + import datetime import json from unittest.mock import patch diff --git a/tests/components/mythicbeastsdns/test_init.py b/tests/components/mythicbeastsdns/test_init.py index 7efcf762df2..81d17d2bf77 100644 --- a/tests/components/mythicbeastsdns/test_init.py +++ b/tests/components/mythicbeastsdns/test_init.py @@ -1,4 +1,5 @@ """Test the Mythic Beasts DNS component.""" + import logging from unittest.mock import patch diff --git a/tests/components/myuplink/test_init.py b/tests/components/myuplink/test_init.py index 17b899aa662..328dc55d4ad 100644 --- a/tests/components/myuplink/test_init.py +++ b/tests/components/myuplink/test_init.py @@ -1,4 +1,5 @@ """Tests for init module.""" + import http import time from unittest.mock import MagicMock diff --git a/tests/components/nam/test_diagnostics.py b/tests/components/nam/test_diagnostics.py index 998819128a9..9d13121392f 100644 --- a/tests/components/nam/test_diagnostics.py +++ b/tests/components/nam/test_diagnostics.py @@ -1,4 +1,5 @@ """Test NAM diagnostics.""" + import json from homeassistant.core import HomeAssistant diff --git a/tests/components/nest/test_api.py b/tests/components/nest/test_api.py index 91975f3559f..31f5d03dc2b 100644 --- a/tests/components/nest/test_api.py +++ b/tests/components/nest/test_api.py @@ -7,6 +7,7 @@ for token refresh and for testing: The tests below exercise both cases during integration setup. """ + import time from unittest.mock import patch diff --git a/tests/components/nest/test_camera.py b/tests/components/nest/test_camera.py index 647a3419501..b68173be201 100644 --- a/tests/components/nest/test_camera.py +++ b/tests/components/nest/test_camera.py @@ -3,6 +3,7 @@ These tests fake out the subscriber/devicemanager, and are not using a real pubsub subscriber. """ + import datetime from http import HTTPStatus from unittest.mock import AsyncMock, Mock, patch diff --git a/tests/components/nest/test_init.py b/tests/components/nest/test_init.py index 1e3eed91f19..082f40094aa 100644 --- a/tests/components/nest/test_init.py +++ b/tests/components/nest/test_init.py @@ -7,6 +7,7 @@ By default all tests use test fixtures that run in each possible configuration mode (e.g. yaml, ConfigEntry, etc) however some tests override and just run in relevant modes. """ + import logging from typing import Any from unittest.mock import patch diff --git a/tests/components/netatmo/test_device_trigger.py b/tests/components/netatmo/test_device_trigger.py index ebafd313ff4..65d7274cdc8 100644 --- a/tests/components/netatmo/test_device_trigger.py +++ b/tests/components/netatmo/test_device_trigger.py @@ -1,4 +1,5 @@ """The tests for Netatmo device triggers.""" + import pytest from pytest_unordered import unordered diff --git a/tests/components/netatmo/test_media_source.py b/tests/components/netatmo/test_media_source.py index c22bfd51acb..f9aff2749d2 100644 --- a/tests/components/netatmo/test_media_source.py +++ b/tests/components/netatmo/test_media_source.py @@ -1,4 +1,5 @@ """Test Local Media Source.""" + import ast import pytest diff --git a/tests/components/nexia/test_init.py b/tests/components/nexia/test_init.py index f920592f8a6..8eeb8a9f729 100644 --- a/tests/components/nexia/test_init.py +++ b/tests/components/nexia/test_init.py @@ -1,4 +1,5 @@ """The init tests for the nexia platform.""" + import aiohttp from homeassistant.components.nexia.const import DOMAIN diff --git a/tests/components/nextdns/test_system_health.py b/tests/components/nextdns/test_system_health.py index 4d4299621e8..758437c9acb 100644 --- a/tests/components/nextdns/test_system_health.py +++ b/tests/components/nextdns/test_system_health.py @@ -1,4 +1,5 @@ """Test NextDNS system health.""" + import asyncio from aiohttp import ClientError diff --git a/tests/components/nibe_heatpump/test_coordinator.py b/tests/components/nibe_heatpump/test_coordinator.py index 474802541f2..ffd5c545645 100644 --- a/tests/components/nibe_heatpump/test_coordinator.py +++ b/tests/components/nibe_heatpump/test_coordinator.py @@ -1,4 +1,5 @@ """Test the Nibe Heat Pump config flow.""" + import asyncio from typing import Any from unittest.mock import patch diff --git a/tests/components/notify/test_init.py b/tests/components/notify/test_init.py index 9fb5b9e531a..0b75a3c4691 100644 --- a/tests/components/notify/test_init.py +++ b/tests/components/notify/test_init.py @@ -1,4 +1,5 @@ """The tests for notify services that change targets.""" + import asyncio from pathlib import Path from unittest.mock import Mock, patch diff --git a/tests/components/nsw_rural_fire_service_feed/test_geo_location.py b/tests/components/nsw_rural_fire_service_feed/test_geo_location.py index bf56cb8a985..f329e456db1 100644 --- a/tests/components/nsw_rural_fire_service_feed/test_geo_location.py +++ b/tests/components/nsw_rural_fire_service_feed/test_geo_location.py @@ -1,4 +1,5 @@ """The tests for the NSW Rural Fire Service Feeds platform.""" + import datetime from unittest.mock import ANY, MagicMock, call, patch diff --git a/tests/components/number/test_device_action.py b/tests/components/number/test_device_action.py index 17c63dd3394..17546218a14 100644 --- a/tests/components/number/test_device_action.py +++ b/tests/components/number/test_device_action.py @@ -1,4 +1,5 @@ """The tests for Number device actions.""" + import pytest from pytest_unordered import unordered import voluptuous_serialize diff --git a/tests/components/number/test_reproduce_state.py b/tests/components/number/test_reproduce_state.py index 01b0383ecf7..e941291c04e 100644 --- a/tests/components/number/test_reproduce_state.py +++ b/tests/components/number/test_reproduce_state.py @@ -1,4 +1,5 @@ """Test reproduce state for Number entities.""" + import pytest from homeassistant.components.number.const import ( diff --git a/tests/components/number/test_significant_change.py b/tests/components/number/test_significant_change.py index 1a6491f3de9..e0e02fc1d35 100644 --- a/tests/components/number/test_significant_change.py +++ b/tests/components/number/test_significant_change.py @@ -1,4 +1,5 @@ """Test the Number significant change platform.""" + import pytest from homeassistant.components.number import NumberDeviceClass diff --git a/tests/components/nws/test_sensor.py b/tests/components/nws/test_sensor.py index 5e36c9c0717..4d29e48ae0b 100644 --- a/tests/components/nws/test_sensor.py +++ b/tests/components/nws/test_sensor.py @@ -1,4 +1,5 @@ """Sensors for National Weather Service (NWS).""" + import pytest from homeassistant.components.nws.const import ATTRIBUTION, DOMAIN diff --git a/tests/components/onboarding/test_views.py b/tests/components/onboarding/test_views.py index af9e6f9ebf0..406faff0dac 100644 --- a/tests/components/onboarding/test_views.py +++ b/tests/components/onboarding/test_views.py @@ -1,4 +1,5 @@ """Test the onboarding views.""" + import asyncio from http import HTTPStatus import os diff --git a/tests/components/onvif/test_config_flow.py b/tests/components/onvif/test_config_flow.py index fcf0ea5c9dc..5640472d6a2 100644 --- a/tests/components/onvif/test_config_flow.py +++ b/tests/components/onvif/test_config_flow.py @@ -1,4 +1,5 @@ """Test ONVIF config flow.""" + import logging from unittest.mock import MagicMock, patch diff --git a/tests/components/openexchangerates/test_config_flow.py b/tests/components/openexchangerates/test_config_flow.py index 213badcab08..e0896f64340 100644 --- a/tests/components/openexchangerates/test_config_flow.py +++ b/tests/components/openexchangerates/test_config_flow.py @@ -1,4 +1,5 @@ """Test the Open Exchange Rates config flow.""" + import asyncio from collections.abc import Generator from typing import Any diff --git a/tests/components/openhardwaremonitor/test_sensor.py b/tests/components/openhardwaremonitor/test_sensor.py index 5598abfabc3..9bf339898a0 100644 --- a/tests/components/openhardwaremonitor/test_sensor.py +++ b/tests/components/openhardwaremonitor/test_sensor.py @@ -1,4 +1,5 @@ """The tests for the Open Hardware Monitor platform.""" + import requests_mock from homeassistant.core import HomeAssistant diff --git a/tests/components/opower/conftest.py b/tests/components/opower/conftest.py index 0ee910f84f4..12d1a0dcdce 100644 --- a/tests/components/opower/conftest.py +++ b/tests/components/opower/conftest.py @@ -1,4 +1,5 @@ """Fixtures for the Opower integration tests.""" + import pytest from homeassistant.components.opower.const import DOMAIN diff --git a/tests/components/otbr/test_config_flow.py b/tests/components/otbr/test_config_flow.py index 03d54981b1a..18c62257803 100644 --- a/tests/components/otbr/test_config_flow.py +++ b/tests/components/otbr/test_config_flow.py @@ -1,4 +1,5 @@ """Test the Open Thread Border Router config flow.""" + import asyncio from http import HTTPStatus from typing import Any diff --git a/tests/components/otbr/test_init.py b/tests/components/otbr/test_init.py index 89a8f433016..39805728a3e 100644 --- a/tests/components/otbr/test_init.py +++ b/tests/components/otbr/test_init.py @@ -1,4 +1,5 @@ """Test the Open Thread Border Router integration.""" + import asyncio from http import HTTPStatus from typing import Any diff --git a/tests/components/owntracks/test_device_tracker.py b/tests/components/owntracks/test_device_tracker.py index 1be21e8b1b2..d855c318fb7 100644 --- a/tests/components/owntracks/test_device_tracker.py +++ b/tests/components/owntracks/test_device_tracker.py @@ -1,4 +1,5 @@ """The tests for the Owntracks device tracker.""" + import json from unittest.mock import patch diff --git a/tests/components/owntracks/test_init.py b/tests/components/owntracks/test_init.py index a54a841030b..7e85b67f9de 100644 --- a/tests/components/owntracks/test_init.py +++ b/tests/components/owntracks/test_init.py @@ -1,4 +1,5 @@ """Test the owntracks_http platform.""" + import pytest from homeassistant.components import owntracks diff --git a/tests/components/p1_monitor/conftest.py b/tests/components/p1_monitor/conftest.py index 5f6713f5228..e95cb245f5e 100644 --- a/tests/components/p1_monitor/conftest.py +++ b/tests/components/p1_monitor/conftest.py @@ -1,4 +1,5 @@ """Fixtures for P1 Monitor integration tests.""" + import json from unittest.mock import AsyncMock, MagicMock, patch diff --git a/tests/components/panel_iframe/test_init.py b/tests/components/panel_iframe/test_init.py index bd8950163a9..147ab879ed6 100644 --- a/tests/components/panel_iframe/test_init.py +++ b/tests/components/panel_iframe/test_init.py @@ -1,4 +1,5 @@ """The tests for the panel_iframe component.""" + import pytest from homeassistant.components import frontend diff --git a/tests/components/person/conftest.py b/tests/components/person/conftest.py index 4079ff24267..7f06b854c5c 100644 --- a/tests/components/person/conftest.py +++ b/tests/components/person/conftest.py @@ -1,4 +1,5 @@ """The tests for the person component.""" + import logging import pytest diff --git a/tests/components/philips_js/test_binary_sensor.py b/tests/components/philips_js/test_binary_sensor.py index 01233706d07..c50c776d416 100644 --- a/tests/components/philips_js/test_binary_sensor.py +++ b/tests/components/philips_js/test_binary_sensor.py @@ -1,4 +1,5 @@ """The tests for philips_js binary_sensor.""" + import pytest from homeassistant.const import STATE_OFF, STATE_ON diff --git a/tests/components/philips_js/test_device_trigger.py b/tests/components/philips_js/test_device_trigger.py index 0e8427b29e5..3a59e3c6662 100644 --- a/tests/components/philips_js/test_device_trigger.py +++ b/tests/components/philips_js/test_device_trigger.py @@ -1,4 +1,5 @@ """The tests for Philips TV device triggers.""" + import pytest from pytest_unordered import unordered diff --git a/tests/components/pi_hole/test_init.py b/tests/components/pi_hole/test_init.py index b0b71fe13ed..a58a46680bb 100644 --- a/tests/components/pi_hole/test_init.py +++ b/tests/components/pi_hole/test_init.py @@ -1,4 +1,5 @@ """Test pi_hole component.""" + import logging from unittest.mock import AsyncMock diff --git a/tests/components/picnic/test_sensor.py b/tests/components/picnic/test_sensor.py index 1535ac1d9ad..37191642c07 100644 --- a/tests/components/picnic/test_sensor.py +++ b/tests/components/picnic/test_sensor.py @@ -1,4 +1,5 @@ """The tests for the Picnic sensor platform.""" + import copy from datetime import timedelta import unittest diff --git a/tests/components/pilight/test_sensor.py b/tests/components/pilight/test_sensor.py index 54a26f690d5..629f0f13de4 100644 --- a/tests/components/pilight/test_sensor.py +++ b/tests/components/pilight/test_sensor.py @@ -1,4 +1,5 @@ """The tests for the Pilight sensor platform.""" + import logging import pytest diff --git a/tests/components/plex/test_config_flow.py b/tests/components/plex/test_config_flow.py index b2a4f3c23a5..30b20eec4ab 100644 --- a/tests/components/plex/test_config_flow.py +++ b/tests/components/plex/test_config_flow.py @@ -1,4 +1,5 @@ """Tests for Plex config flow.""" + import copy from http import HTTPStatus import ssl diff --git a/tests/components/plex/test_device_handling.py b/tests/components/plex/test_device_handling.py index 5887079ce21..c3c26ec0bdd 100644 --- a/tests/components/plex/test_device_handling.py +++ b/tests/components/plex/test_device_handling.py @@ -1,4 +1,5 @@ """Tests for handling the device registry.""" + import requests_mock from homeassistant.components.plex.const import DOMAIN diff --git a/tests/components/plex/test_init.py b/tests/components/plex/test_init.py index 47bdc472b2b..e514ea7baa3 100644 --- a/tests/components/plex/test_init.py +++ b/tests/components/plex/test_init.py @@ -1,4 +1,5 @@ """Tests for Plex setup.""" + import copy from datetime import timedelta from http import HTTPStatus diff --git a/tests/components/plex/test_server.py b/tests/components/plex/test_server.py index 64abe27b16b..ec798af6d03 100644 --- a/tests/components/plex/test_server.py +++ b/tests/components/plex/test_server.py @@ -1,4 +1,5 @@ """Tests for Plex server.""" + import copy from unittest.mock import patch diff --git a/tests/components/plex/test_update.py b/tests/components/plex/test_update.py index ce50f67a0d9..a96e0409bbb 100644 --- a/tests/components/plex/test_update.py +++ b/tests/components/plex/test_update.py @@ -1,4 +1,5 @@ """Tests for update entities.""" + import pytest import requests_mock diff --git a/tests/components/prosegur/test_camera.py b/tests/components/prosegur/test_camera.py index 58017085aed..fdf13e30359 100644 --- a/tests/components/prosegur/test_camera.py +++ b/tests/components/prosegur/test_camera.py @@ -1,4 +1,5 @@ """The camera tests for the prosegur platform.""" + import logging from unittest.mock import AsyncMock diff --git a/tests/components/proximity/conftest.py b/tests/components/proximity/conftest.py index 960ab6cf916..ba73d971131 100644 --- a/tests/components/proximity/conftest.py +++ b/tests/components/proximity/conftest.py @@ -1,4 +1,5 @@ """Config test for proximity.""" + import pytest from homeassistant.core import HomeAssistant diff --git a/tests/components/python_script/test_init.py b/tests/components/python_script/test_init.py index 0692bdfd816..81a98f5828a 100644 --- a/tests/components/python_script/test_init.py +++ b/tests/components/python_script/test_init.py @@ -1,4 +1,5 @@ """Test the python_script component.""" + import logging from unittest.mock import mock_open, patch diff --git a/tests/components/qbittorrent/test_config_flow.py b/tests/components/qbittorrent/test_config_flow.py index 4131b9142e2..8a424f5c87b 100644 --- a/tests/components/qbittorrent/test_config_flow.py +++ b/tests/components/qbittorrent/test_config_flow.py @@ -1,4 +1,5 @@ """Test the qBittorrent config flow.""" + import pytest from requests.exceptions import RequestException import requests_mock diff --git a/tests/components/qld_bushfire/test_geo_location.py b/tests/components/qld_bushfire/test_geo_location.py index 9cd12ea0447..916c7567b55 100644 --- a/tests/components/qld_bushfire/test_geo_location.py +++ b/tests/components/qld_bushfire/test_geo_location.py @@ -1,4 +1,5 @@ """The tests for the Queensland Bushfire Alert Feed platform.""" + import datetime from unittest.mock import MagicMock, call, patch diff --git a/tests/components/qwikswitch/test_init.py b/tests/components/qwikswitch/test_init.py index 6d440691780..08e27ec42bd 100644 --- a/tests/components/qwikswitch/test_init.py +++ b/tests/components/qwikswitch/test_init.py @@ -1,4 +1,5 @@ """Test qwikswitch sensors.""" + import asyncio from typing import Any from unittest.mock import Mock diff --git a/tests/components/radarr/test_binary_sensor.py b/tests/components/radarr/test_binary_sensor.py index cd1df721d5f..bd622ded78d 100644 --- a/tests/components/radarr/test_binary_sensor.py +++ b/tests/components/radarr/test_binary_sensor.py @@ -1,4 +1,5 @@ """The tests for Radarr binary sensor platform.""" + import pytest from homeassistant.components.binary_sensor import BinarySensorDeviceClass diff --git a/tests/components/radarr/test_init.py b/tests/components/radarr/test_init.py index 62660c12874..c4226d3f3fb 100644 --- a/tests/components/radarr/test_init.py +++ b/tests/components/radarr/test_init.py @@ -1,4 +1,5 @@ """Test Radarr integration.""" + import pytest from homeassistant.components.radarr.const import DEFAULT_NAME, DOMAIN diff --git a/tests/components/radarr/test_sensor.py b/tests/components/radarr/test_sensor.py index 11f55b712cd..b75034acc8f 100644 --- a/tests/components/radarr/test_sensor.py +++ b/tests/components/radarr/test_sensor.py @@ -1,4 +1,5 @@ """The tests for Radarr sensor platform.""" + import pytest from homeassistant.components.sensor import ( diff --git a/tests/components/rainforest_raven/test_init.py b/tests/components/rainforest_raven/test_init.py index b99d94f4b43..1cc50971e09 100644 --- a/tests/components/rainforest_raven/test_init.py +++ b/tests/components/rainforest_raven/test_init.py @@ -1,4 +1,5 @@ """Tests for the Rainforest RAVEn component initialisation.""" + import pytest from homeassistant.components.rainforest_raven.const import DOMAIN diff --git a/tests/components/rainforest_raven/test_sensor.py b/tests/components/rainforest_raven/test_sensor.py index e637e22ecf9..36e6572149f 100644 --- a/tests/components/rainforest_raven/test_sensor.py +++ b/tests/components/rainforest_raven/test_sensor.py @@ -1,4 +1,5 @@ """Tests for the Rainforest RAVEn sensors.""" + import pytest from homeassistant.core import HomeAssistant diff --git a/tests/components/rainmachine/conftest.py b/tests/components/rainmachine/conftest.py index 2697e908c94..c3724334776 100644 --- a/tests/components/rainmachine/conftest.py +++ b/tests/components/rainmachine/conftest.py @@ -1,4 +1,5 @@ """Define test fixtures for RainMachine.""" + import json from unittest.mock import AsyncMock, patch diff --git a/tests/components/recorder/test_filters_with_entityfilter.py b/tests/components/recorder/test_filters_with_entityfilter.py index 896987ee58d..d888a1de52e 100644 --- a/tests/components/recorder/test_filters_with_entityfilter.py +++ b/tests/components/recorder/test_filters_with_entityfilter.py @@ -1,4 +1,5 @@ """The tests for the recorder filter matching the EntityFilter component.""" + import json from sqlalchemy import select diff --git a/tests/components/recorder/test_filters_with_entityfilter_schema_37.py b/tests/components/recorder/test_filters_with_entityfilter_schema_37.py index 9a03c024a83..6794827bd6a 100644 --- a/tests/components/recorder/test_filters_with_entityfilter_schema_37.py +++ b/tests/components/recorder/test_filters_with_entityfilter_schema_37.py @@ -1,4 +1,5 @@ """The tests for the recorder filter matching the EntityFilter component.""" + import json from unittest.mock import patch diff --git a/tests/components/recorder/test_migration_from_schema_32.py b/tests/components/recorder/test_migration_from_schema_32.py index 2849c0703da..cd9969206f5 100644 --- a/tests/components/recorder/test_migration_from_schema_32.py +++ b/tests/components/recorder/test_migration_from_schema_32.py @@ -1,4 +1,5 @@ """The tests for the recorder filter matching the EntityFilter component.""" + import datetime import importlib import sys diff --git a/tests/components/recorder/test_pool.py b/tests/components/recorder/test_pool.py index 3a6ff50af2b..541fc8d714b 100644 --- a/tests/components/recorder/test_pool.py +++ b/tests/components/recorder/test_pool.py @@ -1,4 +1,5 @@ """Test pool.""" + import threading import pytest diff --git a/tests/components/recorder/test_websocket_api.py b/tests/components/recorder/test_websocket_api.py index d35be0abc9b..2ca386734bb 100644 --- a/tests/components/recorder/test_websocket_api.py +++ b/tests/components/recorder/test_websocket_api.py @@ -1,4 +1,5 @@ """The tests for sensor recorder platform.""" + import datetime from datetime import timedelta from statistics import fmean diff --git a/tests/components/reddit/test_sensor.py b/tests/components/reddit/test_sensor.py index e3d31d29ff8..92ee282e9c8 100644 --- a/tests/components/reddit/test_sensor.py +++ b/tests/components/reddit/test_sensor.py @@ -1,4 +1,5 @@ """The tests for the Reddit platform.""" + import copy from unittest.mock import patch diff --git a/tests/components/remote/test_device_action.py b/tests/components/remote/test_device_action.py index 76e6075a18f..ef8364c050e 100644 --- a/tests/components/remote/test_device_action.py +++ b/tests/components/remote/test_device_action.py @@ -1,4 +1,5 @@ """The test for remote device automation.""" + import pytest from pytest_unordered import unordered diff --git a/tests/components/remote/test_init.py b/tests/components/remote/test_init.py index be4a4843097..15fbb1174c6 100644 --- a/tests/components/remote/test_init.py +++ b/tests/components/remote/test_init.py @@ -1,4 +1,5 @@ """The tests for the Remote component, adapted from Light Test.""" + import pytest import homeassistant.components.remote as remote diff --git a/tests/components/remote/test_reproduce_state.py b/tests/components/remote/test_reproduce_state.py index 910e3e867c6..7d1954e3ce1 100644 --- a/tests/components/remote/test_reproduce_state.py +++ b/tests/components/remote/test_reproduce_state.py @@ -1,4 +1,5 @@ """Test reproduce state for Remote.""" + import pytest from homeassistant.core import HomeAssistant, State diff --git a/tests/components/renault/test_diagnostics.py b/tests/components/renault/test_diagnostics.py index 76ea88b4b45..3c8c1c7449e 100644 --- a/tests/components/renault/test_diagnostics.py +++ b/tests/components/renault/test_diagnostics.py @@ -1,4 +1,5 @@ """Test Renault diagnostics.""" + import pytest from homeassistant.components.diagnostics import REDACTED diff --git a/tests/components/rest_command/test_init.py b/tests/components/rest_command/test_init.py index ef7707cad76..dc71333370a 100644 --- a/tests/components/rest_command/test_init.py +++ b/tests/components/rest_command/test_init.py @@ -1,4 +1,5 @@ """The tests for the rest command platform.""" + import base64 from http import HTTPStatus from unittest.mock import patch diff --git a/tests/components/rfxtrx/test_binary_sensor.py b/tests/components/rfxtrx/test_binary_sensor.py index 2c1f763ea66..d71cd040c87 100644 --- a/tests/components/rfxtrx/test_binary_sensor.py +++ b/tests/components/rfxtrx/test_binary_sensor.py @@ -1,4 +1,5 @@ """The tests for the Rfxtrx sensor platform.""" + import pytest from homeassistant.components.rfxtrx import DOMAIN diff --git a/tests/components/rfxtrx/test_config_flow.py b/tests/components/rfxtrx/test_config_flow.py index e527b5dfb7b..d3c87885782 100644 --- a/tests/components/rfxtrx/test_config_flow.py +++ b/tests/components/rfxtrx/test_config_flow.py @@ -1,4 +1,5 @@ """Test the Rfxtrx config flow.""" + import os from unittest.mock import MagicMock, patch, sentinel diff --git a/tests/components/rfxtrx/test_sensor.py b/tests/components/rfxtrx/test_sensor.py index e80e612b283..566237156a6 100644 --- a/tests/components/rfxtrx/test_sensor.py +++ b/tests/components/rfxtrx/test_sensor.py @@ -1,4 +1,5 @@ """The tests for the Rfxtrx sensor platform.""" + import pytest from homeassistant.components.rfxtrx import DOMAIN diff --git a/tests/components/ring/test_light.py b/tests/components/ring/test_light.py index 7607f9fa5db..fd58e0ffbee 100644 --- a/tests/components/ring/test_light.py +++ b/tests/components/ring/test_light.py @@ -1,4 +1,5 @@ """The tests for the Ring light platform.""" + import requests_mock from homeassistant.const import Platform diff --git a/tests/components/ring/test_sensor.py b/tests/components/ring/test_sensor.py index 34b6295b740..0299e626670 100644 --- a/tests/components/ring/test_sensor.py +++ b/tests/components/ring/test_sensor.py @@ -1,4 +1,5 @@ """The tests for the Ring sensor platform.""" + import logging from freezegun.api import FrozenDateTimeFactory diff --git a/tests/components/ring/test_siren.py b/tests/components/ring/test_siren.py index 916da5d24fb..9a54a739fbd 100644 --- a/tests/components/ring/test_siren.py +++ b/tests/components/ring/test_siren.py @@ -1,4 +1,5 @@ """The tests for the Ring button platform.""" + import requests_mock from homeassistant.const import Platform diff --git a/tests/components/ring/test_switch.py b/tests/components/ring/test_switch.py index fa3da8b683e..0012db61f97 100644 --- a/tests/components/ring/test_switch.py +++ b/tests/components/ring/test_switch.py @@ -1,4 +1,5 @@ """The tests for the Ring switch platform.""" + import requests_mock from homeassistant.const import ATTR_ENTITY_ID, Platform diff --git a/tests/components/risco/test_init.py b/tests/components/risco/test_init.py index a1a9e3bd6a7..18378c5c9c4 100644 --- a/tests/components/risco/test_init.py +++ b/tests/components/risco/test_init.py @@ -1,4 +1,5 @@ """Tests for the Risco initialization.""" + import pytest from homeassistant.components.risco import CannotConnectError diff --git a/tests/components/rituals_perfume_genie/test_select.py b/tests/components/rituals_perfume_genie/test_select.py index be602552d76..17612edfd97 100644 --- a/tests/components/rituals_perfume_genie/test_select.py +++ b/tests/components/rituals_perfume_genie/test_select.py @@ -1,4 +1,5 @@ """Tests for the Rituals Perfume Genie select platform.""" + import pytest from homeassistant.components.homeassistant import SERVICE_UPDATE_ENTITY diff --git a/tests/components/rmvtransport/test_sensor.py b/tests/components/rmvtransport/test_sensor.py index 92cc04ca3d4..c17eaac2105 100644 --- a/tests/components/rmvtransport/test_sensor.py +++ b/tests/components/rmvtransport/test_sensor.py @@ -1,4 +1,5 @@ """The tests for the rmvtransport platform.""" + import datetime from unittest.mock import patch diff --git a/tests/components/roborock/test_image.py b/tests/components/roborock/test_image.py index 19fa5152e2d..b8d1dc408a2 100644 --- a/tests/components/roborock/test_image.py +++ b/tests/components/roborock/test_image.py @@ -1,4 +1,5 @@ """Test Roborock Image platform.""" + import copy from datetime import timedelta from http import HTTPStatus diff --git a/tests/components/roku/test_config_flow.py b/tests/components/roku/test_config_flow.py index e86084e7718..34640474bcd 100644 --- a/tests/components/roku/test_config_flow.py +++ b/tests/components/roku/test_config_flow.py @@ -1,4 +1,5 @@ """Test the Roku config flow.""" + import dataclasses from unittest.mock import MagicMock diff --git a/tests/components/samsungtv/test_device_trigger.py b/tests/components/samsungtv/test_device_trigger.py index 92df6356f58..a1fb585bfaa 100644 --- a/tests/components/samsungtv/test_device_trigger.py +++ b/tests/components/samsungtv/test_device_trigger.py @@ -1,4 +1,5 @@ """The tests for Samsung TV device triggers.""" + import pytest from homeassistant.components import automation diff --git a/tests/components/scene/test_init.py b/tests/components/scene/test_init.py index e0b2af87187..82f29328850 100644 --- a/tests/components/scene/test_init.py +++ b/tests/components/scene/test_init.py @@ -1,4 +1,5 @@ """The tests for the Scene component.""" + import io from unittest.mock import patch diff --git a/tests/components/screenlogic/conftest.py b/tests/components/screenlogic/conftest.py index 3795df3dddc..7c4d6adf16b 100644 --- a/tests/components/screenlogic/conftest.py +++ b/tests/components/screenlogic/conftest.py @@ -1,4 +1,5 @@ """Setup fixtures for ScreenLogic integration tests.""" + import pytest from homeassistant.components.screenlogic import DOMAIN diff --git a/tests/components/script/test_blueprint.py b/tests/components/script/test_blueprint.py index 6c9f17f29b7..bccf1d9aa50 100644 --- a/tests/components/script/test_blueprint.py +++ b/tests/components/script/test_blueprint.py @@ -1,4 +1,5 @@ """Test script blueprints.""" + import asyncio from collections.abc import Iterator import contextlib diff --git a/tests/components/script/test_init.py b/tests/components/script/test_init.py index 5a5c2c4c9ce..8affd8b7cf9 100644 --- a/tests/components/script/test_init.py +++ b/tests/components/script/test_init.py @@ -1,4 +1,5 @@ """The tests for the Script component.""" + import asyncio from datetime import timedelta from typing import Any diff --git a/tests/components/search/test_init.py b/tests/components/search/test_init.py index ebf70a6239c..57b72de2bcd 100644 --- a/tests/components/search/test_init.py +++ b/tests/components/search/test_init.py @@ -1,4 +1,5 @@ """Tests for Search integration.""" + import pytest from homeassistant.components import search diff --git a/tests/components/select/test_device_action.py b/tests/components/select/test_device_action.py index 121b41fcb2b..8245dfe7d56 100644 --- a/tests/components/select/test_device_action.py +++ b/tests/components/select/test_device_action.py @@ -1,4 +1,5 @@ """The tests for Select device actions.""" + import pytest from pytest_unordered import unordered import voluptuous_serialize diff --git a/tests/components/select/test_reproduce_state.py b/tests/components/select/test_reproduce_state.py index bbd1ae17a7b..579ef3301d9 100644 --- a/tests/components/select/test_reproduce_state.py +++ b/tests/components/select/test_reproduce_state.py @@ -1,4 +1,5 @@ """Test reproduce state for select entities.""" + import pytest from homeassistant.components.select.const import ( diff --git a/tests/components/sensor/test_device_condition.py b/tests/components/sensor/test_device_condition.py index e0a8bebf5fc..31f234109e5 100644 --- a/tests/components/sensor/test_device_condition.py +++ b/tests/components/sensor/test_device_condition.py @@ -1,4 +1,5 @@ """The test for sensor device automation.""" + import pytest from pytest_unordered import unordered diff --git a/tests/components/sensor/test_helpers.py b/tests/components/sensor/test_helpers.py index f103a762842..e197579fa66 100644 --- a/tests/components/sensor/test_helpers.py +++ b/tests/components/sensor/test_helpers.py @@ -1,4 +1,5 @@ """The test for sensor helpers.""" + import pytest from homeassistant.components.sensor import SensorDeviceClass diff --git a/tests/components/sensor/test_significant_change.py b/tests/components/sensor/test_significant_change.py index fa530b66381..e1a2325cd11 100644 --- a/tests/components/sensor/test_significant_change.py +++ b/tests/components/sensor/test_significant_change.py @@ -1,4 +1,5 @@ """Test the sensor significant change platform.""" + import pytest from homeassistant.components.sensor import SensorDeviceClass, significant_change diff --git a/tests/components/sentry/test_config_flow.py b/tests/components/sentry/test_config_flow.py index 34ed1d2c4b5..edcd87cd5d9 100644 --- a/tests/components/sentry/test_config_flow.py +++ b/tests/components/sentry/test_config_flow.py @@ -1,4 +1,5 @@ """Test the sentry config flow.""" + import logging from unittest.mock import patch diff --git a/tests/components/sentry/test_init.py b/tests/components/sentry/test_init.py index 73f6a7cfd09..b8c5c4cbde9 100644 --- a/tests/components/sentry/test_init.py +++ b/tests/components/sentry/test_init.py @@ -1,4 +1,5 @@ """Tests for Sentry integration.""" + import logging from unittest.mock import Mock, patch diff --git a/tests/components/sfr_box/test_config_flow.py b/tests/components/sfr_box/test_config_flow.py index c8130d5d617..282d7dbbb4c 100644 --- a/tests/components/sfr_box/test_config_flow.py +++ b/tests/components/sfr_box/test_config_flow.py @@ -1,4 +1,5 @@ """Test the SFR Box config flow.""" + import json from unittest.mock import AsyncMock, patch diff --git a/tests/components/signal_messenger/test_notify.py b/tests/components/signal_messenger/test_notify.py index 360a2b24bec..d1f590ab5bc 100644 --- a/tests/components/signal_messenger/test_notify.py +++ b/tests/components/signal_messenger/test_notify.py @@ -1,4 +1,5 @@ """The tests for the signal_messenger platform.""" + import base64 import json import logging diff --git a/tests/components/simplisafe/conftest.py b/tests/components/simplisafe/conftest.py index 1b9f9f02cee..0594ac51850 100644 --- a/tests/components/simplisafe/conftest.py +++ b/tests/components/simplisafe/conftest.py @@ -1,4 +1,5 @@ """Define test fixtures for SimpliSafe.""" + import json from unittest.mock import AsyncMock, Mock, patch diff --git a/tests/components/simplisafe/test_config_flow.py b/tests/components/simplisafe/test_config_flow.py index 53d9c86185f..308f04d12a1 100644 --- a/tests/components/simplisafe/test_config_flow.py +++ b/tests/components/simplisafe/test_config_flow.py @@ -1,4 +1,5 @@ """Define tests for the SimpliSafe config flow.""" + import logging from unittest.mock import patch diff --git a/tests/components/smartthings/conftest.py b/tests/components/smartthings/conftest.py index a7a819d6ac9..283b478fdb0 100644 --- a/tests/components/smartthings/conftest.py +++ b/tests/components/smartthings/conftest.py @@ -1,4 +1,5 @@ """Test configuration and mocks for the SmartThings component.""" + import secrets from unittest.mock import Mock, patch from uuid import uuid4 diff --git a/tests/components/smarttub/test_climate.py b/tests/components/smarttub/test_climate.py index 40e3c05b509..e4e73b8b131 100644 --- a/tests/components/smarttub/test_climate.py +++ b/tests/components/smarttub/test_climate.py @@ -1,4 +1,5 @@ """Test the SmartTub climate platform.""" + import smarttub from homeassistant.components.climate import ( diff --git a/tests/components/smarttub/test_light.py b/tests/components/smarttub/test_light.py index f6a3977f373..a3e4e4a5cf7 100644 --- a/tests/components/smarttub/test_light.py +++ b/tests/components/smarttub/test_light.py @@ -1,4 +1,5 @@ """Test the SmartTub light platform.""" + import pytest from smarttub import SpaLight diff --git a/tests/components/smarttub/test_sensor.py b/tests/components/smarttub/test_sensor.py index 5e476dcaaa5..9bdffb62534 100644 --- a/tests/components/smarttub/test_sensor.py +++ b/tests/components/smarttub/test_sensor.py @@ -1,4 +1,5 @@ """Test the SmartTub sensor platform.""" + import pytest import smarttub diff --git a/tests/components/smarttub/test_switch.py b/tests/components/smarttub/test_switch.py index d7e284e9ac2..42fd3d45d88 100644 --- a/tests/components/smarttub/test_switch.py +++ b/tests/components/smarttub/test_switch.py @@ -1,4 +1,5 @@ """Test the SmartTub switch platform.""" + import pytest from homeassistant.const import STATE_OFF, STATE_ON diff --git a/tests/components/smhi/conftest.py b/tests/components/smhi/conftest.py index c474bc50b51..df6a81a223d 100644 --- a/tests/components/smhi/conftest.py +++ b/tests/components/smhi/conftest.py @@ -1,4 +1,5 @@ """Provide common smhi fixtures.""" + import pytest from homeassistant.components.smhi.const import DOMAIN diff --git a/tests/components/snips/test_init.py b/tests/components/snips/test_init.py index da2f23bc49c..9590473f218 100644 --- a/tests/components/snips/test_init.py +++ b/tests/components/snips/test_init.py @@ -1,4 +1,5 @@ """Test the Snips component.""" + import json import logging diff --git a/tests/components/songpal/test_config_flow.py b/tests/components/songpal/test_config_flow.py index 0a3d5d1acb2..338207a5d13 100644 --- a/tests/components/songpal/test_config_flow.py +++ b/tests/components/songpal/test_config_flow.py @@ -1,4 +1,5 @@ """Test the songpal config flow.""" + import copy import dataclasses from unittest.mock import patch diff --git a/tests/components/sonos/test_init.py b/tests/components/sonos/test_init.py index 83171e2029e..c073f9f636e 100644 --- a/tests/components/sonos/test_init.py +++ b/tests/components/sonos/test_init.py @@ -1,4 +1,5 @@ """Tests for the Sonos config flow.""" + import asyncio from datetime import timedelta import logging diff --git a/tests/components/sonos/test_plex_playback.py b/tests/components/sonos/test_plex_playback.py index 99269ca10ef..d5d5884bb50 100644 --- a/tests/components/sonos/test_plex_playback.py +++ b/tests/components/sonos/test_plex_playback.py @@ -1,4 +1,5 @@ """Tests for the Sonos Media Player platform.""" + import json from unittest.mock import Mock, patch diff --git a/tests/components/soundtouch/conftest.py b/tests/components/soundtouch/conftest.py index 1cdd37add4b..c81d76072d7 100644 --- a/tests/components/soundtouch/conftest.py +++ b/tests/components/soundtouch/conftest.py @@ -1,4 +1,5 @@ """Fixtures for Bose SoundTouch integration tests.""" + import pytest from requests_mock import Mocker diff --git a/tests/components/srp_energy/test_sensor.py b/tests/components/srp_energy/test_sensor.py index 2d49fd13bf1..70b4eae14df 100644 --- a/tests/components/srp_energy/test_sensor.py +++ b/tests/components/srp_energy/test_sensor.py @@ -1,4 +1,5 @@ """Tests for the srp_energy sensor platform.""" + import time from unittest.mock import patch diff --git a/tests/components/starline/test_config_flow.py b/tests/components/starline/test_config_flow.py index 4277f01037f..0d7d7cc0731 100644 --- a/tests/components/starline/test_config_flow.py +++ b/tests/components/starline/test_config_flow.py @@ -1,4 +1,5 @@ """Tests for StarLine config flow.""" + import requests_mock from homeassistant import config_entries diff --git a/tests/components/starlink/patchers.py b/tests/components/starlink/patchers.py index d83451ecc17..85e7a77c78c 100644 --- a/tests/components/starlink/patchers.py +++ b/tests/components/starlink/patchers.py @@ -1,4 +1,5 @@ """General Starlink patchers.""" + import json from unittest.mock import patch diff --git a/tests/components/steam_online/test_init.py b/tests/components/steam_online/test_init.py index e3f473e01c6..48584dab7a5 100644 --- a/tests/components/steam_online/test_init.py +++ b/tests/components/steam_online/test_init.py @@ -1,4 +1,5 @@ """Tests for the Steam component.""" + import steam from homeassistant.components.steam_online.const import DEFAULT_NAME, DOMAIN diff --git a/tests/components/stream/test_init.py b/tests/components/stream/test_init.py index 8372e5d5e61..1ae6f9e8931 100644 --- a/tests/components/stream/test_init.py +++ b/tests/components/stream/test_init.py @@ -1,4 +1,5 @@ """Test stream init.""" + import logging import av diff --git a/tests/components/stream/test_ll_hls.py b/tests/components/stream/test_ll_hls.py index cd13ab340c2..02fac835bdc 100644 --- a/tests/components/stream/test_ll_hls.py +++ b/tests/components/stream/test_ll_hls.py @@ -1,4 +1,5 @@ """The tests for hls streams.""" + import asyncio from collections import deque from http import HTTPStatus diff --git a/tests/components/stream/test_recorder.py b/tests/components/stream/test_recorder.py index b8c27037a25..29442620a10 100644 --- a/tests/components/stream/test_recorder.py +++ b/tests/components/stream/test_recorder.py @@ -1,4 +1,5 @@ """The tests for recording streams.""" + import asyncio from datetime import timedelta from io import BytesIO diff --git a/tests/components/stream/test_worker.py b/tests/components/stream/test_worker.py index bd998b008be..cf61368e12b 100644 --- a/tests/components/stream/test_worker.py +++ b/tests/components/stream/test_worker.py @@ -12,6 +12,7 @@ creates a packet sequence, with a mocked output buffer to capture the segments pushed to the output streams. The packet sequence can be used to exercise failure modes or corner cases like how out of order packets are handled. """ + import asyncio import fractions import io diff --git a/tests/components/subaru/test_diagnostics.py b/tests/components/subaru/test_diagnostics.py index 7da53c66c46..9445f1ca235 100644 --- a/tests/components/subaru/test_diagnostics.py +++ b/tests/components/subaru/test_diagnostics.py @@ -1,4 +1,5 @@ """Test Subaru diagnostics.""" + import json from unittest.mock import patch diff --git a/tests/components/surepetcare/test_lock.py b/tests/components/surepetcare/test_lock.py index 14a6a361793..d4275e8385c 100644 --- a/tests/components/surepetcare/test_lock.py +++ b/tests/components/surepetcare/test_lock.py @@ -1,4 +1,5 @@ """The tests for the Sure Petcare lock platform.""" + import pytest from surepy.exceptions import SurePetcareError diff --git a/tests/components/switch/test_device_action.py b/tests/components/switch/test_device_action.py index e86c32c1e32..a4e0472b2e7 100644 --- a/tests/components/switch/test_device_action.py +++ b/tests/components/switch/test_device_action.py @@ -1,4 +1,5 @@ """The test for switch device automation.""" + import pytest from pytest_unordered import unordered diff --git a/tests/components/switch/test_init.py b/tests/components/switch/test_init.py index deb7acb512a..62801346744 100644 --- a/tests/components/switch/test_init.py +++ b/tests/components/switch/test_init.py @@ -1,4 +1,5 @@ """The tests for the Switch component.""" + import pytest from homeassistant import core diff --git a/tests/components/switch/test_light.py b/tests/components/switch/test_light.py index 2254abc08f9..e7681575ce4 100644 --- a/tests/components/switch/test_light.py +++ b/tests/components/switch/test_light.py @@ -1,4 +1,5 @@ """The tests for the Light Switch platform.""" + import pytest from homeassistant.components.light import ( diff --git a/tests/components/switch/test_reproduce_state.py b/tests/components/switch/test_reproduce_state.py index 764efb17036..27bc492494c 100644 --- a/tests/components/switch/test_reproduce_state.py +++ b/tests/components/switch/test_reproduce_state.py @@ -1,4 +1,5 @@ """Test reproduce state for Switch.""" + import pytest from homeassistant.core import HomeAssistant, State diff --git a/tests/components/switchbee/test_config_flow.py b/tests/components/switchbee/test_config_flow.py index 98d413c3b96..c31ada589c8 100644 --- a/tests/components/switchbee/test_config_flow.py +++ b/tests/components/switchbee/test_config_flow.py @@ -1,4 +1,5 @@ """Test the SwitchBee Smart Home config flow.""" + import json from unittest.mock import patch diff --git a/tests/components/switcher_kis/test_sensor.py b/tests/components/switcher_kis/test_sensor.py index 03073b21a96..99bc0aa3a69 100644 --- a/tests/components/switcher_kis/test_sensor.py +++ b/tests/components/switcher_kis/test_sensor.py @@ -1,4 +1,5 @@ """Test the Switcher Sensor Platform.""" + import pytest from homeassistant.components.switcher_kis.const import DATA_DEVICE, DOMAIN diff --git a/tests/components/syncthru/test_config_flow.py b/tests/components/syncthru/test_config_flow.py index 948e55649fc..a413789dc60 100644 --- a/tests/components/syncthru/test_config_flow.py +++ b/tests/components/syncthru/test_config_flow.py @@ -1,4 +1,5 @@ """Tests for syncthru config flow.""" + import re from unittest.mock import patch diff --git a/tests/components/tado/test_service.py b/tests/components/tado/test_service.py index fe7e78f4ba5..759470cb5ea 100644 --- a/tests/components/tado/test_service.py +++ b/tests/components/tado/test_service.py @@ -1,4 +1,5 @@ """The serive tests for the tado platform.""" + import json from unittest.mock import patch diff --git a/tests/components/tag/test_trigger.py b/tests/components/tag/test_trigger.py index 2780b928027..53c511b8594 100644 --- a/tests/components/tag/test_trigger.py +++ b/tests/components/tag/test_trigger.py @@ -1,4 +1,5 @@ """Tests for tag triggers.""" + import pytest import homeassistant.components.automation as automation diff --git a/tests/components/tami4/test_init.py b/tests/components/tami4/test_init.py index ad3f50a377e..62e5861e13c 100644 --- a/tests/components/tami4/test_init.py +++ b/tests/components/tami4/test_init.py @@ -1,4 +1,5 @@ """Test the Tami4 component.""" + import pytest from Tami4EdgeAPI import exceptions diff --git a/tests/components/tasmota/test_binary_sensor.py b/tests/components/tasmota/test_binary_sensor.py index d5f1e4d7101..5abb9ab9bf2 100644 --- a/tests/components/tasmota/test_binary_sensor.py +++ b/tests/components/tasmota/test_binary_sensor.py @@ -1,4 +1,5 @@ """The tests for the Tasmota binary sensor platform.""" + import copy from datetime import timedelta import json diff --git a/tests/components/tasmota/test_common.py b/tests/components/tasmota/test_common.py index 1f414cb4e5a..360794e280f 100644 --- a/tests/components/tasmota/test_common.py +++ b/tests/components/tasmota/test_common.py @@ -1,4 +1,5 @@ """Common test objects.""" + import copy import json from unittest.mock import ANY diff --git a/tests/components/tasmota/test_cover.py b/tests/components/tasmota/test_cover.py index 26f8dee4a9d..a28739d59be 100644 --- a/tests/components/tasmota/test_cover.py +++ b/tests/components/tasmota/test_cover.py @@ -1,4 +1,5 @@ """The tests for the Tasmota cover platform.""" + import copy import json from unittest.mock import patch diff --git a/tests/components/tasmota/test_device_trigger.py b/tests/components/tasmota/test_device_trigger.py index 190c56b33f6..a5d30814b38 100644 --- a/tests/components/tasmota/test_device_trigger.py +++ b/tests/components/tasmota/test_device_trigger.py @@ -1,4 +1,5 @@ """The tests for Tasmota device triggers.""" + import copy import json from unittest.mock import Mock, patch diff --git a/tests/components/tasmota/test_discovery.py b/tests/components/tasmota/test_discovery.py index 4fd9f293498..122c22f752e 100644 --- a/tests/components/tasmota/test_discovery.py +++ b/tests/components/tasmota/test_discovery.py @@ -1,4 +1,5 @@ """The tests for the MQTT discovery.""" + import copy import json from unittest.mock import ANY, patch diff --git a/tests/components/tasmota/test_fan.py b/tests/components/tasmota/test_fan.py index 727fddc9bd3..654b8c955d2 100644 --- a/tests/components/tasmota/test_fan.py +++ b/tests/components/tasmota/test_fan.py @@ -1,4 +1,5 @@ """The tests for the Tasmota fan platform.""" + import copy import json from unittest.mock import patch diff --git a/tests/components/tasmota/test_init.py b/tests/components/tasmota/test_init.py index 09467b893e0..95fb186a46d 100644 --- a/tests/components/tasmota/test_init.py +++ b/tests/components/tasmota/test_init.py @@ -1,4 +1,5 @@ """The tests for the Tasmota binary sensor platform.""" + import copy import json from unittest.mock import call diff --git a/tests/components/tasmota/test_light.py b/tests/components/tasmota/test_light.py index 50f11fb7757..c4c3f0ec8dc 100644 --- a/tests/components/tasmota/test_light.py +++ b/tests/components/tasmota/test_light.py @@ -1,4 +1,5 @@ """The tests for the Tasmota light platform.""" + import copy import json from unittest.mock import patch diff --git a/tests/components/tasmota/test_mixins.py b/tests/components/tasmota/test_mixins.py index aad0d0e723a..86696a0813d 100644 --- a/tests/components/tasmota/test_mixins.py +++ b/tests/components/tasmota/test_mixins.py @@ -1,4 +1,5 @@ """The tests for the Tasmota mixins.""" + import copy import json from unittest.mock import call diff --git a/tests/components/tasmota/test_sensor.py b/tests/components/tasmota/test_sensor.py index dc4820779a6..61034ae66e9 100644 --- a/tests/components/tasmota/test_sensor.py +++ b/tests/components/tasmota/test_sensor.py @@ -1,4 +1,5 @@ """The tests for the Tasmota sensor platform.""" + import copy import datetime from datetime import timedelta diff --git a/tests/components/tasmota/test_switch.py b/tests/components/tasmota/test_switch.py index 1a16f372fc9..1ab5a50d3f5 100644 --- a/tests/components/tasmota/test_switch.py +++ b/tests/components/tasmota/test_switch.py @@ -1,4 +1,5 @@ """The tests for the Tasmota switch platform.""" + import copy import json from unittest.mock import patch diff --git a/tests/components/template/conftest.py b/tests/components/template/conftest.py index 207a7c87886..894c1777fef 100644 --- a/tests/components/template/conftest.py +++ b/tests/components/template/conftest.py @@ -1,4 +1,5 @@ """template conftest.""" + import pytest from homeassistant.setup import async_setup_component diff --git a/tests/components/template/test_alarm_control_panel.py b/tests/components/template/test_alarm_control_panel.py index ef2390680b6..eb4daa3bcb8 100644 --- a/tests/components/template/test_alarm_control_panel.py +++ b/tests/components/template/test_alarm_control_panel.py @@ -1,4 +1,5 @@ """The tests for the Template alarm control panel platform.""" + import pytest from homeassistant.components.alarm_control_panel import DOMAIN as ALARM_DOMAIN diff --git a/tests/components/template/test_button.py b/tests/components/template/test_button.py index ece568eee49..2e83100734a 100644 --- a/tests/components/template/test_button.py +++ b/tests/components/template/test_button.py @@ -1,4 +1,5 @@ """The tests for the Template button platform.""" + import datetime as dt from freezegun.api import FrozenDateTimeFactory diff --git a/tests/components/template/test_fan.py b/tests/components/template/test_fan.py index ccdafebd8bb..11a0afbaf33 100644 --- a/tests/components/template/test_fan.py +++ b/tests/components/template/test_fan.py @@ -1,4 +1,5 @@ """The tests for the Template fan platform.""" + import pytest import voluptuous as vol diff --git a/tests/components/template/test_light.py b/tests/components/template/test_light.py index ec830d4daf6..a40f093a573 100644 --- a/tests/components/template/test_light.py +++ b/tests/components/template/test_light.py @@ -1,4 +1,5 @@ """The tests for the Template light platform.""" + import pytest import homeassistant.components.light as light diff --git a/tests/components/template/test_lock.py b/tests/components/template/test_lock.py index 118a73264d7..77b7c9657d4 100644 --- a/tests/components/template/test_lock.py +++ b/tests/components/template/test_lock.py @@ -1,4 +1,5 @@ """The tests for the Template lock platform.""" + import pytest from homeassistant import setup diff --git a/tests/components/template/test_switch.py b/tests/components/template/test_switch.py index 1e979fc9926..acf80006798 100644 --- a/tests/components/template/test_switch.py +++ b/tests/components/template/test_switch.py @@ -1,4 +1,5 @@ """The tests for the Template switch platform.""" + import pytest from homeassistant import setup diff --git a/tests/components/template/test_template_entity.py b/tests/components/template/test_template_entity.py index 4fe3d7cb780..dcceea95181 100644 --- a/tests/components/template/test_template_entity.py +++ b/tests/components/template/test_template_entity.py @@ -1,4 +1,5 @@ """Test template entity.""" + import pytest from homeassistant.components.template import template_entity diff --git a/tests/components/template/test_vacuum.py b/tests/components/template/test_vacuum.py index e6850728450..2c6f083abce 100644 --- a/tests/components/template/test_vacuum.py +++ b/tests/components/template/test_vacuum.py @@ -1,4 +1,5 @@ """The tests for the Template vacuum platform.""" + import pytest from homeassistant import setup diff --git a/tests/components/tessie/test_binary_sensors.py b/tests/components/tessie/test_binary_sensors.py index b6dccd9d3b1..0ced8a6d8aa 100644 --- a/tests/components/tessie/test_binary_sensors.py +++ b/tests/components/tessie/test_binary_sensors.py @@ -1,4 +1,5 @@ """Test the Tessie binary sensor platform.""" + import pytest from syrupy import SnapshotAssertion diff --git a/tests/components/text/test_device_action.py b/tests/components/text/test_device_action.py index 59b77ecfa06..e2357fc7794 100644 --- a/tests/components/text/test_device_action.py +++ b/tests/components/text/test_device_action.py @@ -1,4 +1,5 @@ """The tests for Text device actions.""" + import pytest from pytest_unordered import unordered import voluptuous_serialize diff --git a/tests/components/text/test_reproduce_state.py b/tests/components/text/test_reproduce_state.py index 94c9b8127f6..d87e0e983de 100644 --- a/tests/components/text/test_reproduce_state.py +++ b/tests/components/text/test_reproduce_state.py @@ -1,4 +1,5 @@ """Test reproduce state for Text entities.""" + import pytest from homeassistant.components.text.const import ( diff --git a/tests/components/thread/test_dataset_store.py b/tests/components/thread/test_dataset_store.py index bcc16de4ed2..a0d85fc6cea 100644 --- a/tests/components/thread/test_dataset_store.py +++ b/tests/components/thread/test_dataset_store.py @@ -1,4 +1,5 @@ """Test the thread dataset store.""" + import asyncio from typing import Any from unittest.mock import ANY, AsyncMock, patch diff --git a/tests/components/threshold/test_init.py b/tests/components/threshold/test_init.py index 82d183ad380..a580ec50a9d 100644 --- a/tests/components/threshold/test_init.py +++ b/tests/components/threshold/test_init.py @@ -1,4 +1,5 @@ """Test the Min/Max integration.""" + import pytest from homeassistant.components.threshold.const import DOMAIN diff --git a/tests/components/tibber/conftest.py b/tests/components/tibber/conftest.py index 3fa503ed002..da3f3df1bd9 100644 --- a/tests/components/tibber/conftest.py +++ b/tests/components/tibber/conftest.py @@ -1,4 +1,5 @@ """Test helpers for Tibber.""" + import pytest from homeassistant.components.tibber.const import DOMAIN diff --git a/tests/components/tibber/test_common.py b/tests/components/tibber/test_common.py index 7faa07a6d9f..8d6b22ad7f7 100644 --- a/tests/components/tibber/test_common.py +++ b/tests/components/tibber/test_common.py @@ -1,4 +1,5 @@ """Test common.""" + import datetime as dt from unittest.mock import AsyncMock diff --git a/tests/components/tile/conftest.py b/tests/components/tile/conftest.py index 577abd6fa70..964986ba151 100644 --- a/tests/components/tile/conftest.py +++ b/tests/components/tile/conftest.py @@ -1,4 +1,5 @@ """Define test fixtures for Tile.""" + import json from unittest.mock import AsyncMock, Mock, patch diff --git a/tests/components/timer/test_reproduce_state.py b/tests/components/timer/test_reproduce_state.py index 2d4fca68dfe..fcc331fef50 100644 --- a/tests/components/timer/test_reproduce_state.py +++ b/tests/components/timer/test_reproduce_state.py @@ -1,4 +1,5 @@ """Test reproduce state for Timer.""" + import pytest from homeassistant.components.timer import ( diff --git a/tests/components/tomorrowio/conftest.py b/tests/components/tomorrowio/conftest.py index 2d36d68c57a..94adda43f23 100644 --- a/tests/components/tomorrowio/conftest.py +++ b/tests/components/tomorrowio/conftest.py @@ -1,4 +1,5 @@ """Configure py.test.""" + import json from unittest.mock import PropertyMock, patch diff --git a/tests/components/tplink/test_diagnostics.py b/tests/components/tplink/test_diagnostics.py index 3ef42c48b2f..bda5b143a6a 100644 --- a/tests/components/tplink/test_diagnostics.py +++ b/tests/components/tplink/test_diagnostics.py @@ -1,4 +1,5 @@ """Tests for the diagnostics data provided by the TP-Link integration.""" + import json from kasa import SmartDevice diff --git a/tests/components/trace/test_websocket_api.py b/tests/components/trace/test_websocket_api.py index 511667a7462..5e584de2b4f 100644 --- a/tests/components/trace/test_websocket_api.py +++ b/tests/components/trace/test_websocket_api.py @@ -1,4 +1,5 @@ """Test Trace websocket API.""" + import asyncio from collections import defaultdict import json diff --git a/tests/components/tradfri/test_util.py b/tests/components/tradfri/test_util.py index c4f3509dfef..37b532c7798 100644 --- a/tests/components/tradfri/test_util.py +++ b/tests/components/tradfri/test_util.py @@ -1,4 +1,5 @@ """Tradfri utility function tests.""" + import pytest from homeassistant.components.tradfri.fan import _from_fan_percentage, _from_fan_speed diff --git a/tests/components/tts/test_init.py b/tests/components/tts/test_init.py index d56542b2a57..cbf18fe8771 100644 --- a/tests/components/tts/test_init.py +++ b/tests/components/tts/test_init.py @@ -1,4 +1,5 @@ """The tests for the TTS component.""" + import asyncio from http import HTTPStatus from typing import Any diff --git a/tests/components/twentemilieu/test_sensor.py b/tests/components/twentemilieu/test_sensor.py index e4b845264db..6fd39e38d48 100644 --- a/tests/components/twentemilieu/test_sensor.py +++ b/tests/components/twentemilieu/test_sensor.py @@ -1,4 +1,5 @@ """Tests for the Twente Milieu sensors.""" + import pytest from syrupy.assertion import SnapshotAssertion diff --git a/tests/components/twitch/test_init.py b/tests/components/twitch/test_init.py index da03857a95d..d3b9313c46e 100644 --- a/tests/components/twitch/test_init.py +++ b/tests/components/twitch/test_init.py @@ -1,4 +1,5 @@ """Tests for YouTube.""" + import http import time from unittest.mock import patch diff --git a/tests/components/uk_transport/test_sensor.py b/tests/components/uk_transport/test_sensor.py index d60966fc6d7..baed4dbd44b 100644 --- a/tests/components/uk_transport/test_sensor.py +++ b/tests/components/uk_transport/test_sensor.py @@ -1,4 +1,5 @@ """The tests for the uk_transport platform.""" + import re from unittest.mock import patch diff --git a/tests/components/unifi/test_config_flow.py b/tests/components/unifi/test_config_flow.py index 572f7a2ff05..0f8efc8b483 100644 --- a/tests/components/unifi/test_config_flow.py +++ b/tests/components/unifi/test_config_flow.py @@ -1,4 +1,5 @@ """Test UniFi Network config flow.""" + import socket from unittest.mock import patch diff --git a/tests/components/uptime/test_sensor.py b/tests/components/uptime/test_sensor.py index 41c097badd1..169b1e80c7d 100644 --- a/tests/components/uptime/test_sensor.py +++ b/tests/components/uptime/test_sensor.py @@ -1,4 +1,5 @@ """The tests for the uptime sensor platform.""" + import pytest from syrupy.assertion import SnapshotAssertion from syrupy.filters import props diff --git a/tests/components/uptimerobot/test_diagnostics.py b/tests/components/uptimerobot/test_diagnostics.py index 9eca73d0240..12a91077552 100644 --- a/tests/components/uptimerobot/test_diagnostics.py +++ b/tests/components/uptimerobot/test_diagnostics.py @@ -1,4 +1,5 @@ """Test UptimeRobot diagnostics.""" + import json from unittest.mock import patch diff --git a/tests/components/usb/test_init.py b/tests/components/usb/test_init.py index a1637f62b01..dd6d9fff874 100644 --- a/tests/components/usb/test_init.py +++ b/tests/components/usb/test_init.py @@ -1,4 +1,5 @@ """Tests for the USB Discovery integration.""" + import os import sys from unittest.mock import MagicMock, Mock, call, patch, sentinel diff --git a/tests/components/usgs_earthquakes_feed/test_geo_location.py b/tests/components/usgs_earthquakes_feed/test_geo_location.py index 6307125930c..effaa119a07 100644 --- a/tests/components/usgs_earthquakes_feed/test_geo_location.py +++ b/tests/components/usgs_earthquakes_feed/test_geo_location.py @@ -1,4 +1,5 @@ """The tests for the USGS Earthquake Hazards Program Feed platform.""" + import datetime from unittest.mock import ANY, MagicMock, call, patch diff --git a/tests/components/vacuum/test_device_action.py b/tests/components/vacuum/test_device_action.py index cf0ab3c20d8..6b7b56ccf18 100644 --- a/tests/components/vacuum/test_device_action.py +++ b/tests/components/vacuum/test_device_action.py @@ -1,4 +1,5 @@ """The tests for Vacuum device actions.""" + import pytest from pytest_unordered import unordered diff --git a/tests/components/vacuum/test_device_condition.py b/tests/components/vacuum/test_device_condition.py index a2ba75cc752..029765afd77 100644 --- a/tests/components/vacuum/test_device_condition.py +++ b/tests/components/vacuum/test_device_condition.py @@ -1,4 +1,5 @@ """The tests for Vacuum device conditions.""" + import pytest from pytest_unordered import unordered diff --git a/tests/components/vacuum/test_reproduce_state.py b/tests/components/vacuum/test_reproduce_state.py index 2f7817a3b9e..ff8da28e98c 100644 --- a/tests/components/vacuum/test_reproduce_state.py +++ b/tests/components/vacuum/test_reproduce_state.py @@ -1,4 +1,5 @@ """Test reproduce state for Vacuum.""" + import pytest from homeassistant.components.vacuum import ( diff --git a/tests/components/vacuum/test_significant_change.py b/tests/components/vacuum/test_significant_change.py index 5f46080fb8d..f4def0ccbf6 100644 --- a/tests/components/vacuum/test_significant_change.py +++ b/tests/components/vacuum/test_significant_change.py @@ -1,4 +1,5 @@ """Test the Vacuum significant change platform.""" + import pytest from homeassistant.components.vacuum import ( diff --git a/tests/components/vallox/test_number.py b/tests/components/vallox/test_number.py index 29de3d54d1c..2e440c5e304 100644 --- a/tests/components/vallox/test_number.py +++ b/tests/components/vallox/test_number.py @@ -1,4 +1,5 @@ """Tests for Vallox number platform.""" + import pytest from homeassistant.components.number.const import ( diff --git a/tests/components/venstar/test_config_flow.py b/tests/components/venstar/test_config_flow.py index 521e5a8512e..c7a0f0a394f 100644 --- a/tests/components/venstar/test_config_flow.py +++ b/tests/components/venstar/test_config_flow.py @@ -1,4 +1,5 @@ """Test the Venstar config flow.""" + import logging from unittest.mock import patch diff --git a/tests/components/vesync/common.py b/tests/components/vesync/common.py index 47cce03afe3..2e5a973c143 100644 --- a/tests/components/vesync/common.py +++ b/tests/components/vesync/common.py @@ -1,4 +1,5 @@ """Common methods used across tests for VeSync.""" + import json import requests_mock diff --git a/tests/components/vesync/test_fan.py b/tests/components/vesync/test_fan.py index 26ac565e1a6..4d444036a60 100644 --- a/tests/components/vesync/test_fan.py +++ b/tests/components/vesync/test_fan.py @@ -1,4 +1,5 @@ """Tests for the fan module.""" + import pytest import requests_mock from syrupy import SnapshotAssertion diff --git a/tests/components/vesync/test_light.py b/tests/components/vesync/test_light.py index b293d6e808e..866e6b295bf 100644 --- a/tests/components/vesync/test_light.py +++ b/tests/components/vesync/test_light.py @@ -1,4 +1,5 @@ """Tests for the light module.""" + import pytest import requests_mock from syrupy import SnapshotAssertion diff --git a/tests/components/vesync/test_sensor.py b/tests/components/vesync/test_sensor.py index c50b916df66..bd3a8eb8591 100644 --- a/tests/components/vesync/test_sensor.py +++ b/tests/components/vesync/test_sensor.py @@ -1,4 +1,5 @@ """Tests for the sensor module.""" + import pytest import requests_mock from syrupy import SnapshotAssertion diff --git a/tests/components/vesync/test_switch.py b/tests/components/vesync/test_switch.py index af721724d91..111f2b80960 100644 --- a/tests/components/vesync/test_switch.py +++ b/tests/components/vesync/test_switch.py @@ -1,4 +1,5 @@ """Tests for the switch module.""" + import pytest import requests_mock from syrupy import SnapshotAssertion diff --git a/tests/components/vizio/test_config_flow.py b/tests/components/vizio/test_config_flow.py index 578d79fcba0..d19cf319a5a 100644 --- a/tests/components/vizio/test_config_flow.py +++ b/tests/components/vizio/test_config_flow.py @@ -1,4 +1,5 @@ """Tests for Vizio config flow.""" + import dataclasses import pytest diff --git a/tests/components/voip/test_sip.py b/tests/components/voip/test_sip.py index 975b8f326d9..2e144b87ec0 100644 --- a/tests/components/voip/test_sip.py +++ b/tests/components/voip/test_sip.py @@ -1,4 +1,5 @@ """Test SIP server.""" + import socket import pytest diff --git a/tests/components/voip/test_voip.py b/tests/components/voip/test_voip.py index 703b99db962..3d34218e999 100644 --- a/tests/components/voip/test_voip.py +++ b/tests/components/voip/test_voip.py @@ -1,4 +1,5 @@ """Test VoIP protocol.""" + import asyncio import io import time diff --git a/tests/components/vulcan/test_config_flow.py b/tests/components/vulcan/test_config_flow.py index d575fe73600..97dd47d7ea4 100644 --- a/tests/components/vulcan/test_config_flow.py +++ b/tests/components/vulcan/test_config_flow.py @@ -1,4 +1,5 @@ """Test the Uonet+ Vulcan config flow.""" + import json from unittest import mock from unittest.mock import patch diff --git a/tests/components/vultr/conftest.py b/tests/components/vultr/conftest.py index 0d69cf53335..f8ecd1cf321 100644 --- a/tests/components/vultr/conftest.py +++ b/tests/components/vultr/conftest.py @@ -1,4 +1,5 @@ """Test configuration for the Vultr tests.""" + import json from unittest.mock import patch diff --git a/tests/components/vultr/test_binary_sensor.py b/tests/components/vultr/test_binary_sensor.py index d7f421e4463..f6b46b54d25 100644 --- a/tests/components/vultr/test_binary_sensor.py +++ b/tests/components/vultr/test_binary_sensor.py @@ -1,4 +1,5 @@ """Test the Vultr binary sensor platform.""" + import pytest import voluptuous as vol diff --git a/tests/components/vultr/test_sensor.py b/tests/components/vultr/test_sensor.py index 0f2b1b7d4a4..f9f922b35d4 100644 --- a/tests/components/vultr/test_sensor.py +++ b/tests/components/vultr/test_sensor.py @@ -1,4 +1,5 @@ """The tests for the Vultr sensor platform.""" + import pytest import voluptuous as vol diff --git a/tests/components/wallbox/conftest.py b/tests/components/wallbox/conftest.py index 4677dc95e6f..72d493ceb69 100644 --- a/tests/components/wallbox/conftest.py +++ b/tests/components/wallbox/conftest.py @@ -1,4 +1,5 @@ """Test fixtures for the Wallbox integration.""" + import pytest from homeassistant.components.wallbox.const import CONF_STATION, DOMAIN diff --git a/tests/components/wallbox/test_init.py b/tests/components/wallbox/test_init.py index 93082737f1f..3dfc391aa3b 100644 --- a/tests/components/wallbox/test_init.py +++ b/tests/components/wallbox/test_init.py @@ -1,4 +1,5 @@ """Test Wallbox Init Component.""" + import json import requests_mock diff --git a/tests/components/wallbox/test_lock.py b/tests/components/wallbox/test_lock.py index 065a43b2789..637f0c827f4 100644 --- a/tests/components/wallbox/test_lock.py +++ b/tests/components/wallbox/test_lock.py @@ -1,4 +1,5 @@ """Test Wallbox Lock component.""" + import json import pytest diff --git a/tests/components/wallbox/test_number.py b/tests/components/wallbox/test_number.py index 837df4dfd47..5d782224ce5 100644 --- a/tests/components/wallbox/test_number.py +++ b/tests/components/wallbox/test_number.py @@ -1,4 +1,5 @@ """Test Wallbox Switch component.""" + import json import pytest diff --git a/tests/components/wallbox/test_switch.py b/tests/components/wallbox/test_switch.py index edd85c6ccc7..d06251db003 100644 --- a/tests/components/wallbox/test_switch.py +++ b/tests/components/wallbox/test_switch.py @@ -1,4 +1,5 @@ """Test Wallbox Lock component.""" + import json import pytest diff --git a/tests/components/waqi/test_config_flow.py b/tests/components/waqi/test_config_flow.py index ecc7e07158d..f19d0991f46 100644 --- a/tests/components/waqi/test_config_flow.py +++ b/tests/components/waqi/test_config_flow.py @@ -1,4 +1,5 @@ """Test the World Air Quality Index (WAQI) config flow.""" + import json from typing import Any from unittest.mock import AsyncMock, patch diff --git a/tests/components/waqi/test_sensor.py b/tests/components/waqi/test_sensor.py index ebe0c87736d..7b19fbee083 100644 --- a/tests/components/waqi/test_sensor.py +++ b/tests/components/waqi/test_sensor.py @@ -1,4 +1,5 @@ """Test the World Air Quality Index (WAQI) sensor.""" + import json from unittest.mock import patch diff --git a/tests/components/water_heater/test_device_action.py b/tests/components/water_heater/test_device_action.py index 8254fb77a77..1a3645af80b 100644 --- a/tests/components/water_heater/test_device_action.py +++ b/tests/components/water_heater/test_device_action.py @@ -1,4 +1,5 @@ """The tests for Water Heater device actions.""" + import pytest from pytest_unordered import unordered diff --git a/tests/components/water_heater/test_reproduce_state.py b/tests/components/water_heater/test_reproduce_state.py index a050d28a7d2..2aa10fa004f 100644 --- a/tests/components/water_heater/test_reproduce_state.py +++ b/tests/components/water_heater/test_reproduce_state.py @@ -1,4 +1,5 @@ """Test reproduce state for Water heater.""" + import pytest from homeassistant.components.water_heater import ( diff --git a/tests/components/water_heater/test_significant_change.py b/tests/components/water_heater/test_significant_change.py index 40803eea09a..dd0a8cc5924 100644 --- a/tests/components/water_heater/test_significant_change.py +++ b/tests/components/water_heater/test_significant_change.py @@ -1,4 +1,5 @@ """Test the Water Heater significant change platform.""" + import pytest from homeassistant.components.water_heater import ( diff --git a/tests/components/watttime/conftest.py b/tests/components/watttime/conftest.py index f636ffefcfb..72bdc2d3419 100644 --- a/tests/components/watttime/conftest.py +++ b/tests/components/watttime/conftest.py @@ -1,4 +1,5 @@ """Define test fixtures for WattTime.""" + import json from unittest.mock import AsyncMock, Mock, patch diff --git a/tests/components/waze_travel_time/test_config_flow.py b/tests/components/waze_travel_time/test_config_flow.py index f1fd3041d46..9bd5016c2f4 100644 --- a/tests/components/waze_travel_time/test_config_flow.py +++ b/tests/components/waze_travel_time/test_config_flow.py @@ -1,4 +1,5 @@ """Test the Waze Travel Time config flow.""" + import pytest from homeassistant import config_entries, data_entry_flow diff --git a/tests/components/waze_travel_time/test_sensor.py b/tests/components/waze_travel_time/test_sensor.py index 60e5535fdba..0b2ec4297e6 100644 --- a/tests/components/waze_travel_time/test_sensor.py +++ b/tests/components/waze_travel_time/test_sensor.py @@ -1,4 +1,5 @@ """Test Waze Travel Time sensors.""" + import pytest from pywaze.route_calculator import WRCError diff --git a/tests/components/weatherflow/conftest.py b/tests/components/weatherflow/conftest.py index 0bf6b69b9a7..dc533f153e2 100644 --- a/tests/components/weatherflow/conftest.py +++ b/tests/components/weatherflow/conftest.py @@ -1,4 +1,5 @@ """Fixtures for Weatherflow integration tests.""" + import asyncio from collections.abc import Generator from unittest.mock import AsyncMock, patch diff --git a/tests/components/weatherflow_cloud/test_config_flow.py b/tests/components/weatherflow_cloud/test_config_flow.py index 9a6c64fc32c..cef0e224434 100644 --- a/tests/components/weatherflow_cloud/test_config_flow.py +++ b/tests/components/weatherflow_cloud/test_config_flow.py @@ -1,4 +1,5 @@ """Test the WeatherflowCloud config flow.""" + import pytest from homeassistant import config_entries diff --git a/tests/components/webmin/test_sensor.py b/tests/components/webmin/test_sensor.py index 528aebca990..5fb874825a3 100644 --- a/tests/components/webmin/test_sensor.py +++ b/tests/components/webmin/test_sensor.py @@ -1,4 +1,5 @@ """Test cases for the Webmin sensors.""" + import pytest from syrupy.assertion import SnapshotAssertion diff --git a/tests/components/webostv/test_config_flow.py b/tests/components/webostv/test_config_flow.py index ad57b4647ea..07a11b5bf29 100644 --- a/tests/components/webostv/test_config_flow.py +++ b/tests/components/webostv/test_config_flow.py @@ -1,4 +1,5 @@ """Test the WebOS Tv config flow.""" + import dataclasses from unittest.mock import Mock diff --git a/tests/components/webostv/test_device_trigger.py b/tests/components/webostv/test_device_trigger.py index db3bd85bbf7..5205f6ae7a1 100644 --- a/tests/components/webostv/test_device_trigger.py +++ b/tests/components/webostv/test_device_trigger.py @@ -1,4 +1,5 @@ """The tests for WebOS TV device triggers.""" + import pytest from homeassistant.components import automation diff --git a/tests/components/websocket_api/conftest.py b/tests/components/websocket_api/conftest.py index 75a7834f629..7cfd0e204a7 100644 --- a/tests/components/websocket_api/conftest.py +++ b/tests/components/websocket_api/conftest.py @@ -1,4 +1,5 @@ """Fixtures for websocket tests.""" + import pytest from homeassistant.components.websocket_api.auth import TYPE_AUTH_REQUIRED diff --git a/tests/components/websocket_api/test_commands.py b/tests/components/websocket_api/test_commands.py index a6a2fb06d7b..5e4eff5da53 100644 --- a/tests/components/websocket_api/test_commands.py +++ b/tests/components/websocket_api/test_commands.py @@ -1,4 +1,5 @@ """Tests for WebSocket API commands.""" + import asyncio from copy import deepcopy import logging diff --git a/tests/components/websocket_api/test_connection.py b/tests/components/websocket_api/test_connection.py index 7a6bd86586c..d6c2765522e 100644 --- a/tests/components/websocket_api/test_connection.py +++ b/tests/components/websocket_api/test_connection.py @@ -1,4 +1,5 @@ """Test WebSocket Connection class.""" + import logging from typing import Any from unittest.mock import AsyncMock, Mock, patch diff --git a/tests/components/websocket_api/test_http.py b/tests/components/websocket_api/test_http.py index 090f034b3d3..465c4aea749 100644 --- a/tests/components/websocket_api/test_http.py +++ b/tests/components/websocket_api/test_http.py @@ -1,4 +1,5 @@ """Test Websocket API http module.""" + import asyncio from datetime import timedelta from typing import Any, cast diff --git a/tests/components/websocket_api/test_messages.py b/tests/components/websocket_api/test_messages.py index 5fc0e4ea315..350aed8b5f7 100644 --- a/tests/components/websocket_api/test_messages.py +++ b/tests/components/websocket_api/test_messages.py @@ -1,4 +1,5 @@ """Test Websocket API messages module.""" + import pytest from homeassistant.components.websocket_api.messages import ( diff --git a/tests/components/wemo/conftest.py b/tests/components/wemo/conftest.py index 6c4d28ecae7..cdf1e7deb68 100644 --- a/tests/components/wemo/conftest.py +++ b/tests/components/wemo/conftest.py @@ -1,4 +1,5 @@ """Fixtures for pywemo.""" + import contextlib from unittest.mock import create_autospec, patch diff --git a/tests/components/wemo/entity_test_helpers.py b/tests/components/wemo/entity_test_helpers.py index 90bfadf402f..f999de408c0 100644 --- a/tests/components/wemo/entity_test_helpers.py +++ b/tests/components/wemo/entity_test_helpers.py @@ -2,6 +2,7 @@ This is not a test module. These test methods are used by the platform test modules. """ + import asyncio import threading diff --git a/tests/components/wemo/test_device_trigger.py b/tests/components/wemo/test_device_trigger.py index 9140f5f1e35..47b704dae5d 100644 --- a/tests/components/wemo/test_device_trigger.py +++ b/tests/components/wemo/test_device_trigger.py @@ -1,4 +1,5 @@ """Verify that WeMo device triggers work as expected.""" + import pytest from pytest_unordered import unordered from pywemo.subscribe import EVENT_TYPE_LONG_PRESS diff --git a/tests/components/wemo/test_fan.py b/tests/components/wemo/test_fan.py index 48ad5774b0a..7a1bb2c628b 100644 --- a/tests/components/wemo/test_fan.py +++ b/tests/components/wemo/test_fan.py @@ -1,4 +1,5 @@ """Tests for the Wemo fan entity.""" + import pytest from pywemo.exceptions import ActionException from pywemo.ouimeaux_device.humidifier import DesiredHumidity, FanMode diff --git a/tests/components/wemo/test_init.py b/tests/components/wemo/test_init.py index 1d4271063f2..5512c2ee989 100644 --- a/tests/components/wemo/test_init.py +++ b/tests/components/wemo/test_init.py @@ -1,4 +1,5 @@ """Tests for the wemo component.""" + import asyncio from datetime import timedelta from unittest.mock import create_autospec, patch diff --git a/tests/components/wemo/test_light_dimmer.py b/tests/components/wemo/test_light_dimmer.py index 51ddc6cab2d..96d27b56963 100644 --- a/tests/components/wemo/test_light_dimmer.py +++ b/tests/components/wemo/test_light_dimmer.py @@ -1,4 +1,5 @@ """Tests for the Wemo standalone/non-bridge light entity.""" + import pytest from pywemo.exceptions import ActionException diff --git a/tests/components/wemo/test_switch.py b/tests/components/wemo/test_switch.py index 4df13a777d4..b73844bdb58 100644 --- a/tests/components/wemo/test_switch.py +++ b/tests/components/wemo/test_switch.py @@ -1,4 +1,5 @@ """Tests for the Wemo switch entity.""" + import pytest import pywemo diff --git a/tests/components/wemo/test_wemo_device.py b/tests/components/wemo/test_wemo_device.py index 5c8353fc8bc..7d23b590b57 100644 --- a/tests/components/wemo/test_wemo_device.py +++ b/tests/components/wemo/test_wemo_device.py @@ -1,4 +1,5 @@ """Tests for wemo_device.py.""" + import asyncio from dataclasses import asdict from datetime import timedelta diff --git a/tests/components/wiffi/test_config_flow.py b/tests/components/wiffi/test_config_flow.py index bf0b072df8c..14cb8a03f7a 100644 --- a/tests/components/wiffi/test_config_flow.py +++ b/tests/components/wiffi/test_config_flow.py @@ -1,4 +1,5 @@ """Test the wiffi integration config flow.""" + import errno from unittest.mock import patch diff --git a/tests/components/wilight/test_config_flow.py b/tests/components/wilight/test_config_flow.py index a46af6e7d82..e3496010c95 100644 --- a/tests/components/wilight/test_config_flow.py +++ b/tests/components/wilight/test_config_flow.py @@ -1,4 +1,5 @@ """Test the WiLight config flow.""" + import dataclasses from unittest.mock import patch diff --git a/tests/components/wiz/test_init.py b/tests/components/wiz/test_init.py index 41871381d3c..bd494da95b7 100644 --- a/tests/components/wiz/test_init.py +++ b/tests/components/wiz/test_init.py @@ -1,4 +1,5 @@ """Tests for wiz integration.""" + import datetime from unittest.mock import AsyncMock, patch diff --git a/tests/components/wled/test_binary_sensor.py b/tests/components/wled/test_binary_sensor.py index eb5faadd530..aa75b0c6696 100644 --- a/tests/components/wled/test_binary_sensor.py +++ b/tests/components/wled/test_binary_sensor.py @@ -1,4 +1,5 @@ """Tests for the WLED binary sensor platform.""" + import pytest from syrupy.assertion import SnapshotAssertion diff --git a/tests/components/wled/test_coordinator.py b/tests/components/wled/test_coordinator.py index 89817fb8569..14e8b620983 100644 --- a/tests/components/wled/test_coordinator.py +++ b/tests/components/wled/test_coordinator.py @@ -1,4 +1,5 @@ """Tests for the coordinator of the WLED integration.""" + import asyncio from collections.abc import Callable from copy import deepcopy diff --git a/tests/components/wled/test_init.py b/tests/components/wled/test_init.py index 38793898243..6f4c47ec201 100644 --- a/tests/components/wled/test_init.py +++ b/tests/components/wled/test_init.py @@ -1,4 +1,5 @@ """Tests for the WLED integration.""" + import asyncio from collections.abc import Callable from unittest.mock import AsyncMock, MagicMock, patch diff --git a/tests/components/wled/test_light.py b/tests/components/wled/test_light.py index fc1d5503c07..2b64619e306 100644 --- a/tests/components/wled/test_light.py +++ b/tests/components/wled/test_light.py @@ -1,4 +1,5 @@ """Tests for the WLED light platform.""" + import json from unittest.mock import MagicMock diff --git a/tests/components/wled/test_number.py b/tests/components/wled/test_number.py index e91ec4f2e66..b692de37282 100644 --- a/tests/components/wled/test_number.py +++ b/tests/components/wled/test_number.py @@ -1,4 +1,5 @@ """Tests for the WLED number platform.""" + import json from unittest.mock import MagicMock diff --git a/tests/components/wled/test_select.py b/tests/components/wled/test_select.py index 219ec945021..380af1a286a 100644 --- a/tests/components/wled/test_select.py +++ b/tests/components/wled/test_select.py @@ -1,4 +1,5 @@ """Tests for the WLED select platform.""" + import json from unittest.mock import MagicMock diff --git a/tests/components/wled/test_switch.py b/tests/components/wled/test_switch.py index 40b7783fc04..6dfd62e363f 100644 --- a/tests/components/wled/test_switch.py +++ b/tests/components/wled/test_switch.py @@ -1,4 +1,5 @@ """Tests for the WLED switch platform.""" + import json from unittest.mock import MagicMock diff --git a/tests/components/worldclock/test_sensor.py b/tests/components/worldclock/test_sensor.py index 3ec7579bf68..00195a49827 100644 --- a/tests/components/worldclock/test_sensor.py +++ b/tests/components/worldclock/test_sensor.py @@ -1,4 +1,5 @@ """The test for the World clock sensor platform.""" + import pytest from homeassistant.core import HomeAssistant diff --git a/tests/components/xiaomi_ble/test_device_trigger.py b/tests/components/xiaomi_ble/test_device_trigger.py index 28195f784e8..6c6ad1c0f94 100644 --- a/tests/components/xiaomi_ble/test_device_trigger.py +++ b/tests/components/xiaomi_ble/test_device_trigger.py @@ -1,4 +1,5 @@ """Test Xiaomi BLE events.""" + import pytest from homeassistant.components import automation diff --git a/tests/components/xiaomi_ble/test_event.py b/tests/components/xiaomi_ble/test_event.py index a0e84c0ac2e..785c336106e 100644 --- a/tests/components/xiaomi_ble/test_event.py +++ b/tests/components/xiaomi_ble/test_event.py @@ -1,4 +1,5 @@ """Test the Xiaomi BLE events.""" + import pytest from homeassistant.components.event import ATTR_EVENT_TYPE diff --git a/tests/components/yalexs_ble/test_config_flow.py b/tests/components/yalexs_ble/test_config_flow.py index a8ce68a3209..510e2c8be56 100644 --- a/tests/components/yalexs_ble/test_config_flow.py +++ b/tests/components/yalexs_ble/test_config_flow.py @@ -1,4 +1,5 @@ """Test the Yale Access Bluetooth config flow.""" + import asyncio from unittest.mock import AsyncMock, MagicMock, Mock, patch diff --git a/tests/components/yandex_transport/test_yandex_transport_sensor.py b/tests/components/yandex_transport/test_yandex_transport_sensor.py index bf9d0fd92b3..deb4fd1f360 100644 --- a/tests/components/yandex_transport/test_yandex_transport_sensor.py +++ b/tests/components/yandex_transport/test_yandex_transport_sensor.py @@ -1,4 +1,5 @@ """Tests for the yandex transport platform.""" + import json from unittest.mock import AsyncMock, patch diff --git a/tests/components/yeelight/conftest.py b/tests/components/yeelight/conftest.py index 9a9b9d19ec2..e4ce0afc9bf 100644 --- a/tests/components/yeelight/conftest.py +++ b/tests/components/yeelight/conftest.py @@ -1,4 +1,5 @@ """yeelight conftest.""" + import pytest from tests.components.light.conftest import mock_light_profiles # noqa: F401 diff --git a/tests/components/yolink/test_device_trigger.py b/tests/components/yolink/test_device_trigger.py index 0e258d0e1c7..678fe6e35cc 100644 --- a/tests/components/yolink/test_device_trigger.py +++ b/tests/components/yolink/test_device_trigger.py @@ -1,4 +1,5 @@ """The tests for YoLink device triggers.""" + import pytest from pytest_unordered import unordered from yolink.const import ATTR_DEVICE_DIMMER, ATTR_DEVICE_SMART_REMOTER diff --git a/tests/components/youtube/test_init.py b/tests/components/youtube/test_init.py index bd3babdc383..a6c3acbdd3b 100644 --- a/tests/components/youtube/test_init.py +++ b/tests/components/youtube/test_init.py @@ -1,4 +1,5 @@ """Tests for YouTube.""" + import http import time from unittest.mock import patch diff --git a/tests/components/zha/common.py b/tests/components/zha/common.py index d679ac5cb03..63d3e9cf747 100644 --- a/tests/components/zha/common.py +++ b/tests/components/zha/common.py @@ -1,4 +1,5 @@ """Common test objects.""" + import asyncio from datetime import timedelta import math diff --git a/tests/components/zha/test_config_flow.py b/tests/components/zha/test_config_flow.py index 3cd20771e6e..57833f0e67e 100644 --- a/tests/components/zha/test_config_flow.py +++ b/tests/components/zha/test_config_flow.py @@ -1,4 +1,5 @@ """Tests for ZHA config flow.""" + import copy from datetime import timedelta from ipaddress import ip_address diff --git a/tests/components/zha/test_cover.py b/tests/components/zha/test_cover.py index 964868118c4..a1b320097e8 100644 --- a/tests/components/zha/test_cover.py +++ b/tests/components/zha/test_cover.py @@ -1,4 +1,5 @@ """Test ZHA cover.""" + import asyncio from unittest.mock import patch diff --git a/tests/components/zha/test_gateway.py b/tests/components/zha/test_gateway.py index e4d8d2a5d65..5ae1cc0e7e5 100644 --- a/tests/components/zha/test_gateway.py +++ b/tests/components/zha/test_gateway.py @@ -1,4 +1,5 @@ """Test ZHA Gateway.""" + import asyncio from unittest.mock import MagicMock, PropertyMock, patch diff --git a/tests/components/zha/test_helpers.py b/tests/components/zha/test_helpers.py index 7e3c4a40872..b97a2d0fa5d 100644 --- a/tests/components/zha/test_helpers.py +++ b/tests/components/zha/test_helpers.py @@ -1,4 +1,5 @@ """Tests for ZHA helpers.""" + import logging from unittest.mock import patch diff --git a/tests/components/zha/test_init.py b/tests/components/zha/test_init.py index 5887fa2d8bc..f516dca7094 100644 --- a/tests/components/zha/test_init.py +++ b/tests/components/zha/test_init.py @@ -1,4 +1,5 @@ """Tests for ZHA integration init.""" + import asyncio import typing from unittest.mock import AsyncMock, Mock, patch diff --git a/tests/components/zone/test_trigger.py b/tests/components/zone/test_trigger.py index 7f44cecefe1..8987481f460 100644 --- a/tests/components/zone/test_trigger.py +++ b/tests/components/zone/test_trigger.py @@ -1,4 +1,5 @@ """The tests for the location automation.""" + import pytest from homeassistant.components import automation, zone diff --git a/tests/components/zwave_js/conftest.py b/tests/components/zwave_js/conftest.py index f2c3abd362a..98453071bc1 100644 --- a/tests/components/zwave_js/conftest.py +++ b/tests/components/zwave_js/conftest.py @@ -1,4 +1,5 @@ """Provide common Z-Wave JS fixtures.""" + import asyncio import copy import io diff --git a/tests/components/zwave_js/scripts/test_convert_device_diagnostics_to_fixture.py b/tests/components/zwave_js/scripts/test_convert_device_diagnostics_to_fixture.py index ee03d57f4c7..545c56d6f9d 100644 --- a/tests/components/zwave_js/scripts/test_convert_device_diagnostics_to_fixture.py +++ b/tests/components/zwave_js/scripts/test_convert_device_diagnostics_to_fixture.py @@ -1,4 +1,5 @@ """Test convert_device_diagnostics_to_fixture script.""" + import copy import json from pathlib import Path diff --git a/tests/components/zwave_js/test_button.py b/tests/components/zwave_js/test_button.py index 68a8e07ffe4..e1a1c6d665a 100644 --- a/tests/components/zwave_js/test_button.py +++ b/tests/components/zwave_js/test_button.py @@ -1,4 +1,5 @@ """Test the Z-Wave JS button entities.""" + import pytest from homeassistant.components.button import DOMAIN as BUTTON_DOMAIN, SERVICE_PRESS diff --git a/tests/components/zwave_js/test_climate.py b/tests/components/zwave_js/test_climate.py index c96f1c48797..9a4559de1a5 100644 --- a/tests/components/zwave_js/test_climate.py +++ b/tests/components/zwave_js/test_climate.py @@ -1,4 +1,5 @@ """Test the Z-Wave JS climate platform.""" + import copy import pytest diff --git a/tests/components/zwave_js/test_config_flow.py b/tests/components/zwave_js/test_config_flow.py index e8d6b0fd44c..ad066dec992 100644 --- a/tests/components/zwave_js/test_config_flow.py +++ b/tests/components/zwave_js/test_config_flow.py @@ -1,4 +1,5 @@ """Test the Z-Wave JS config flow.""" + import asyncio from collections.abc import Generator from copy import copy diff --git a/tests/components/zwave_js/test_config_validation.py b/tests/components/zwave_js/test_config_validation.py index b811ab7c10b..8428972bde1 100644 --- a/tests/components/zwave_js/test_config_validation.py +++ b/tests/components/zwave_js/test_config_validation.py @@ -1,4 +1,5 @@ """Test the Z-Wave JS config validation helpers.""" + import pytest import voluptuous as vol diff --git a/tests/components/zwave_js/test_cover.py b/tests/components/zwave_js/test_cover.py index 54be2b43765..4ecd697f4d1 100644 --- a/tests/components/zwave_js/test_cover.py +++ b/tests/components/zwave_js/test_cover.py @@ -1,4 +1,5 @@ """Test the Z-Wave JS cover platform.""" + import logging from zwave_js_server.const import ( diff --git a/tests/components/zwave_js/test_diagnostics.py b/tests/components/zwave_js/test_diagnostics.py index 2510143695c..054906cd0f6 100644 --- a/tests/components/zwave_js/test_diagnostics.py +++ b/tests/components/zwave_js/test_diagnostics.py @@ -1,4 +1,5 @@ """Test the Z-Wave JS diagnostics.""" + import copy from unittest.mock import patch diff --git a/tests/components/zwave_js/test_discovery.py b/tests/components/zwave_js/test_discovery.py index 67f4a8d962f..2b597339e8f 100644 --- a/tests/components/zwave_js/test_discovery.py +++ b/tests/components/zwave_js/test_discovery.py @@ -1,4 +1,5 @@ """Test entity discovery for device-specific schemas for the Z-Wave JS integration.""" + import pytest from homeassistant.components.binary_sensor import DOMAIN as BINARY_SENSOR_DOMAIN diff --git a/tests/components/zwave_js/test_fan.py b/tests/components/zwave_js/test_fan.py index c26a5366d37..03cd6bfb704 100644 --- a/tests/components/zwave_js/test_fan.py +++ b/tests/components/zwave_js/test_fan.py @@ -1,4 +1,5 @@ """Test the Z-Wave JS fan platform.""" + import copy import pytest diff --git a/tests/components/zwave_js/test_helpers.py b/tests/components/zwave_js/test_helpers.py index b40c09b249d..38e15df52cc 100644 --- a/tests/components/zwave_js/test_helpers.py +++ b/tests/components/zwave_js/test_helpers.py @@ -1,4 +1,5 @@ """Test the Z-Wave JS helpers module.""" + import voluptuous as vol from homeassistant.components.zwave_js.helpers import ( diff --git a/tests/components/zwave_js/test_init.py b/tests/components/zwave_js/test_init.py index 4555ee59e1e..ee0e9d61707 100644 --- a/tests/components/zwave_js/test_init.py +++ b/tests/components/zwave_js/test_init.py @@ -1,4 +1,5 @@ """Test the Z-Wave JS init module.""" + import asyncio from copy import deepcopy import logging diff --git a/tests/components/zwave_js/test_lock.py b/tests/components/zwave_js/test_lock.py index 2213e9cf069..e8a8a2035d8 100644 --- a/tests/components/zwave_js/test_lock.py +++ b/tests/components/zwave_js/test_lock.py @@ -1,4 +1,5 @@ """Test the Z-Wave JS lock platform.""" + import pytest from zwave_js_server.const import CommandClass from zwave_js_server.const.command_class.lock import ( diff --git a/tests/components/zwave_js/test_migrate.py b/tests/components/zwave_js/test_migrate.py index 1f5a96eb5f3..b5e88a745ef 100644 --- a/tests/components/zwave_js/test_migrate.py +++ b/tests/components/zwave_js/test_migrate.py @@ -1,4 +1,5 @@ """Test the Z-Wave JS migration module.""" + import copy import pytest diff --git a/tests/components/zwave_js/test_sensor.py b/tests/components/zwave_js/test_sensor.py index a3d36b84382..2ae4dc7686a 100644 --- a/tests/components/zwave_js/test_sensor.py +++ b/tests/components/zwave_js/test_sensor.py @@ -1,4 +1,5 @@ """Test the Z-Wave JS sensor platform.""" + import copy import pytest diff --git a/tests/components/zwave_js/test_switch.py b/tests/components/zwave_js/test_switch.py index fd5c626bdd2..e9ffdef55cb 100644 --- a/tests/components/zwave_js/test_switch.py +++ b/tests/components/zwave_js/test_switch.py @@ -1,4 +1,5 @@ """Test the Z-Wave JS switch platform.""" + import pytest from zwave_js_server.const import CURRENT_VALUE_PROPERTY, CommandClass from zwave_js_server.event import Event diff --git a/tests/components/zwave_js/test_update.py b/tests/components/zwave_js/test_update.py index 1774254a3c5..64c72ddc1fa 100644 --- a/tests/components/zwave_js/test_update.py +++ b/tests/components/zwave_js/test_update.py @@ -1,4 +1,5 @@ """Test the Z-Wave JS update entities.""" + import asyncio from datetime import timedelta