Skip to content

Commit

Permalink
test: add different nq for restful v2 test (#33469)
Browse files Browse the repository at this point in the history
pr: #33456

Signed-off-by: zhuwenxing <[email protected]>
  • Loading branch information
zhuwenxing authored May 31, 2024
1 parent 38e5e33 commit 6de80a0
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions tests/restful_client_v2/testcases/test_vector_operations.py
Original file line number Diff line number Diff line change
Expand Up @@ -750,8 +750,9 @@ def test_search_vector_with_all_vector_datatype(self, nb, dim, insert_round, aut
@pytest.mark.parametrize("enable_dynamic_schema", [True])
@pytest.mark.parametrize("nb", [3000])
@pytest.mark.parametrize("dim", [128])
@pytest.mark.parametrize("nq", [1, 2])
def test_search_vector_with_float_vector_datatype(self, nb, dim, insert_round, auto_id,
is_partition_key, enable_dynamic_schema):
is_partition_key, enable_dynamic_schema, nq):
"""
Insert a vector with a simple payload
"""
Expand Down Expand Up @@ -812,7 +813,7 @@ def test_search_vector_with_float_vector_datatype(self, nb, dim, insert_round, a
# search data
payload = {
"collectionName": name,
"data": [gen_vector(datatype="FloatVector", dim=dim)],
"data": [gen_vector(datatype="FloatVector", dim=dim) for _ in range(nq)],
"filter": "word_count > 100",
"groupingField": "user_id",
"outputFields": ["*"],
Expand All @@ -827,7 +828,7 @@ def test_search_vector_with_float_vector_datatype(self, nb, dim, insert_round, a
}
rsp = self.vector_client.vector_search(payload)
assert rsp['code'] == 0
assert len(rsp['data']) == 100
assert len(rsp['data']) == 100 * nq


@pytest.mark.parametrize("insert_round", [1])
Expand Down

0 comments on commit 6de80a0

Please sign in to comment.