| 20 | @pytest.mark.asyncio |
| 21 | async def test_generate_database_sample_questions_rejects_empty_files(monkeypatch): |
| 22 | class FakeKnowledgeBase: |
| 23 | async def get_database_info(self, kb_id: str) -> dict: |
| 24 | return {"name": "空知识库", "kb_type": "milvus", "files": {}} |
| 25 | |
| 26 | monkeypatch.setattr(sq, "knowledge_base", FakeKnowledgeBase()) |
| 27 | monkeypatch.setattr( |
no outgoing calls