Fix the error of the search case reporting unmatched limit (#18980)

Signed-off-by: “nico” <cheng.yuan@zilliz.com>

Signed-off-by: “nico” <cheng.yuan@zilliz.com>
This commit is contained in:
NicoYuan1986 2022-09-02 18:41:03 +08:00 committed by GitHub
parent 2fa174ef30
commit 3920f6426a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1778,16 +1778,12 @@ class TestCollectionSearch(TestcaseBase):
res = collection_w.search(binary_vectors[:nq], "binary_vector",
search_params, default_limit, "int64 >= 0",
_async=_async,
travel_timestamp=time_stamp,
check_task=CheckTasks.check_search_results,
check_items={"nq": nq,
"ids": insert_ids,
"limit": default_limit,
"_async": _async})[0]
travel_timestamp=time_stamp)[0]
if _async:
res.done()
res = res.result()
assert res[0].distances[0] == 0.0
assert len(res) <= default_limit
@pytest.mark.tags(CaseLabel.L2)
@pytest.mark.parametrize("index", ["BIN_FLAT"])