提交 c5708907 编写于 作者: G Ganlin Zhao

fix test cases

上级 2f4c73d8
......@@ -271,6 +271,10 @@ SMonHttpStatus *monGetHttpStatusHashTableEntry(int32_t code) {
}
static void *monAuditFunc(void *param) {
if (!tsEnableAudit) {
return NULL;
}
monDebug("starting to initialize audit database...");
setThreadName("audit");
taosMsleep(1000);
......
......@@ -28,8 +28,8 @@ class TDTestCase:
tdSql.prepare()
ret = tdSql.query('select database()')
tdSql.checkData(0, 0, "db")
tdSql.checkData(0, 0, "db")
ret = tdSql.query('select server_status()')
tdSql.checkData(0, 0, 1)
......@@ -59,10 +59,10 @@ class TDTestCase:
if create_time-time_delta < role_time < create_time+time_delta:
tdLog.info("role_time {} and create_time {} expected within range".format(role_time, create_time))
else:
tdLog.exit("role_time {} and create_time {} not expected within range".format(role_time, create_time))
tdLog.exit("role_time {} and create_time {} not expected within range".format(role_time, create_time))
ret = tdSql.query('show vgroups')
tdSql.checkRows(0)
tdSql.checkRows(0)
tdSql.execute('create stable st (ts timestamp, f int) tags(t int)')
tdSql.execute('create table ct1 using st tags(1)');
......@@ -71,11 +71,11 @@ class TDTestCase:
time.sleep(3)
ret = tdSql.query('show vnodes "{}"'.format(dnodeEndpoint))
tdSql.checkRows(1)
tdSql.checkRows(2)
tdSql.checkData(0, 0, 2)
tdSql.checkData(0, 1, "leader")
cmd = "taos -h 127.0.0.1 -s 'show databases'"
cmd = "taos -h 127.0.0.1 -s 'show databases'"
r = os.popen(cmd)
text = r.read()
r.close
......
......@@ -101,8 +101,9 @@ class TDTestCase:
tdSql.execute("drop database db")
tdSql.execute("drop database db1")
time.sleep(1)
tdSql.query("show databases")
tdSql.checkRows(0)
tdSql.checkRows(1)
os.system("%s -i ./taosdumptest/tmp1" % binPath)
os.system("%s -i ./taosdumptest/tmp2" % binPath)
......
......@@ -94,8 +94,9 @@ class TDTestCase:
binPath)
tdSql.execute("drop database db")
time.sleep(1)
tdSql.query("show databases")
tdSql.checkRows(0)
tdSql.checkRows(1)
os.system("%s -i ./taosdumptest/tmp -y" % binPath)
......
......@@ -85,6 +85,7 @@ echo wdebugFlag 135 >> %TAOS_CFG%
echo cqdebugFlag 135 >> %TAOS_CFG%
echo monitor 0 >> %TAOS_CFG%
echo monitorInterval 1 >> %TAOS_CFG%
echo audit 0 >> %TAOS_CFG%
echo http 0 >> %TAOS_CFG%
echo slaveQuery 0 >> %TAOS_CFG%
echo numOfThreadsPerCore 2.0 >> %TAOS_CFG%
......
......@@ -139,6 +139,7 @@ echo "wdebugFlag 143" >> $TAOS_CFG
echo "cqdebugFlag 143" >> $TAOS_CFG
echo "monitor 0" >> $TAOS_CFG
echo "monitorInterval 1" >> $TAOS_CFG
echo "audit 0" >> $TAOS_CFG
echo "http 0" >> $TAOS_CFG
echo "slaveQuery 0" >> $TAOS_CFG
echo "numOfThreadsPerCore 2.0" >> $TAOS_CFG
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册