Skip to content

Commit

Permalink
add order when listing records in test (#5813)
Browse files Browse the repository at this point in the history
# Description
<!-- Please include a summary of the changes and the related issue.
Please also include relevant motivation and context. List any
dependencies that are required for this change. -->


**Type of change**
<!-- Please delete options that are not relevant. Remember to title the
PR according to the type of change -->

- Bug fix (non-breaking change which fixes an issue)

**How Has This Been Tested**
<!-- Please add some reference about how your feature has been tested.
-->

**Checklist**
<!-- Please go over the list and make sure you've taken everything into
account -->

- I added relevant documentation
- I followed the style guidelines of this project
- I did a self-review of my code
- I made corresponding changes to the documentation
- I confirm My changes generate no new warnings
- I have added tests that prove my fix is effective or that my feature
works
- I have added relevant notes to the CHANGELOG.md file (See
https://keepachangelog.com/)
  • Loading branch information
frascuchon authored Feb 17, 2025
1 parent 534821b commit 1bc9407
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion argilla-server/tests/unit/contexts/hub/test_hub_dataset.py
Original file line number Diff line number Diff line change
Expand Up @@ -471,7 +471,7 @@ async def test_hub_dataset_import_to_idempotency_without_external_id(
await hub_dataset.import_to(db, mock_search_engine, dataset)
assert (await db.execute(select(func.count(Record.id)))).scalar_one() == 5

records = (await db.execute(select(Record))).scalars().all()
records = (await db.execute(select(Record).order_by(Record.inserted_at.asc()))).scalars().all()
assert [record.external_id for record in records] == ["train_0", "train_1", "train_2", "train_3", "train_4"]

async def test_hub_dataset_import_to_idempotency_without_external_id_and_multiple_splits(
Expand Down

0 comments on commit 1bc9407

Please sign in to comment.