fischer-agentkit/tests/unit/server
chiguyong 3f9588e673 feat(rag_platform): U3+U7 — rewrite upload endpoint with sanitization + pipeline
Rewrite upload_document() to use rag_platform sanitize + DocumentProcessor:
- File type whitelist validation (8 allowed types, reject .exe/.sh)
- File size limit (50MB) + zip bomb detection for ZIP-based formats
- DocumentProcessor.parse() (with content sanitization) + segment()
- Return chunks preview, status="segmenting" (pending vectorization)

Add POST /kb-management/documents/preview endpoint:
- Pre-upload preview with adjustable chunk_size/chunk_overlap
- Same security validation as upload, no document record created

Add POST /kb-management/documents/{id}/vectorize placeholder:
- Returns 503 — full async vectorization deferred to U8 (TaskIQ)

Test: update test_upload_document assertion (status "indexed" → "segmenting")
2026-06-25 12:06:16 +08:00
..
__init__.py fix: resolve code review issues from deferred improvements 2026-06-11 13:49:02 +08:00
test_atomic_write.py fix(review): U3 atomic file writes for YAML + .env + skill config 2026-06-22 17:03:27 +08:00
test_chat_team.py feat: 企业级客户端-服务端架构 + 代码审查修复 2026-06-20 06:48:18 +08:00
test_event_queue_integration.py feat: integrate SQ/EQ into portal WebSocket and CLI (Phase 4) 2026-06-17 11:05:04 +08:00
test_evolution_dashboard.py feat: frontend productization with code review fixes 2026-06-13 01:29:58 +08:00
test_kb_management.py feat(rag_platform): U3+U7 — rewrite upload endpoint with sanitization + pipeline 2026-06-25 12:06:16 +08:00
test_portal_routes.py feat: SQLite persistence, verification loop, spec-driven execution 2026-06-17 10:45:20 +08:00
test_portal_ws_background.py fix: WebSocket task persistence three-layer defense with security hardening 2026-06-17 22:11:51 +08:00
test_settings_routes.py feat: 企业级客户端-服务端架构 + 代码审查修复 2026-06-20 06:48:18 +08:00
test_skill_management.py feat(skills): distinguish agent templates from business skills in UI 2026-06-23 15:55:59 +08:00
test_terminal_routes.py feat: 企业级客户端-服务端架构 + 代码审查修复 2026-06-20 06:48:18 +08:00
test_workflow_routes.py feat: frontend productization with code review fixes 2026-06-13 01:29:58 +08:00