mirror of
https://gitee.com/milvus-io/milvus.git
synced 2024-12-02 03:48:37 +08:00
test: update test cases (#36841)
Signed-off-by: nico <cheng.yuan@zilliz.com>
This commit is contained in:
parent
af2da8d8d6
commit
937ebec2ce
@ -1463,7 +1463,7 @@ class TestIndexInvalid(TestcaseBase):
|
||||
collection_w.insert(data=data)
|
||||
param = cf.get_index_params_params(index)
|
||||
params = {"index_type": index, "metric_type": metric_type, "params": param}
|
||||
error = {ct.err_code: 65535, ct.err_msg: "only IP is the supported metric type for sparse index"}
|
||||
error = {ct.err_code: 65535, ct.err_msg: "only IP&BM25 is the supported metric type for sparse index"}
|
||||
index, _ = self.index_wrap.init_index(collection_w.collection, ct.default_sparse_vec_field_name, params,
|
||||
check_task=CheckTasks.err_res,
|
||||
check_items=error)
|
||||
|
@ -339,7 +339,8 @@ class TestQueryParams(TestcaseBase):
|
||||
# not support filter bool field with expr 'bool in [0/ 1]'
|
||||
not_support_expr = f'{ct.default_bool_field_name} in [0]'
|
||||
error = {ct.err_code: 65535,
|
||||
ct.err_msg: "cannot parse expression: bool in [0], error: value '0' in list cannot be casted to Bool"}
|
||||
ct.err_msg: "cannot parse expression: bool in [0], error: "
|
||||
"value 'int64_val:0' in list cannot be casted to Bool"}
|
||||
self.collection_wrap.query(not_support_expr, output_fields=[ct.default_bool_field_name],
|
||||
check_task=CheckTasks.err_res, check_items=error)
|
||||
|
||||
@ -456,7 +457,7 @@ class TestQueryParams(TestcaseBase):
|
||||
|
||||
expr_3 = f'{ct.default_int64_field_name} in not [1, 2]'
|
||||
error_3 = {ct.err_code: 65535, ct.err_msg: "cannot parse expression: int64 in not [1, 2], "
|
||||
"error: line 1:9 no viable alternative at input 'innot'"}
|
||||
"error: value 'not[1,2]' in list cannot be a non-const expression"}
|
||||
collection_w.query(expr_3, check_task=CheckTasks.err_res, check_items=error_3)
|
||||
|
||||
@pytest.mark.tags(CaseLabel.L1)
|
||||
|
Loading…
Reference in New Issue
Block a user