提交 fa902a35 编写于 作者: L liuyq-617

[TD-4059]update case version.py

上级 1466505e
...@@ -28,20 +28,22 @@ class TDTestCase: ...@@ -28,20 +28,22 @@ class TDTestCase:
sql = "select server_version()" sql = "select server_version()"
ret = tdSql.query(sql) ret = tdSql.query(sql)
version = tdSql.getData(0, 0)[0:3] version = tdSql.getData(0, 0)[0:3]
expectedVersion = "2.0" expectedVersion_dev = "2.0"
if(version == expectedVersion): expectedVersion_master = "2.1"
tdLog.info("sql:%s, row:%d col:%d data:%s == expect:%s" % (sql, 0, 0, version, expectedVersion)) if(version == expectedVersion_dev or version == expectedVersion_master):
tdLog.info("sql:%s, row:%d col:%d data:%s == expect" % (sql, 0, 0, version))
else: else:
tdLog.exit("sql:%s, row:%d col:%d data:%s != expect:%s" % (sql, 0, 0, version, expectedVersion)) tdLog.exit("sql:%s, row:%d col:%d data:%s != expect:%s or %s " % (sql, 0, 0, version, expectedVersion_dev, expectedVersion_master))
sql = "select client_version()" sql = "select client_version()"
ret = tdSql.query(sql) ret = tdSql.query(sql)
version = tdSql.getData(0, 0)[0:3] version = tdSql.getData(0, 0)[0:3]
expectedVersion = "2.0" expectedVersion_dev = "2.0"
if(version == expectedVersion): expectedVersion_master = "2.1"
tdLog.info("sql:%s, row:%d col:%d data:%s == expect:%s" % (sql, 0, 0, version, expectedVersion)) if(version == expectedVersion_dev or version == expectedVersion_master):
tdLog.info("sql:%s, row:%d col:%d data:%s == expect" % (sql, 0, 0, version))
else: else:
tdLog.exit("sql:%s, row:%d col:%d data:%s != expect:%s" % (sql, 0, 0, version, expectedVersion)) tdLog.exit("sql:%s, row:%d col:%d data:%s != expect:%s or %s " % (sql, 0, 0, version, expectedVersion_dev, expectedVersion_master))
def stop(self): def stop(self):
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册