test(student):lab4 attachments negative cases
- 11 MiB body -> 413 payload_too_large - truncated PNG -> 415 unsupported_media_type - MIME mismatch (PNG bytes as image/jpeg) -> 201, content_type image/png - outsider access to metadata and bytes -> 404 - foreign-chat attachment_id in message -> 404 - 11 attachment_ids -> 400 invalid_request - duplicate attachment_ids -> 400 invalid_request - empty filename -> 400 - path-traversal / backslash / NUL in filename -> 400 All rejections are 4xx; no 500 on user error.
This commit is contained in:
@@ -5,8 +5,7 @@ from pathlib import Path
|
||||
|
||||
ROOT = Path(__file__).resolve().parent
|
||||
|
||||
QUICK = ('test_cases.py', 'test_concurrency.py', 'test_auth.py')
|
||||
|
||||
QUICK = ('test_cases.py', 'test_concurrency.py', 'test_auth.py', 'test_attachments.py')
|
||||
|
||||
def main():
|
||||
args = sys.argv[1:]
|
||||
|
||||
Reference in New Issue
Block a user