From defc7684418c00e38ff9d15f1ed79a43a0f6f2ff Mon Sep 17 00:00:00 2001 From: binbin <83755740+binbinlv@users.noreply.github.com> Date: Mon, 4 Jul 2022 19:58:23 +0800 Subject: [PATCH] Update test cases for code fix (#18037) Signed-off-by: Binbin Lv --- tests/python_client/testcases/test_collection.py | 2 +- tests/python_client/testcases/test_compaction.py | 4 ++-- tests/python_client/testcases/test_partition.py | 2 +- tests/python_client/testcases/test_search.py | 1 - 4 files changed, 4 insertions(+), 5 deletions(-) diff --git a/tests/python_client/testcases/test_collection.py b/tests/python_client/testcases/test_collection.py index 0590fa94b..ee82415d9 100644 --- a/tests/python_client/testcases/test_collection.py +++ b/tests/python_client/testcases/test_collection.py @@ -1084,7 +1084,7 @@ class TestCollectionOperation(TestcaseBase): partition_w1 = self.init_partition_wrap(collection_w) partition_w1.insert(cf.gen_default_list_data()) collection_w.load() - error = {ct.err_code: 1, ct.err_msg: f'load the partition after load collection is not supported'} + error = {ct.err_code: 5, ct.err_msg: f'load the partition after load collection is not supported'} partition_w1.load(check_task=CheckTasks.err_res, check_items=error) diff --git a/tests/python_client/testcases/test_compaction.py b/tests/python_client/testcases/test_compaction.py index f963f7a79..ed69d0472 100644 --- a/tests/python_client/testcases/test_compaction.py +++ b/tests/python_client/testcases/test_compaction.py @@ -931,7 +931,7 @@ class TestCompactionOperation(TestcaseBase): collection_w = self.collection_insert_multi_segments_one_shard(prefix, num_of_segment=threshold) # Estimated auto-merging takes 30s - cost = 60 + cost = 120 collection_w.load() replicas = collection_w.get_replicas()[0] replica_num = len(replicas.groups) @@ -1158,7 +1158,7 @@ class TestCompactionOperation(TestcaseBase): t = threading.Thread(target=do_index, args=()) t.start() collection_w.compact() - collection_w.wait_for_compaction_completed(timeout=90) + collection_w.wait_for_compaction_completed(timeout=180) collection_w.get_compaction_plans() t.join() diff --git a/tests/python_client/testcases/test_partition.py b/tests/python_client/testcases/test_partition.py index db527451d..1c3f2a18d 100644 --- a/tests/python_client/testcases/test_partition.py +++ b/tests/python_client/testcases/test_partition.py @@ -249,7 +249,7 @@ class TestPartitionParams(TestcaseBase): partition_w1.insert(cf.gen_default_list_data()) partition_w2.insert(cf.gen_default_list_data()) partition_w1.load() - error = {ct.err_code: 1, ct.err_msg: f'load the partition after load collection is not supported'} + error = {ct.err_code: 5, ct.err_msg: f'load the partition after load collection is not supported'} partition_w2.load(check_task=CheckTasks.err_res, check_items=error) diff --git a/tests/python_client/testcases/test_search.py b/tests/python_client/testcases/test_search.py index 6b1debac6..1ec585354 100644 --- a/tests/python_client/testcases/test_search.py +++ b/tests/python_client/testcases/test_search.py @@ -275,7 +275,6 @@ class TestCollectionSearchInvalid(TestcaseBase): % invalid_search_field}) @pytest.mark.tags(CaseLabel.L1) - @pytest.mark.xfail(reason="issue 17935") def test_search_param_invalid_metric_type(self, get_invalid_metric_type): """ target: test search with invalid parameter values -- GitLab