You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by da...@apache.org on 2024/07/10 14:08:40 UTC

(doris) branch master updated: [fix](regression) Fix `test_alter_table_property` run in config force… (#37581)

This is an automated email from the ASF dual-hosted git repository.

dataroaring pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/doris.git


The following commit(s) were added to refs/heads/master by this push:
     new 6758e93ed2e [fix](regression) Fix `test_alter_table_property` run in config force… (#37581)
6758e93ed2e is described below

commit 6758e93ed2e028083ee9229f43822e133866cf87
Author: deardeng <56...@qq.com>
AuthorDate: Wed Jul 10 22:08:33 2024 +0800

    [fix](regression) Fix `test_alter_table_property` run in config force… (#37581)
    
    …_olap_table_replication_num
    
    ## Proposed changes
    
    Issue Number: close #xxx
    
    <!--Describe your changes.-->
---
 .../suites/alter_p2/test_alter_table_property.groovy          | 11 ++++++++---
 1 file changed, 8 insertions(+), 3 deletions(-)

diff --git a/regression-test/suites/alter_p2/test_alter_table_property.groovy b/regression-test/suites/alter_p2/test_alter_table_property.groovy
index 0803e781dc4..bdc2a8ac01c 100644
--- a/regression-test/suites/alter_p2/test_alter_table_property.groovy
+++ b/regression-test/suites/alter_p2/test_alter_table_property.groovy
@@ -46,11 +46,16 @@ suite ("test_alter_table_property") {
         }
         sum
     }
+    def replication_num = 1
+    def forceReplicaNum = getFeConfig('force_olap_table_replication_num').toInteger()
+    if (forceReplicaNum > 0) {
+        replication_num = forceReplicaNum
+    }
 
-    assertEquals(1, queryReplicaCount("p1"))
+    assertEquals(replication_num, queryReplicaCount("p1"))
 
     sql """ ALTER TABLE ${tableName} ADD PARTITION p2 VALUES LESS THAN ("200") """
-    assertEquals(1, queryReplicaCount("p2"))
+    assertEquals(replication_num, queryReplicaCount("p2"))
 
     if (!isCloudMode()) {
         sql """ ALTER TABLE ${tableName} SET ( "default.replication_allocation" = "tag.location.default: 2" ) """
@@ -67,7 +72,7 @@ suite ("test_alter_table_property") {
         }
         assertEquals(2, queryReplicaCount("p1"))
     }
-    assertEquals(1, queryReplicaCount("p2"))
+    assertEquals(replication_num, queryReplicaCount("p2"))
 
     sql "DROP TABLE ${tableName}"
 }


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org