test : update case

This commit is contained in:
wenzhouwww@live.cn 2022-05-27 15:09:31 +08:00
parent 9bddc341bf
commit 6dde3edc8d
3 changed files with 6 additions and 5 deletions

View File

@ -153,7 +153,7 @@ class TDTestCase:
case6 = {"col": "c9"} case6 = {"col": "c9"}
self.checkcsum(**case6) self.checkcsum(**case6)
# # case7~8: nested query # case7~8: nested query
# case7 = {"table_expr": "(select c1 from stb1)"} # case7 = {"table_expr": "(select c1 from stb1)"}
# self.checkcsum(**case7) # self.checkcsum(**case7)
# case8 = {"table_expr": "(select csum(c1) c1 from stb1 group by tbname)"} # case8 = {"table_expr": "(select csum(c1) c1 from stb1 group by tbname)"}
@ -188,7 +188,7 @@ class TDTestCase:
"condition": "where t1.ts=t2.ts" "condition": "where t1.ts=t2.ts"
} }
self.checkcsum(**case17) self.checkcsum(**case17)
# # case18~19: with group by # case18~19: with group by
# case18 = { # case18 = {
# "table_expr": "t1", # "table_expr": "t1",
# "condition": "group by c6" # "condition": "group by c6"

View File

@ -1560,13 +1560,13 @@ class TDTestCase:
if pres == "ms": if pres == "ms":
if unit in ["10u","10b"]: if unit in ["10u","10b"]:
# tdSql.error("select elapsed(ts,%s) from db_%s.st group by tbname "%(unit,pres)) tdSql.error("select elapsed(ts,%s) from db_%s.st group by tbname "%(unit,pres))
pass pass
else: else:
tdSql.query("select elapsed(ts,%s) from db_%s.st group by tbname "%(unit,pres)) tdSql.query("select elapsed(ts,%s) from db_%s.st group by tbname "%(unit,pres))
elif pres == "us" and unit in ["10b"]: elif pres == "us" and unit in ["10b"]:
if unit in ["10b"]: if unit in ["10b"]:
# tdSql.error("select elapsed(ts,%s) from db_%s.st group by tbname "%(unit,pres)) tdSql.error("select elapsed(ts,%s) from db_%s.st group by tbname "%(unit,pres))
pass pass
else: else:
tdSql.query("select elapsed(ts,%s) from db_%s.st group by tbname "%(unit,pres)) tdSql.query("select elapsed(ts,%s) from db_%s.st group by tbname "%(unit,pres))
@ -1575,7 +1575,7 @@ class TDTestCase:
tdSql.query("select elapsed(ts,%s) from db_%s.st group by tbname "%(unit,pres)) tdSql.query("select elapsed(ts,%s) from db_%s.st group by tbname "%(unit,pres))
basic_result = 9 basic_result = 9
tdSql.checkData(0,0,basic_result*pow(1000,index)) tdSql.checkData(0,0,basic_result*pow(1000,index))
def run(self): def run(self):
tdSql.prepare() tdSql.prepare()
self.prepare_data() self.prepare_data()

View File

@ -65,6 +65,7 @@ python3 ./test.py -f 2-query/avg.py
python3 ./test.py -f 2-query/elapsed.py python3 ./test.py -f 2-query/elapsed.py
python3 ./test.py -f 2-query/csum.py python3 ./test.py -f 2-query/csum.py
python3 ./test.py -f 7-tmq/basic5.py python3 ./test.py -f 7-tmq/basic5.py
python3 ./test.py -f 7-tmq/subscribeDb.py python3 ./test.py -f 7-tmq/subscribeDb.py
python3 ./test.py -f 7-tmq/subscribeDb1.py python3 ./test.py -f 7-tmq/subscribeDb1.py