diff --git a/CHANGELOG.md b/CHANGELOG.md index caa9d87f..ce35f59e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,4 +1,4 @@ -## 0.3.12-dev3 +## 0.3.12-dev4 ### Enhancements diff --git a/test/integration/connectors/test_qdrant.py b/test/integration/connectors/test_qdrant.py index d3ab1f56..5f7f55f7 100644 --- a/test/integration/connectors/test_qdrant.py +++ b/test/integration/connectors/test_qdrant.py @@ -109,6 +109,14 @@ async def test_qdrant_destination_local(upload_file: Path, tmp_path: Path): async with qdrant_client(connection_kwargs) as client: await validate_upload(client=client, upload_file=upload_file) + # Repeat upload to test the upsert functionality + if uploader.is_async(): + await uploader.run_async(path=staged_upload_file, file_data=file_data) + else: + uploader.run(path=upload_file, file_data=file_data) + async with qdrant_client(connection_kwargs) as client: + await validate_upload(client=client, upload_file=upload_file) + @pytest.fixture def docker_context(): @@ -144,10 +152,12 @@ async def test_qdrant_destination_server(upload_file: Path, tmp_path: Path, dock output_filename=upload_file.name, ) uploader.precheck() - if uploader.is_async(): - await uploader.run_async(path=staged_upload_file, file_data=file_data) - else: - uploader.run(path=upload_file, file_data=file_data) + await uploader.run_async(path=staged_upload_file, file_data=file_data) + async with qdrant_client(connection_kwargs) as client: + await validate_upload(client=client, upload_file=upload_file) + + # NOTE: Upload the second time to validate upsert behavior + await uploader.run_async(path=staged_upload_file, file_data=file_data) async with qdrant_client(connection_kwargs) as client: await validate_upload(client=client, upload_file=upload_file) @@ -189,10 +199,13 @@ async def test_qdrant_destination_cloud(upload_file: Path, tmp_path: Path): output_filename=upload_file.name, ) uploader.precheck() - if uploader.is_async(): - await uploader.run_async(path=staged_upload_file, file_data=file_data) - else: - uploader.run(path=staged_upload_file, file_data=file_data) + + await uploader.run_async(path=staged_upload_file, file_data=file_data) + async with qdrant_client(connection_kwargs) as client: + await validate_upload(client=client, upload_file=upload_file) + + # NOTE: Upload the second time to validate upsert behavior + await uploader.run_async(path=staged_upload_file, file_data=file_data) async with qdrant_client(connection_kwargs) as client: await validate_upload(client=client, upload_file=upload_file) diff --git a/unstructured_ingest/__version__.py b/unstructured_ingest/__version__.py index 3ad6f8bf..5d08f71b 100644 --- a/unstructured_ingest/__version__.py +++ b/unstructured_ingest/__version__.py @@ -1 +1 @@ -__version__ = "0.3.12-dev3" # pragma: no cover +__version__ = "0.3.12-dev4" # pragma: no cover