mirror of
https://github.com/MODSetter/SurfSense.git
synced 2026-06-20 21:18:13 +02:00
fix: update upload conftest mock to span-aware chunker
This commit is contained in:
parent
cfc3be5b1f
commit
31a14190e3
1 changed files with 5 additions and 2 deletions
|
|
@ -286,9 +286,12 @@ def _mock_external_apis(monkeypatch):
|
|||
"app.indexing_pipeline.cache.cached_indexing.embed_texts",
|
||||
MagicMock(side_effect=lambda texts: [[0.1] * _EMBEDDING_DIM for _ in texts]),
|
||||
)
|
||||
from app.indexing_pipeline.document_chunker import ChunkSlice
|
||||
|
||||
chunk = "Test chunk content."
|
||||
monkeypatch.setattr(
|
||||
"app.indexing_pipeline.cache.cached_indexing.chunk_text",
|
||||
MagicMock(return_value=["Test chunk content."]),
|
||||
"app.indexing_pipeline.cache.cached_indexing.chunk_markdown_with_spans",
|
||||
MagicMock(return_value=[ChunkSlice(chunk, 0, len(chunk))]),
|
||||
)
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue