tests: workaround for Ghostscript 9.52 txtwrite problem

This commit is contained in:
James R. Barlow
2020-03-29 22:45:16 -07:00
parent 8307832ce9
commit 23bc3d3a29
2 changed files with 31 additions and 22 deletions
+4
View File
@@ -26,6 +26,7 @@ from PIL import Image
from reportlab.pdfgen.canvas import Canvas
from ocrmypdf import pdfinfo
from ocrmypdf.exec import ghostscript
from ocrmypdf.pdfinfo import Colorspace, Encoding
# pylint: disable=protected-access
@@ -183,6 +184,9 @@ def test_ocr_detection(resources):
@pytest.mark.parametrize(
'testfile', ('truetype_font_nomapping.pdf', 'type3_font_nomapping.pdf')
)
@pytest.mark.xfail(
ghostscript.version() in ('9.52',), reason="gs 9.52 txtwrite doesn't work"
)
def test_corrupt_font_detection(resources, testfile):
filename = resources / testfile
with pytest.raises(NotImplementedError):