fix: reject idempotency key payload conflicts
This commit is contained in:
@@ -441,3 +441,6 @@ def test_catch_report_idempotency_key_prevents_duplicates(monkeypatch) -> None:
|
||||
assert second.json()["idempotent"] is True
|
||||
assert second.json()["id"] == report_id
|
||||
assert second.json()["screenshot_upload_token"] == first.json()["screenshot_upload_token"]
|
||||
changed = dict(payload, weight_g=7800)
|
||||
conflict = client.post("/api/v1/catch-reports", json=changed, headers=headers)
|
||||
assert conflict.status_code == 409
|
||||
|
||||
Reference in New Issue
Block a user