2026-11-20T04:53:36+03:00
make test-contract

BASE_URL="http://localhost:8080" python3 scripts/contract-audit.py
ok:   explicit attachment_ids=null is 400
ok:   empty variant is 400
ok:   whitespace-only filename is 400
ok:   Content-Type parameters are accepted
ok:   41,000,000 pixels is 413
ok:   text length bounds
ok:   attachment count bounds
ok:   duplicate attachment_ids is 400
ok:   idempotent replay with the same set
ok:   absent and empty attachment_ids agree
ok:   attachment from another chat is 404
ok:   unknown attachment id is 404
ok:   outsider access is 404
ok:   upload to unknown chat is 404
ok:   media errors are 415
ok:   oversize is 413
ok:   filename errors are 400
ok:   chat validation errors are 400
ok:   pagination errors are 400
ok:   idempotency errors
ok:   null request fields are 400
ok:   more than 100 members is 400
ok:   user field validation
ok:   missing Content-Type is 415
ok:   variant is case sensitive
ok:   filename control characters are 400
ok:   chat title bounds
ok:   cursor is bound to the endpoint
ok:   204 responses carry headers and no body
ok:   download Content-Length matches the bytes
PASS: 30 checks
