mirror of
https://github.com/tiennm99/DocsGPT.git
synced 2026-10-13 02:14:23 +00:00
standalone OCR
This commit is contained in:
1 parent
d4e92be0ab
commit
96b878217d
27 files changed
+1995
-152
No files matched your search
@@ -471,11 +471,11 @@ def test_temp_file_cleaned_up_on_parser_error(monkeypatch):
|
||||
# ---------------------------------------------------------------------------
|
||||
@pytest.mark.unit
|
||||
def test_ocr_resolution(monkeypatch):
|
||||
monkeypatch.setattr(dr.settings, "DOCLING_OCR_ENABLED", True, raising=False)
|
||||
monkeypatch.setattr(dr.settings, "OCR_ENABLED", True, raising=False)
|
||||
assert dr._resolve_ocr_enabled("off") is False
|
||||
assert dr._resolve_ocr_enabled("on") is True
|
||||
assert dr._resolve_ocr_enabled("auto") is True
|
||||
monkeypatch.setattr(dr.settings, "DOCLING_OCR_ENABLED", False, raising=False)
|
||||
monkeypatch.setattr(dr.settings, "OCR_ENABLED", False, raising=False)
|
||||
assert dr._resolve_ocr_enabled("auto") is False
|
||||
|
||||
|
||||
|
||||
Reference in new issue
Block a user