Skip to content

Commit c65e1b1

Browse files
committed
test if splitting is the issue
1 parent 4c7e037 commit c65e1b1

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

_test_unstructured_client/integration/test_decorators.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -478,7 +478,7 @@ async def mock_send(_, request: httpx.Request, **kwargs):
478478
@pytest.mark.parametrize(
479479
("filename", "chunking_strategy", "expected_elements_num"),
480480
[
481-
## -- Paid strategy --
481+
# -- Paid strategy --
482482
("_sample_docs/layout-parser-paper.pdf", "by_page", 16), # 16 pages, 133 elements w/o chunking
483483
("_sample_docs/layout-parser-paper.pdf", shared.ChunkingStrategy.BY_PAGE, 16),
484484
# -- Open source strategy --
@@ -503,6 +503,7 @@ def test_chunking(
503503
parameters = shared.PartitionParameters(
504504
files=files,
505505
chunking_strategy=chunking_strategy, # type: ignore
506+
split_pdf_page=False, # -- Testing splitting as potential issue
506507
)
507508

508509
req = operations.PartitionRequest(
@@ -511,5 +512,5 @@ def test_chunking(
511512

512513
resp = client.general.partition(request=req)
513514
assert len(resp.elements) == expected_elements_num
514-
assert all(element.type == "CompositeElement" for element in resp.elements)
515+
assert all(element.get("type") == "CompositeElement" for element in resp.elements)
515516

0 commit comments

Comments
 (0)