Fix Windows. Again.
This commit is contained in:
parent
a7e9301215
commit
e522a9f268
|
@ -58,6 +58,7 @@ class Environment():
|
||||||
log_dir = 'meson-logs'
|
log_dir = 'meson-logs'
|
||||||
coredata_file = os.path.join(private_dir, 'coredata.dat')
|
coredata_file = os.path.join(private_dir, 'coredata.dat')
|
||||||
version_regex = '\d+(\.\d+)+(-[a-zA-Z0-9]+)?'
|
version_regex = '\d+(\.\d+)+(-[a-zA-Z0-9]+)?'
|
||||||
|
|
||||||
def __init__(self, source_dir, build_dir, main_script_file, options, original_cmd_line_args):
|
def __init__(self, source_dir, build_dir, main_script_file, options, original_cmd_line_args):
|
||||||
assert(os.path.isabs(main_script_file))
|
assert(os.path.isabs(main_script_file))
|
||||||
assert(not os.path.islink(main_script_file))
|
assert(not os.path.islink(main_script_file))
|
||||||
|
|
14
run_tests.py
14
run_tests.py
|
@ -309,10 +309,20 @@ def run_tests(extra_args):
|
||||||
# and getting it wrong by not doing logical number sorting.
|
# and getting it wrong by not doing logical number sorting.
|
||||||
(testnum, testbase) = os.path.split(t)[-1].split(' ', 1)
|
(testnum, testbase) = os.path.split(t)[-1].split(' ', 1)
|
||||||
testname = '%.3d %s' % (int(testnum), testbase)
|
testname = '%.3d %s' % (int(testnum), testbase)
|
||||||
result = executor.submit(run_test, skipped, t, extra_args, name != 'failing')
|
# Windows errors out when calling result.result() below with
|
||||||
|
# a bizarre error about appending None to an array that comes
|
||||||
|
# from the standard library. This is probably either because I use
|
||||||
|
# XP or the Python version is old. Anyhow, fall back to immediate
|
||||||
|
# evaluation. This causes output not to be printed until the end,
|
||||||
|
# which is unfortunate but least it works.
|
||||||
|
if mesonlib.is_windows():
|
||||||
|
result = run_test(skipped, t, extra_args, name != 'failing')
|
||||||
|
else:
|
||||||
|
result = executor.submit(run_test, skipped, t, extra_args, name != 'failing')
|
||||||
futures.append((testname, t, result))
|
futures.append((testname, t, result))
|
||||||
for (testname, t, result) in futures:
|
for (testname, t, result) in futures:
|
||||||
result = result.result()
|
if not mesonlib.is_windows(): # See above.
|
||||||
|
result = result.result()
|
||||||
if result is None:
|
if result is None:
|
||||||
print('Skipping:', t)
|
print('Skipping:', t)
|
||||||
current_test = ET.SubElement(current_suite, 'testcase', {'name' : testname,
|
current_test = ET.SubElement(current_suite, 'testcase', {'name' : testname,
|
||||||
|
|
Loading…
Reference in New Issue