-
Notifications
You must be signed in to change notification settings - Fork 2.7k
GetMetadataFieldsInfoAsyncTest, GetMetadataFieldMinMaxAsyncTest, GetMetadataFieldUniqueValuesAsyncTest #10921
Copy link
Copy link
Labels
P2Medium priority, add to the next sprint if no P1 availableMedium priority, add to the next sprint if no P1 available
Description
NOTES:
- Tests should be written into
haystack/testing/document_store_async.py - Use
async deffor all test methods - Decorate each test method with
@pytest.mark.asyncio - Rely on an
async-compatibledocument_storefixture (to be provided by the concrete test class in each integration) - Use
awaiton all*_async()calls - Use
write_documents_async/count_documents_asyncin setup steps (not the sync variants), so the full async path is exercised end-to-end - Open the PR to the async-mixin-tests feature branch
GetMetadataFieldsInfoAsyncTest
Mirrors: GetMetadataFieldsInfoTest
| Test | Description |
|---|---|
test_get_metadata_fields_info_async |
After writing docs, returned dict contains expected field names and each has a "type" key |
test_get_metadata_fields_info_empty_collection_async |
Empty store returns {} |
GetMetadataFieldMinMaxAsyncTest
Mirrors: GetMetadataFieldMinMaxTest
| Test | Description |
|---|---|
test_get_metadata_field_min_max_numeric_async |
Integer field, correct min/max |
test_get_metadata_field_min_max_float_async |
Float field, correct min/max (use pytest.approx) |
test_get_metadata_field_min_max_single_value_async |
Single doc: min == max |
test_get_metadata_field_min_max_empty_collection_async |
Empty store: {"min": None, "max": None} |
test_get_metadata_field_min_max_meta_prefix_async |
Field names with "meta." prefix are handled |
GetMetadataFieldUniqueValuesAsyncTest
Mirrors: GetMetadataFieldUniqueValuesTest
| Test | Description |
|---|---|
test_get_metadata_field_unique_values_basic_async |
Returns correct set of unique values; inspects signature for search_term, from_/offset, size/limit params |
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
P2Medium priority, add to the next sprint if no P1 availableMedium priority, add to the next sprint if no P1 available