diff --git a/tests/python_client/milvus_client/test_milvus_client_collection.py b/tests/python_client/milvus_client/test_milvus_client_collection.py index 8ef66153942b4..2a69350a28fb5 100644 --- a/tests/python_client/milvus_client/test_milvus_client_collection.py +++ b/tests/python_client/milvus_client/test_milvus_client_collection.py @@ -813,11 +813,11 @@ def test_milvus_client_load_collection_over_max_length(self): """ client = self._connect(enable_milvus_client_api=True) collection_name = "a".join("a" for i in range(256)) - error = {ct.err_code: 1100, ct.err_msg: f"invalid dimension: {collection_name}. " + error = {ct.err_code: 1100, ct.err_msg: f"Invalid collection name: {collection_name}. " f"the length of a collection name must be less than 255 characters: " f"invalid parameter"} client_w.load_collection(client, collection_name, - check_task=CheckTasks.err_res, check_items=error) + check_task=CheckTasks.err_res, check_items=error) @pytest.mark.tags(CaseLabel.L1) def test_milvus_client_load_collection_without_index(self): @@ -929,8 +929,7 @@ def test_milvus_client_describe_collection_not_existed(self): """ client = self._connect(enable_milvus_client_api=True) collection_name = "nonexisted" - error = {ct.err_code: 100, ct.err_msg: f"can't find collection collection not " - f"found[database=default][collection=nonexisted]"} + error = {ct.err_code: 100, ct.err_msg: "can't find collection[database=default][collection=nonexisted]"} client_w.describe_collection(client, collection_name, check_task=CheckTasks.err_res, check_items=error) @@ -946,8 +945,7 @@ def test_milvus_client_describe_collection_deleted_collection(self): # 1. create collection client_w.create_collection(client, collection_name, default_dim) client_w.drop_collection(client, collection_name) - error = {ct.err_code: 100, ct.err_msg: f"can't find collection collection not " - f"found[database=default]"} + error = {ct.err_code: 100, ct.err_msg: f"can't find collection[database=default][collection={collection_name}]"} client_w.describe_collection(client, collection_name, check_task=CheckTasks.err_res, check_items=error) @@ -1048,7 +1046,7 @@ def test_milvus_client_rename_collection_duplicated_collection(self): collection_name = cf.gen_unique_str(prefix) # 1. create collection client_w.create_collection(client, collection_name, default_dim) - error = {ct.err_code: 65535, ct.err_msg: f"duplicated new collection name default:{collection_name}" + error = {ct.err_code: 65535, ct.err_msg: f"duplicated new collection name default:{collection_name} " f"with other collection name or alias"} client_w.rename_collection(client, collection_name, collection_name, check_task=CheckTasks.err_res, check_items=error) @@ -1065,10 +1063,9 @@ def test_milvus_client_rename_deleted_collection(self): # 1. create collection client_w.create_collection(client, collection_name, default_dim) client_w.drop_collection(client, collection_name) - error = {ct.err_code: 100, ct.err_msg: f"can't find collection collection not " - f"found[database=default]"} + error = {ct.err_code: 100, ct.err_msg: f"{collection_name}: collection not found[collection=default]"} client_w.rename_collection(client, collection_name, "new_collection", - check_task=CheckTasks.err_res, check_items=error) + check_task=CheckTasks.err_res, check_items=error) class TestMilvusClientRenameCollectionValid(TestcaseBase): diff --git a/tests/python_client/milvus_client/test_milvus_client_search.py b/tests/python_client/milvus_client/test_milvus_client_search.py index b5523b18dc899..ea270de7cea76 100644 --- a/tests/python_client/milvus_client/test_milvus_client_search.py +++ b/tests/python_client/milvus_client/test_milvus_client_search.py @@ -126,7 +126,8 @@ def test_milvus_client_collection_invalid_metric_type(self): collection_name = cf.gen_unique_str(prefix) # 1. create collection error = {ct.err_code: 1100, - ct.err_msg: "metric type not found or not supported, supported: [L2 IP COSINE HAMMING JACCARD]"} + ct.err_msg: "float vector index does not support metric type: invalid: " + "invalid parameter[expected=valid index params][actual=invalid index params]"} client_w.create_collection(client, collection_name, default_dim, metric_type="invalid", check_task=CheckTasks.err_res, check_items=error) diff --git a/tests/python_client/requirements.txt b/tests/python_client/requirements.txt index 0b24f91996fbd..006358229a7d3 100644 --- a/tests/python_client/requirements.txt +++ b/tests/python_client/requirements.txt @@ -27,8 +27,8 @@ pytest-parallel pytest-random-order # pymilvus -pymilvus==2.5.0rc118 -pymilvus[bulk_writer]==2.5.0rc118 +pymilvus==2.5.0rc119 +pymilvus[bulk_writer]==2.5.0rc119 # for customize config test diff --git a/tests/python_client/testcases/test_partition.py b/tests/python_client/testcases/test_partition.py index 0af8ee21553bf..0606bc0c67e05 100644 --- a/tests/python_client/testcases/test_partition.py +++ b/tests/python_client/testcases/test_partition.py @@ -397,8 +397,8 @@ def test_load_replica_change(self): partition_w.load(replica_number=1) collection_w.query(expr=f"{ct.default_int64_field_name} in [0]", check_task=CheckTasks.check_query_results, check_items={'exp_res': [{'int64': 0}]}) - error = {ct.err_code: 1100, ct.err_msg: "call query coordinator LoadCollection: can't change the replica number" - " for loaded collection: invalid parameter[expected=1][actual=2]"} + error = {ct.err_code: 1100, ct.err_msg: "=can't change the replica number for loaded partitions: " + "invalid parameter[expected=1][actual=2]"} partition_w.load(replica_number=2, check_task=CheckTasks.err_res, check_items=error) partition_w.release()