diff --git a/tests/pytest/client/client.py b/tests/pytest/client/client.py index 36c06ac09daf26ef0e23130a01111919501c6f46..6fd2a2b6bdd9a83c4f54b90cc37d16f05209b069 100644 --- a/tests/pytest/client/client.py +++ b/tests/pytest/client/client.py @@ -26,7 +26,7 @@ class TDTestCase: tdSql.prepare() ret = tdSql.query('select database()') - tdSql.checkData(0, 0, "db") + tdSql.checkData(0, 0, "db") ret = tdSql.query('select server_version()') tdSql.checkData(0, 0, "2.0.0.0") @@ -45,6 +45,13 @@ class TDTestCase: ret = tdSql.execute('alter dnode "%s" debugFlag 135' % tdSql.getData(0,0)) tdLog.info('alter dnode "%s" debugFlag 135 -> ret: %d' % (tdSql.getData(0, 0), ret)) + ret = tdSql.query('show mnodes') + tdSql.checkRows(1) + + ret = tdSql.query('show vgroups') + tdSql.checkRows(0) + + def stop(self): tdSql.close() tdLog.success("%s successfully executed" % __file__) diff --git a/tests/pytest/insert/multi.py b/tests/pytest/insert/multi.py index 5f81f12fdbf471e4680d48c743d64878777788cd..42d699ea713006886ba14e1ceda15756d5715e51 100644 --- a/tests/pytest/insert/multi.py +++ b/tests/pytest/insert/multi.py @@ -48,6 +48,18 @@ class TDTestCase: "import INTO dev_001 VALUES ('2020-05-13 10:00:00.000', 1),('2020-05-13 10:00:00.001', 1)") tdSql.checkAffectedRows(2) + + tdSql.execute( + "CREATE TABLE if not exists dev_002 using st tags('dev_01')") + tdSql.execute( + "CREATE TABLE if not exists dev_003 using st tags('dev_01')") + print("==============step4") + tdLog.info("multiple tables inserts by insert") + tdSql.execute( + '''insert INTO dev_002 VALUES ('2020-05-13 10:00:00.000', 1),('2020-05-13 10:00:00.001', 1) + dev_003 VALUES ('2020-05-13 10:00:00.000', 2),('2020-05-13 10:00:00.001', 3)''') + tdSql.checkAffectedRows(4) + def stop(self): tdSql.close() tdLog.success("%s successfully executed" % __file__)