Test threaded parsing with a single thread (sequential baseline).
()
| 288 | |
| 289 | |
| 290 | def test_threaded_single_thread(): |
| 291 | """Test threaded parsing with a single thread (sequential baseline).""" |
| 292 | filename = SAMPLE_PDF |
| 293 | |
| 294 | parser = DoclingThreadedPdfParser( |
| 295 | parser_config=ThreadedPdfParserConfig( |
| 296 | loglevel="fatal", |
| 297 | threads=1, |
| 298 | max_concurrent_results=32, |
| 299 | boundary_type=PdfPageBoundaryType.CROP_BOX, |
| 300 | ), |
| 301 | decode_config=_make_decode_config(), |
| 302 | ) |
| 303 | |
| 304 | key = parser.load(filename) |
| 305 | count = sum(1 for result in parser.iterate_results() if result.success) |
| 306 | assert count == parser.page_count(key) |
| 307 | |
| 308 | |
| 309 | def test_threaded_selected_pages_schedule_subset(): |
nothing calls this directly
no test coverage detected