Merge pull request #340 from christianlouis/copilot/fix-json-decode-error

fix(test): fix test_get_lgpl_license_not_found JSONDecodeError
This commit is contained in:
Christian Krakau-Louis
2026-02-17 13:02:56 +01:00
committed by GitHub
+2 -2
View File
@@ -27,10 +27,10 @@ class TestLicenseViews:
def test_get_lgpl_license_not_found(self, client):
"""Test LGPL license file not found."""
with patch("pathlib.Path.exists", return_value=False):
with patch("app.views.license_routes.Path") as MockPath:
MockPath.return_value.exists.return_value = False
response = client.get("/licenses/lgpl.txt")
assert response.status_code == 404
assert "not found" in response.json()["detail"].lower()
def test_serve_attribution_page(self, client):
"""Test attribution page is served."""