From fac48fa73fb6bc7325d1809f7e18bbff8189b3f0 Mon Sep 17 00:00:00 2001 From: Martin Thoma Date: Mon, 4 Jul 2022 22:39:16 +0200 Subject: [PATCH] TST: Scale page --- tests/test_workflows.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tests/test_workflows.py b/tests/test_workflows.py index 6340fc0e0f..372505c773 100644 --- a/tests/test_workflows.py +++ b/tests/test_workflows.py @@ -325,3 +325,13 @@ def test_get_fields(): # Cleanup os.remove("tmp.txt") + + +def test_scale(): + url = "https://corpora.tika.apache.org/base/docs/govdocs1/999/999944.pdf" + name = "tika-999944.pdf" + data = BytesIO(get_pdf_from_url(url, name=name)) + reader = PdfReader(data) + + for page in reader.pages: + page.scale(sx=2, sy=3)