Address code review feedback: improve test parameter handling

Co-authored-by: kuhyx <147418882+kuhyx@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot] 2026-01-14 16:40:58 +00:00
parent a65d933eec
commit e934e50461

View File

@ -208,7 +208,8 @@ class TestGenerateAnkiPackage:
"""Test that download errors are handled gracefully."""
test_codes = {200: "OK", 404: "Not Found"}
def mock_download(code: int, *, use_cache: bool) -> bytes: # noqa: ARG001
def mock_download(code: int, *, use_cache: bool) -> bytes:
del use_cache # Intentionally unused in test mock
error_msg = "Failed"
if code == 404:
raise requests.exceptions.RequestException(error_msg)