Skip to content

Commit f63cb4e

Browse files
tests/: test_4180(): update to match latest mupdf.
1 parent 9cf9f14 commit f63cb4e

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed
-3 Bytes
Loading

tests/test_textextract.py

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -498,8 +498,15 @@ def test_4180():
498498

499499
path_expected = os.path.normpath(f'{__file__}/../../tests/resources/test_4180_expected.png')
500500
rms = gentle_compare.pixmaps_rms(path_expected, pixmap)
501+
pixmap_diff = gentle_compare.pixmaps_diff(path_expected, pixmap)
502+
path_diff = os.path.normpath(f'{__file__}/../../tests/resources/test_4180_diff.png')
503+
pixmap_diff.save(path_diff)
501504
print(f'{rms=}')
502-
assert rms < 0.01
505+
if pymupdf.mupdf_version_tuple < (1, 26):
506+
# Prior to fix for mupdf bug 708274.
507+
assert rms < 0.3
508+
else:
509+
assert rms < 0.01
503510

504511

505512
def test_4182():

0 commit comments

Comments
 (0)