remove is cloud mode from regression test
This commit is contained in:
@ -21,18 +21,6 @@ suite("test_nereids_row_policy") {
|
||||
def user='row_policy_user'
|
||||
def tokens = context.config.jdbcUrl.split('/')
|
||||
def url=tokens[0] + "//" + tokens[2] + "/" + dbName + "?"
|
||||
def isCloudMode = {
|
||||
def ret = sql_return_maparray """show backends"""
|
||||
ret.Tag[0].contains("cloud_cluster_name")
|
||||
}
|
||||
def cloudMode = isCloudMode.call()
|
||||
//cloud-mode
|
||||
if (cloudMode) {
|
||||
def clusters = sql " SHOW CLUSTERS; "
|
||||
assertTrue(!clusters.isEmpty())
|
||||
def validCluster = clusters[0][0]
|
||||
sql """GRANT USAGE_PRIV ON CLUSTER ${validCluster} TO ${user}""";
|
||||
}
|
||||
|
||||
def assertQueryResult = { size ->
|
||||
def result1 = connect(user=user, password='123abc!@#', url=url) {
|
||||
|
||||
@ -38,14 +38,6 @@ suite("column_authorization") {
|
||||
sql "create user ${user1}"
|
||||
sql "grant SELECT_PRIV(id) on ${db}.${baseTable} to '${user1}'@'%';"
|
||||
|
||||
//cloud-mode
|
||||
if (isCloudMode()) {
|
||||
def clusters = sql " SHOW CLUSTERS; "
|
||||
assertTrue(!clusters.isEmpty())
|
||||
def validCluster = clusters[0][0]
|
||||
sql """GRANT USAGE_PRIV ON CLUSTER ${validCluster} TO ${user1}""";
|
||||
}
|
||||
|
||||
sql 'sync'
|
||||
|
||||
def defaultDbUrl = context.config.jdbcUrl.substring(0, context.config.jdbcUrl.lastIndexOf("/"))
|
||||
|
||||
@ -88,13 +88,9 @@ suite("test_dynamic_partition") {
|
||||
assertEquals(Integer.valueOf(result.get(0).get(8)), 3)
|
||||
sql "drop table dy_par_bucket_set_by_distribution"
|
||||
sql "drop table if exists dy_par_bad"
|
||||
def isCloudMode = {
|
||||
def ret = sql_return_maparray """show backends"""
|
||||
ret.Tag[0].contains("cloud_cluster_name")
|
||||
}
|
||||
|
||||
// not support tag in cloud mode
|
||||
if (!isCloudMode) {
|
||||
|
||||
test {
|
||||
sql """
|
||||
CREATE TABLE IF NOT EXISTS dy_par_bad ( k1 date NOT NULL, k2 varchar(20) NOT NULL, k3 int sum NOT NULL )
|
||||
@ -114,7 +110,7 @@ suite("test_dynamic_partition") {
|
||||
// check exception message contains
|
||||
exception "errCode = 2,"
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
sql "drop table if exists dy_par_bad"
|
||||
sql """
|
||||
@ -139,7 +135,7 @@ suite("test_dynamic_partition") {
|
||||
//
|
||||
sql "drop table if exists dy_par_bad"
|
||||
// not support tag in cloud mode
|
||||
if (!isCloudMode) {
|
||||
|
||||
test {
|
||||
sql """
|
||||
CREATE TABLE IF NOT EXISTS dy_par_bad ( k1 datev2 NOT NULL, k2 varchar(20) NOT NULL, k3 int sum NOT NULL )
|
||||
@ -159,6 +155,5 @@ suite("test_dynamic_partition") {
|
||||
// check exception message contains
|
||||
exception "errCode = 2,"
|
||||
}
|
||||
}
|
||||
sql "drop table if exists dy_par_bad"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user