Merge pull request #13911 from taosdata/fix/ZhiqiangWang/TD-16357-add-auto-exit-case

test: add auto exit case
This commit is contained in:
Zhiqiang Wang 2022-06-16 20:54:58 +08:00 committed by GitHub
commit d3e2d1f3ef
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 8 additions and 0 deletions

View File

@ -33,8 +33,16 @@ import taos
def checkRunTimeError():
import win32gui
timeCount = 0
while 1:
time.sleep(1)
timeCount = timeCount + 1
if (timeCount>900):
os.system("TASKKILL /F /IM taosd.exe")
os.system("TASKKILL /F /IM taos.exe")
os.system("TASKKILL /F /IM tmq_sim.exe")
os.system("TASKKILL /F /IM mintty.exe")
quit(0)
hwnd = win32gui.FindWindow(None, "Microsoft Visual C++ Runtime Library")
if hwnd:
os.system("TASKKILL /F /IM taosd.exe")