Skip to content
Snippets Groups Projects

Add a link to our terms of use in API response headers

1 unresolved thread
2 files
+ 12
0
Compare changes
  • Side-by-side
  • Inline
Files
2
@@ -152,6 +152,15 @@ def test_error_response_handler(mocker, api_client):
assert "Traceback" in resp.data["traceback"]
def test_tos_in_api_response_headers(api_client):
url = reverse("api-1-stat-counters")
response = api_client.get(url)
assert (
response.get("X-Terms-of-Use")
== "https://www.softwareheritage.org/legal/api-terms-of-use/"
)
def test_api_endpoints_have_cors_headers(client, content, directory, revision):
url = reverse("api-1-stat-counters")
Loading