2014-04-05 01:57:18 +04:00
|
|
|
#!/usr/bin/env python3
|
|
|
|
|
|
|
|
import subprocess, os, multiprocessing
|
|
|
|
|
|
|
|
from config import *
|
|
|
|
|
|
|
|
def test_one(params):
|
|
|
|
python, architecture = params
|
|
|
|
try:
|
|
|
|
print ("Running: %s, %s" %params)
|
|
|
|
command = [r'%s\%s%s\Scripts\python.exe' % (VIRT_BASE, python, architecture),
|
|
|
|
'Tests/run.py',
|
|
|
|
'--installed']
|
|
|
|
proc = subprocess.Popen(command,
|
|
|
|
stdin=subprocess.PIPE,
|
|
|
|
stdout=subprocess.PIPE)
|
2014-04-05 02:18:14 +04:00
|
|
|
(trace, stderr) = proc.communicate()
|
|
|
|
status = proc.returncode
|
2014-04-05 01:57:18 +04:00
|
|
|
print ("Done with %s, %s -- %s" % (python, architecture, status ))
|
|
|
|
return (python, architecture, status, trace)
|
|
|
|
except Exception as msg:
|
|
|
|
print ("Error with %s, %s: %s" % (python, architecture, msg))
|
|
|
|
return (python, architecture, -1, str(msg))
|
|
|
|
|
|
|
|
|
|
|
|
if __name__=='__main__':
|
|
|
|
|
|
|
|
os.chdir('..')
|
2014-04-05 02:18:14 +04:00
|
|
|
pool = multiprocessing.Pool()
|
|
|
|
matrix = [(python, architecture) for python in pythons
|
2014-04-05 01:57:18 +04:00
|
|
|
for architecture in ('', 'x64')]
|
2014-04-05 02:18:14 +04:00
|
|
|
|
|
|
|
results = pool.map(test_one, matrix)
|
2014-04-05 01:57:18 +04:00
|
|
|
|
|
|
|
for (python, architecture, status, trace) in results:
|
|
|
|
print ("%s%s: %s" % (python, architecture, status))
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|