fixed the RAg in test pipeline issue

This commit is contained in:
belviskhoremk
2026-04-26 18:51:48 +00:00
parent 205d9d7901
commit 97a501097d
14 changed files with 249 additions and 57 deletions

View File

@@ -216,8 +216,10 @@ class TestDocumentDelete:
"file_url": None,
}
with patch("app.routers.documents.get_supabase") as mock_sb, \
patch("app.routers.documents.vector_store") as mock_vs:
patch("app.routers.documents.vector_store") as mock_vs, \
patch("app.routers.documents.response_cache") as mock_cache:
mock_vs.delete_by_document_id = MagicMock()
mock_cache.invalidate = MagicMock()
mock_sb.return_value = _make_doc_sb(doc=doc)
resp = client.delete("/api/v1/chatbots/cb-1/documents/doc-1", headers=AUTH)
assert resp.status_code == 200