Spaces:
Sleeping
Sleeping
Download tests/test_chunking.py from thabsheeeeeer/DocBrain-API: direct link, hf CLI and curl.
- Browser
- Download file 257 Bytes
-
https://huggingface.co/spaces/thabsheeeeeer/DocBrain-API/resolve/main/tests/test_chunking.py
- Command line
-
hf download hf://spaces/thabsheeeeeer/DocBrain-API/tests/test_chunking.py
-
curl -L -o test_chunking.py https://huggingface.co/spaces/thabsheeeeeer/DocBrain-API/resolve/main/tests/test_chunking.py
257 Bytes
| from app.utils.chunking import chunk_text | |
| def test_chunk_text_returns_chunks(): | |
| text = "This is a sample text. " * 100 | |
| chunks = chunk_text(text) | |
| assert isinstance(chunks, list) | |
| assert len(chunks) > 0 | |
| assert isinstance(chunks[0], str) |