From 036bcc63ec585dbdf8f7fae4414817b3acd4ec26 Mon Sep 17 00:00:00 2001 From: Shuduo Sang Date: Sat, 9 Apr 2022 09:57:10 +0800 Subject: [PATCH] [tools]: taosdump dump result (#11329) * [TD-14593]: taosdump dump-result update taos-tools * add debug in tools/taosdumpTest2.py --- tests/pytest/tools/taosdumpTest2.py | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/tests/pytest/tools/taosdumpTest2.py b/tests/pytest/tools/taosdumpTest2.py index 0b53cbdfea..673abee700 100644 --- a/tests/pytest/tools/taosdumpTest2.py +++ b/tests/pytest/tools/taosdumpTest2.py @@ -66,6 +66,7 @@ class TDTestCase: tdSql.prepare() + print("DEBUG LN69: %s" % tdSql.getResult("show databases")) tdSql.execute("create table st(ts timestamp, c1 timestamp, c2 int, c3 bigint, c4 float, c5 double, c6 binary(8), c7 smallint, c8 tinyint, c9 bool, c10 nchar(8)) tags(t1 int)") tdSql.execute("create table t1 using st tags(0)") currts = self.ts @@ -79,6 +80,7 @@ class TDTestCase: break tdSql.execute(sql) + print("DEBUG LN83: %s" % tdSql.getResult("show databases")) binPath = self.getPath() if (binPath == ""): tdLog.exit("taosdump not found!") @@ -91,12 +93,15 @@ class TDTestCase: "%s --databases db -o ./taosdumptest/tmp " % binPath) + print("DEBUG LN96: %s" % tdSql.getResult("show databases")) tdSql.execute("drop database db") -# tdSql.query("show databases") -# tdSql.checkRows(0) + print("DEBUG LN98: %s" % tdSql.getResult("show databases")) + tdSql.query("show databases") + tdSql.checkRows(0) os.system("%s -i ./taosdumptest/tmp -y" % binPath) + print("DEBUG LN104: %s" % tdSql.getResult("show databases")) tdSql.query("show databases") tdSql.checkRows(1) tdSql.checkData(0, 0, 'db') @@ -111,6 +116,7 @@ class TDTestCase: # test case for TS-1225 tdSql.execute("create database test") + print("DEBUG LN119: %s" % tdSql.getResult("show databases")) tdSql.execute("use test") tdSql.execute( "create table stb(ts timestamp, c1 binary(16374), c2 binary(16374), c3 binary(16374)) tags(t1 nchar(256))") @@ -125,11 +131,13 @@ class TDTestCase: os.system("%s -D test -o ./taosdumptest/tmp -y" % binPath) tdSql.execute("drop database test") + print("DEBUG LN134: %s" % tdSql.getResult("show databases")) tdSql.query("show databases") tdSql.checkRows(1) os.system("%s -i ./taosdumptest/tmp -y" % binPath) + print("DEBUG LN140: %s" % tdSql.getResult("show databases")) tdSql.execute("use test") tdSql.error("show vnodes '' ") tdSql.query("show stables") -- GitLab