Test: Add SDK API tests for chat assistant management and improve con… (#8131)

### What problem does this PR solve?

- Implement new SDK API test cases for chat assistant CRUD operations
- Enhance HTTP API concurrent tests to use as_completed for better
reliability

### Type of change

- [x] Add test cases
- [x] Refactoring
This commit is contained in:
Liu An
2025-06-09 13:30:12 +08:00
committed by GitHub
parent 968ffc7ef3
commit 4649accd54
9 changed files with 854 additions and 10 deletions

View File

@ -40,3 +40,8 @@ def bulk_upload_documents(dataset: DataSet, num: int, tmp_path: Path) -> list[Do
# CHUNK MANAGEMENT WITHIN DATASET
def batch_add_chunks(document: Document, num: int):
return [document.add_chunk(content=f"chunk test {i}") for i in range(num)]
# CHAT ASSISTANT MANAGEMENT
def batch_create_chat_assistants(client: RAGFlow, num: int):
return [client.create_chat(name=f"test_chat_assistant_{i}") for i in range(num)]