Skip to content

Commit

Permalink
Fix broken test_rotate_page_level
Browse files Browse the repository at this point in the history
Before 42ff7fc84289a885c86d4629ebcf8dd9a65cef2d0, `make_rotate_test`
always used `resources / 'typewriter.png'`, but after the change the
second call accidentally used just `resources`, which is a directory,
and fails to open.
  • Loading branch information
QuLogic committed Aug 21, 2024
1 parent 5e1e249 commit 20b516f
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tests/test_rotation.py
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,9 @@ def make_rotate_test(imagefile, outdir, prefix, image_angle, page_angle):
@pytest.mark.parametrize('image_angle', (0, 90, 180, 270))
def test_rotate_page_level(image_angle, page_angle, resources, outdir, caplog):
reference = make_rotate_test(resources / 'typewriter.png', outdir, 'ref', 0, 0)
test = make_rotate_test(resources, outdir, 'test', image_angle, page_angle)
test = make_rotate_test(

Check warning on line 242 in tests/test_rotation.py

View check run for this annotation

Codecov / codecov/patch

tests/test_rotation.py#L242

Added line #L242 was not covered by tests
resources / 'typewriter.png', outdir, 'test', image_angle, page_angle
)
out = test.with_suffix('.out.pdf')

exitcode = run_ocrmypdf_api(
Expand Down

0 comments on commit 20b516f

Please sign in to comment.