haystack/test/test_docx_conversion.py

10 lines
288 B
Python
Raw Normal View History

from pathlib import Path
from haystack.file_converter.docx import DocxToTextConverter
def test_convert():
converter = DocxToTextConverter()
document = converter.convert(file_path=Path("samples/docx/sample_docx.docx"))
assert document["text"].startswith("Sample Docx File")