Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions test.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,9 @@
if not pythonExecutable:
pythonExecutable = "python"

# adds quotes to sorround path elements that contain blank characters - to be used only for Popen calls under Windows
pythonExecutablePopenWin = os.path.join(*['\"'+i+'\"' if ' ' in i else i+'\\' if ':' in i else i for i in pythonExecutable.split('\\')]) if isWin else ''

def fflush():
sys.stdout.flush()
sys.stderr.flush()
Expand Down Expand Up @@ -747,7 +750,7 @@ def runScript(c, timeout, memoryLimit, runverbose):
sys.stdout.flush()

if isWin:
res_cmd = runCommand("%s testmodel.py --win --msysEnvironment=%s --libraries=%s %s --ompython_omhome=%s %s.conf.json > files/%s.cmdout 2>&1" % (pythonExecutable, msysEnvironment, librariespath, ("--docker %s --dockerExtraArgs '%s'" % (docker, " ".join(dockerExtraArgs))) if docker else "", ompython_omhome, c, c), prefix=c, timeout=timeout)
res_cmd = runCommand("%s testmodel.py --win --msysEnvironment=%s --libraries=\"%s\" %s --ompython_omhome=%s %s.conf.json > files/%s.cmdout 2>&1" % (pythonExecutablePopenWin, msysEnvironment, librariespath, ("--docker %s --dockerExtraArgs '%s'" % (docker, " ".join(dockerExtraArgs))) if docker else "", ompython_omhome, c, c), prefix=c, timeout=timeout)
else:
res_cmd = runCommand("ulimit -v %d; ./testmodel.py --libraries=%s %s --ompython_omhome=%s %s.conf.json > files/%s.cmdout 2>&1" % (memoryLimit, librariespath, ("--docker %s --dockerExtraArgs '%s'" % (docker, " ".join(dockerExtraArgs))) if docker else "", ompython_omhome, c, c), prefix=c, timeout=timeout)

Expand Down Expand Up @@ -1086,7 +1089,7 @@ def cpu_name():
try:
rmtree("files/")
except:
print("-- problemduring removing of ./files dir")
print("-- problem during removing of ./files dir")

# Do not commit until we have generated and uploaded the reports
conn.commit()
Expand Down