test.py: more python-2.5 support (process.terminate)

This commit is contained in:
Aapo Rantalainen 2013-03-24 07:57:49 +02:00
parent df1d321b96
commit 62c378852a

View file

@ -7,7 +7,7 @@ import subprocess
import threading
PPSSPP_EXECUTABLES = [ "Windows\\Release\\PPSSPPHeadless.exe", "build/PPSSPPHeadless" ]
PPSSPP_EXECUTABLES = [ "Windows\\Release\\PPSSPPHeadless.exe", "build/PPSSPPHeadless","./PPSSPPHeadless" ]
PPSSPP_EXE = None
TEST_ROOT = "pspautotests/tests/"
teamcity_mode = False
@ -32,6 +32,10 @@ class Command(object):
thread.join(timeout)
if thread.isAlive():
self.timeout = True
if sys.version_info < (2, 6):
os.kill(process.pid, signal.SIGKILL)
else:
process.terminate()
self.process.terminate()
thread.join()