Fixup other docker test suite errors
Outstanding failures: test_pageinfo::test_jpeg tests involving unpaper due to version <6.1 failures
This commit is contained in:
@@ -50,6 +50,7 @@ WORKDIR /home/docker
|
||||
|
||||
ENV DEFAULT_RUFFUS_HISTORY_FILE=/tmp/.{basename}.ruffus_history.sqlite
|
||||
ENV OCRMYPDF_TEST_OUTPUT=/tmp/test-output
|
||||
ENV OCRMYPDF_IN_DOCKER=1
|
||||
|
||||
# Must use array form of ENTRYPOINT
|
||||
# Non-array form does not append other arguments, because that is "intuitive"
|
||||
|
||||
@@ -7,7 +7,6 @@ from PIL import Image
|
||||
from tempfile import NamedTemporaryFile
|
||||
from contextlib import suppress
|
||||
import os
|
||||
import sys
|
||||
import shutil
|
||||
import pytest
|
||||
import img2pdf
|
||||
@@ -15,7 +14,9 @@ from pkg_resources import Requirement, resource_filename
|
||||
|
||||
req = Requirement.parse('ocrmypdf')
|
||||
|
||||
TEST_OUTPUT = os.path.join(os.path.dirname(__file__), 'output')
|
||||
TEST_OUTPUT = os.environ.get(
|
||||
'OCRMYPDF_TEST_OUTPUT',
|
||||
default=os.path.join(os.path.dirname(__file__), 'output'))
|
||||
|
||||
|
||||
def setup_module():
|
||||
|
||||
+3
-1
@@ -265,6 +265,8 @@ def break_ghostscript_pdfa():
|
||||
return override_binary('gs', 'replace_ghostscript_nopdfa.py')
|
||||
|
||||
|
||||
@pytest.mark.skipif(os.environ.get('OCRMYPDF_IN_DOCKER', False),
|
||||
reason="Requires writable filesystem")
|
||||
def test_ghostscript_pdfa_fails(break_ghostscript_pdfa):
|
||||
env = os.environ.copy()
|
||||
env['PATH'] = break_ghostscript_pdfa
|
||||
@@ -297,7 +299,7 @@ def test_blank_input_pdf():
|
||||
|
||||
def test_french():
|
||||
p, out, err = run_ocrmypdf_env(
|
||||
'français.pdf', 'français.pdf', '-l', 'fra')
|
||||
'francais.pdf', 'francais.pdf', '-l', 'fra')
|
||||
assert p.returncode == ExitCode.ok, \
|
||||
"This test may fail if Tesseract language packs are missing"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user