From 316eedb08893c8e1d19fd4f1aa1503df7d68deb3 Mon Sep 17 00:00:00 2001 From: Robert Sachunsky Date: Fri, 30 Aug 2024 01:59:31 +0200 Subject: [PATCH] =?UTF-8?q?tests:=20base=E2=86=92conftest?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- tests/{base.py => conftest.py} | 3 ++- tests/test_binarize.py | 2 +- tests/test_recognize.py | 5 ----- tests/test_segment.py | 2 -- 4 files changed, 3 insertions(+), 9 deletions(-) rename tests/{base.py => conftest.py} (97%) diff --git a/tests/base.py b/tests/conftest.py similarity index 97% rename from tests/base.py rename to tests/conftest.py index 9e6cebc..3b8cd32 100644 --- a/tests/base.py +++ b/tests/conftest.py @@ -7,7 +7,7 @@ from ocrd import Resolver, Workspace, OcrdMetsServer from ocrd_utils import pushd_popd, disableLogging, initLogging, setOverrideLogLevel, config -from tests.assets import assets +from .assets import assets @pytest.fixture def workspace(tmpdir, pytestconfig): @@ -34,3 +34,4 @@ def workspace_aufklaerung_region(workspace): @pytest.fixture def workspace_sbb(workspace): yield from workspace(assets.url_of('SBB0000F29300010000/data/mets_one_file.xml')) + diff --git a/tests/test_binarize.py b/tests/test_binarize.py index 3d5816c..4396aec 100644 --- a/tests/test_binarize.py +++ b/tests/test_binarize.py @@ -2,7 +2,7 @@ import json -from tests.base import * +from .assets import assets from ocrd import run_processor from ocrd_kraken.binarize import KrakenBinarize diff --git a/tests/test_recognize.py b/tests/test_recognize.py index 1b31cbd..290d7d0 100644 --- a/tests/test_recognize.py +++ b/tests/test_recognize.py @@ -1,15 +1,10 @@ # pylint: disable=import-error -from tests.base import * - from ocrd import run_processor from ocrd_kraken.recognize import KrakenRecognize def test_recognize(workspace_manifesto): ws = workspace_manifesto - print(ws) - print(type(ws)) - print(ws.directory) run_processor(KrakenRecognize, workspace=ws, input_file_grp="OCR-D-SEG-KRAKEN", diff --git a/tests/test_segment.py b/tests/test_segment.py index 7dc78ba..27dc2d7 100644 --- a/tests/test_segment.py +++ b/tests/test_segment.py @@ -1,7 +1,5 @@ # pylint: disable=import-error -from tests.base import * - from ocrd import run_processor from ocrd_kraken.segment import KrakenSegment