Skip to content

Commit

Permalink
tests/: added placeholder test for #3725 PyMuPDF inserting newline ch…
Browse files Browse the repository at this point in the history
…aracters mid-word
  • Loading branch information
julian-smith-artifex-com committed Dec 2, 2024
1 parent 3e5c369 commit 95ffdeb
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
Binary file added tests/resources/test_3725.pdf
Binary file not shown.
9 changes: 9 additions & 0 deletions tests/test_textextract.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
"""
import os
import sys
import textwrap

import pymupdf

Expand Down Expand Up @@ -400,3 +401,11 @@ def test_4026():
else:
assert len(blocks) == 5

def test_3725():
# This currently just shows the extracted text. We don't check it is as expected.
path = os.path.normpath(f'{__file__}/../../tests/resources/test_3725.pdf')
with pymupdf.open(path) as document:
page = document[0]
text = page.get_text()
if 0:
print(textwrap.indent(text, ' '))

0 comments on commit 95ffdeb

Please sign in to comment.