--- a/tests/run-tests.py Sat Jun 08 13:46:05 2013 +0100
+++ b/tests/run-tests.py Thu Jun 13 19:37:59 2013 +0100
@@ -904,8 +904,7 @@
return skip("blacklisted")
if options.retest and not os.path.exists(test + ".err"):
- ignore("not retesting")
- return None
+ return ignore("not retesting")
if options.keywords:
fp = open(test)
@@ -915,8 +914,7 @@
if k in t:
break
else:
- ignore("doesn't match keyword")
- return None
+ return ignore("doesn't match keyword")
for ext, func, out in testtypes:
if lctest.startswith("test-") and lctest.endswith(ext):
@@ -1091,7 +1089,7 @@
test = tests.pop(0)
if options.loop:
tests.append(test)
- t = threading.Thread(None, job, args=(test, count))
+ t = threading.Thread(target=job, args=(test, count))
t.start()
running += 1
count += 1
@@ -1167,7 +1165,12 @@
slow = 'svn gendoc check-code-hg'.split()
def sortkey(f):
# run largest tests first, as they tend to take the longest
- val = -os.stat(f).st_size
+ try:
+ val = -os.stat(f).st_size
+ except OSError, e:
+ if e.errno != errno.ENOENT:
+ raise
+ return -1e9 # file does not exist, tell early
for kw in slow:
if kw in f:
val *= 10