tests: convert all uses of multipage.pdf to fixture
This commit is contained in:
+6
-1
@@ -44,7 +44,7 @@ TESTS_ROOT = Path(__file__).parent.resolve()
|
||||
PROJECT_ROOT = TESTS_ROOT
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
@pytest.fixture(scope="session")
|
||||
def resources() -> Path:
|
||||
return Path(TESTS_ROOT) / 'resources'
|
||||
|
||||
@@ -78,6 +78,11 @@ def no_outpdf(tmp_path) -> Path:
|
||||
return tmp_path / 'no_output.pdf'
|
||||
|
||||
|
||||
@pytest.fixture(scope="session")
|
||||
def multipage(resources):
|
||||
return resources / 'multipage.pdf'
|
||||
|
||||
|
||||
def check_ocrmypdf(input_file: Path, output_file: Path, *args) -> Path:
|
||||
"""Run ocrmypdf and confirm that a valid plausible PDF was created."""
|
||||
api_args = [str(input_file), str(output_file)] + [
|
||||
|
||||
Reference in New Issue
Block a user