Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ suite("test_ds_view_basic") {
}
def checkTableOrViewExists = { res, name -> Boolean
for (List<Object> row : res) {
if ((row[0] as String).equals(name)) {
if ("${row[0]}".equals(name)) {
return true
}
}
Expand Down Expand Up @@ -99,8 +99,11 @@ suite("test_ds_view_basic") {
select user_id, name from ${tableDuplicate0};
"""

def checkViewExistFunc = { res -> Boolean
return checkTableOrViewExists(res, "view_test_${suffix}")
}
assertTrue(helper.checkShowTimesOf("SHOW VIEWS",
checkTableOrViewExists("view_test_${suffix}"), 30, func = "target_sql"))
checkViewExistFunc, 30, func = "target_sql"))

explain {
sql("select user_id, name from ${tableDuplicate0}")
Expand All @@ -113,7 +116,7 @@ suite("test_ds_view_basic") {
def checkViewNotExistFunc = { res -> Boolean
return !checkTableOrViewExists(res, "view_test_${suffix}")
}
assertTrue(helper.checkShowTimesOf("SHOW VIEWS", checkViewNotExistFunc, 5, func = "target_sql"))
assertTrue(helper.checkShowTimesOf("SHOW VIEWS", checkViewNotExistFunc, 30, func = "target_sql"))

logger.info("=== Test 2: delete job ===")
test_num = 5
Expand Down
Loading