meson: specify a timeout of 90 s for tests which take a bit longer
Both test-hashmap and test-benchmark need 10-11 s here, but might time out under load with the default meson timeout of 30 s.
This commit is contained in:
parent
8191c5948b
commit
81efcc1c89
|
@ -2075,8 +2075,13 @@ foreach tuple : tests
|
||||||
type = tuple.length() >= 5 ? tuple[4] : ''
|
type = tuple.length() >= 5 ? tuple[4] : ''
|
||||||
defs = tuple.length() >= 6 ? tuple[5] : []
|
defs = tuple.length() >= 6 ? tuple[5] : []
|
||||||
incs = tuple.length() >= 7 ? tuple[6] : includes
|
incs = tuple.length() >= 7 ? tuple[6] : includes
|
||||||
|
timeout = 30
|
||||||
|
|
||||||
name = sources[0].split('/')[-1].split('.')[0]
|
name = sources[0].split('/')[-1].split('.')[0]
|
||||||
|
if type.startswith('timeout=')
|
||||||
|
timeout = type.split('=')[1].to_int()
|
||||||
|
type = ''
|
||||||
|
endif
|
||||||
|
|
||||||
if condition == '' or conf.get(condition, 0) == 1
|
if condition == '' or conf.get(condition, 0) == 1
|
||||||
install = install_tests and type == ''
|
install = install_tests and type == ''
|
||||||
|
@ -2097,7 +2102,9 @@ foreach tuple : tests
|
||||||
elif type == 'unsafe' and want_tests != 'unsafe'
|
elif type == 'unsafe' and want_tests != 'unsafe'
|
||||||
message('@0@ is an unsafe test'.format(name))
|
message('@0@ is an unsafe test'.format(name))
|
||||||
else
|
else
|
||||||
test(name, exe, env : test_env)
|
test(name, exe,
|
||||||
|
env : test_env,
|
||||||
|
timeout : timeout)
|
||||||
endif
|
endif
|
||||||
else
|
else
|
||||||
message('Not compiling @0@ because @1@ is not true'.format(name, condition))
|
message('Not compiling @0@ because @1@ is not true'.format(name, condition))
|
||||||
|
|
|
@ -340,7 +340,8 @@ tests += [
|
||||||
'src/test/test-hashmap-plain.c',
|
'src/test/test-hashmap-plain.c',
|
||||||
test_hashmap_ordered_c],
|
test_hashmap_ordered_c],
|
||||||
[libshared],
|
[libshared],
|
||||||
[]],
|
[],
|
||||||
|
'', 'timeout=90'],
|
||||||
|
|
||||||
[['src/test/test-set.c'],
|
[['src/test/test-set.c'],
|
||||||
[libshared],
|
[libshared],
|
||||||
|
@ -698,7 +699,8 @@ tests += [
|
||||||
[libjournal_core,
|
[libjournal_core,
|
||||||
libshared],
|
libshared],
|
||||||
[liblz4,
|
[liblz4,
|
||||||
libxz]],
|
libxz],
|
||||||
|
'', 'timeout=90'],
|
||||||
|
|
||||||
[['src/journal/test-audit-type.c'],
|
[['src/journal/test-audit-type.c'],
|
||||||
[libjournal_core,
|
[libjournal_core,
|
||||||
|
|
Loading…
Reference in a new issue