def test_metadata_filters(metadata_filters: MetadataFilters) -> None:
    """Test conversion of MetadataFilters to MQL."""
    mql_filters = pipelines.filters_to_mql(metadata_filters)
    assert mql_filters == {
        "$and": [{"metadata.year": {"$lte": 2024}}, {"metadata.year": {"$gt": 2022}}]
    }
Test conversion of MetadataFilters to MQL.
llama-index-integrations/vector_stores/llama-index-vector-stores-mongodb/tests/test_filters.py