File tree Expand file tree Collapse file tree 2 files changed +7
-2
lines changed
Expand file tree Collapse file tree 2 files changed +7
-2
lines changed Original file line number Diff line number Diff line change 4646 from redis .commands .search .aggregation import AggregateResult
4747 from redis .commands .search .document import Document
4848 from redis .commands .search .result import Result
49-
5049 from redisvl .query .query import BaseQuery
5150
5251from redis import __version__ as redis_version
Original file line number Diff line number Diff line change @@ -130,6 +130,8 @@ def test_hybrid_query_with_all_parameters():
130130 10 ,
131131 "EF_RUNTIME" ,
132132 100 ,
133+ "FILTER" ,
134+ "@genre:{comedy}" ,
133135 "YIELD_SCORE_AS" ,
134136 "vsim_score" ,
135137 "COMBINE" ,
@@ -369,6 +371,8 @@ def test_hybrid_query_with_string_filter():
369371 "VSIM" ,
370372 "@embedding" ,
371373 bytes_vector ,
374+ "FILTER" ,
375+ "@category:{tech|science|engineering}" ,
372376 ]
373377
374378
@@ -393,6 +397,8 @@ def test_hybrid_query_with_tag_filter():
393397 "VSIM" ,
394398 "@embedding" ,
395399 bytes_vector ,
400+ "FILTER" ,
401+ "@genre:{comedy}" ,
396402 ]
397403
398404
@@ -412,7 +418,7 @@ def test_hybrid_query_with_numeric_filter():
412418 # Verify filter is included in serialized query
413419 args = get_query_pieces (hybrid_query )
414420 expected = "@age:[(30 +inf]"
415- assert args [1 ].endswith ("AND " + expected ) # Check text filter
421+ assert args [1 ].endswith (f "AND { expected } )" ) # Check text filter
416422 assert args [8 ] == expected # Check vector filter
417423
418424
You can’t perform that action at this time.
0 commit comments