Skip to content

Commit 19b82af

Browse files
Apply suggested fix to tests/test_api.py from Copilot Autofix
Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>
1 parent 970d822 commit 19b82af

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

tests/test_api.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,14 @@
1515
def mocked_requests_get(*args, **kwargs):
1616
class MockResponse:
1717
def __init__(
18-
self, json_data: dict | None, status_code: int, headers: dict = {}
18+
self,
19+
json_data: dict | None,
20+
status_code: int,
21+
headers: dict | None = None,
1922
):
2023
self.json_data = json_data
2124
self.status_code = status_code
22-
self.headers = headers
25+
self.headers = headers if headers is not None else {}
2326

2427
def json(self):
2528
return self.json_data

0 commit comments

Comments
 (0)