Skip to content

Commit

Permalink
TST: Add MCVE of issue #416 (#980)
Browse files Browse the repository at this point in the history
  • Loading branch information
MartinThoma authored Jun 12, 2022
1 parent 8149026 commit 41eff2a
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
10 changes: 10 additions & 0 deletions tests/test_reader.py
Original file line number Diff line number Diff line change
Expand Up @@ -702,3 +702,13 @@ def test_read_path():
path = Path(os.path.join(RESOURCE_ROOT, "crazyones.pdf"))
reader = PdfReader(path)
assert len(reader.pages) == 1


@pytest.mark.xfail(reason="#416")
def test_read_form_416():
url = (
"https://www.fda.gov/downloads/AboutFDA/ReportsManualsForms/Forms/UCM074728.pdf"
)
reader = PdfReader(BytesIO(get_pdf_from_url(url, name="issue_416.pdf")))
fields = reader.get_form_text_fields()
assert len(fields) > 0
1 change: 1 addition & 0 deletions tests/test_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -201,6 +201,7 @@ def test_read_block_backwards_at_start():
6,
),
],
ids=list(range(11)),
)
def test_read_previous_line(dat, pos, expected, expected_pos):
s = io.BytesIO(dat)
Expand Down

0 comments on commit 41eff2a

Please sign in to comment.