mirror of
https://github.com/home-assistant/core.git
synced 2025-07-16 09:47:13 +00:00
Fix pylint warnings in xiaomi tests (#119373)
This commit is contained in:
parent
f9cf7598da
commit
43db0e457c
@ -28,7 +28,7 @@ def mocked_requests(*args, **kwargs):
|
||||
class MockResponse:
|
||||
"""Class to represent a mocked response."""
|
||||
|
||||
def __init__(self, json_data, status_code):
|
||||
def __init__(self, json_data, status_code) -> None:
|
||||
"""Initialize the mock response class."""
|
||||
self.json_data = json_data
|
||||
self.status_code = status_code
|
||||
@ -48,6 +48,7 @@ def mocked_requests(*args, **kwargs):
|
||||
raise requests.HTTPError(self.status_code)
|
||||
|
||||
data = kwargs.get("data")
|
||||
# pylint: disable-next=global-statement
|
||||
global FIRST_CALL # noqa: PLW0603
|
||||
|
||||
if data and data.get("username", None) == INVALID_USERNAME:
|
||||
|
Loading…
x
Reference in New Issue
Block a user