提交 5a15739c 编写于 作者: wafwerar's avatar wafwerar

fix(os): run case on win

上级 704fc256
......@@ -148,17 +148,13 @@ if __name__ == "__main__":
tdDnodes.deploy(1,{})
tdDnodes.startWin(1)
else:
# remote_conn = Connection("root@%s"%host)
# with remote_conn.cd('/var/lib/jenkins/workspace/TDinternal/community/tests/pytest'):
# remote_conn.run("python3 ./test.py")
os.system("docker exec -d tdengine_test bash -c \"cd ~/TDinternal/community/tests/pytest && python3 ./test.py\"")
time.sleep(2)
remote_conn = Connection("root@%s"%host)
with remote_conn.cd('/var/lib/jenkins/workspace/TDinternal/community/tests/pytest'):
remote_conn.run("python3 ./test.py")
tdDnodes.init(deployPath)
conn = taos.connect(
host="%s" % (host),
config=tdDnodes.sim.getCfgDir())
print(host)
print(tdDnodes.sim.getCfgDir())
tdCases.runOneWindows(conn, fileName)
tdCases.logSql(logSql)
else:
......
......@@ -518,8 +518,7 @@ class TDDnodes:
processID = subprocess.check_output(
psCmd, shell=True).decode("utf-8")
binPath = os.path.dirname(os.path.realpath(__file__))
binPath = binPath + "/../../../debug/"
binPath = self.dnodes[0].getPath() + "/../../../"
tdLog.debug("binPath %s" % (binPath))
binPath = os.path.realpath(binPath)
tdLog.debug("binPath real path %s" % (binPath))
......@@ -546,7 +545,6 @@ class TDDnodes:
for i in range(len(self.dnodes)):
self.dnodes[i].init(self.path)
print(self.path)
self.sim = TDSimClient(self.path)
def setTestCluster(self, value):
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册