From 5220005a24afbc9004bcfc30f09483bdb5ae90c7 Mon Sep 17 00:00:00 2001 From: elstic Date: Wed, 13 Mar 2024 16:53:04 +0800 Subject: [PATCH] test: update the dim of the largest or smallest vector in case (#31223) issue: https://github.com/milvus-io/milvus/issues/31160 Signed-off-by: elstic --- tests/python_client/testcases/test_collection.py | 2 +- tests/python_client/testcases/test_index.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/python_client/testcases/test_collection.py b/tests/python_client/testcases/test_collection.py index dc0ca32379..bdf2ebe70f 100644 --- a/tests/python_client/testcases/test_collection.py +++ b/tests/python_client/testcases/test_collection.py @@ -841,7 +841,7 @@ class TestCollectionParams(TestcaseBase): c_name = cf.gen_unique_str(prefix) float_vec_field = cf.gen_float_vec_field(dim=dim) schema = cf.gen_collection_schema(fields=[cf.gen_int64_field(is_primary=True), float_vec_field]) - error = {ct.err_code: 1, ct.err_msg: "invalid dimension: {}. should be in range 1 ~ 32768".format(dim)} + error = {ct.err_code: 65535, ct.err_msg: "invalid dimension: {}.".format(dim)} self.collection_wrap.init_collection(c_name, schema=schema, check_task=CheckTasks.err_res, check_items=error) @pytest.mark.tags(CaseLabel.L1) diff --git a/tests/python_client/testcases/test_index.py b/tests/python_client/testcases/test_index.py index 1279fda7e2..8c0e0541e1 100644 --- a/tests/python_client/testcases/test_index.py +++ b/tests/python_client/testcases/test_index.py @@ -1907,7 +1907,7 @@ class TestIndexDiskann(TestcaseBase): "limit": default_limit}) @pytest.mark.tags(CaseLabel.L2) - @pytest.mark.parametrize("dim", [1, 32768]) + @pytest.mark.parametrize("dim", [ct.min_dim, ct.max_dim]) def test_create_index_diskann_with_max_min_dim(self, dim): """ target: test create index with diskann @@ -2258,7 +2258,7 @@ class TestScaNNIndex(TestcaseBase): check_task=CheckTasks.err_res, check_items=error) @pytest.mark.tags(CaseLabel.L2) - @pytest.mark.parametrize("dim", [1, 127]) + @pytest.mark.parametrize("dim", [3, 127]) def test_create_scann_index_dim_invalid(self, dim): """ target: test create scann index invalid