MCPcopy Create free account
hub / github.com/alibaba/zvec / test_properties

Method test_properties

python/tests/test_query_executor.py:174–193  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

172 assert ctx.include_vector is False
173
174 def test_properties(self):
175 queries = [Query(field_name="test")]
176 reranker = RrfReRanker()
177 output_fields = ["field1", "field2"]
178
179 ctx = QueryContext(
180 topk=5,
181 filter="test_filter",
182 include_vector=True,
183 queries=queries,
184 output_fields=output_fields,
185 reranker=reranker,
186 )
187
188 assert ctx.topk == 5
189 assert ctx.queries == queries
190 assert ctx.filter == "test_filter"
191 assert ctx.reranker == reranker
192 assert ctx.output_fields == output_fields
193 assert ctx.include_vector is True
194
195 def test_properties_with_weighted_reranker(self):
196 queries = [Query(field_name="test")]

Callers

nothing calls this directly

Calls 3

QueryClass · 0.90
RrfReRankerClass · 0.90
QueryContextClass · 0.90

Tested by

no test coverage detected