meson: Clean up test declarations a bit

This commit is contained in:
Kenny Levinsen 2021-03-15 20:22:55 +01:00
parent d8ddf590fa
commit 951c1790fa

View file

@ -186,31 +186,18 @@ if get_option('examples').enabled()
) )
endif endif
test( tests = {
'linked_list', 'linked_list': ['common/linked_list.c'],
executable( 'connection': ['common/connection.c'],
'linked_list_test', 'poller': ['common/linked_list.c', 'seatd/poller.c'],
['common/linked_list.c', 'tests/linked_list.c'], }
include_directories: [include_directories('.', 'include')],
)
)
test(
'poller',
executable(
'poller_test',
['common/linked_list.c', 'seatd/poller.c', 'tests/poller.c'],
include_directories: [include_directories('.', 'include')],
)
)
test( foreach name, value : tests
'connection', test(name, executable(
executable( '@0@_test'.format(name),
'connection_test', ['tests/@0@.c'.format(name), value],
['common/connection.c', 'tests/connection.c'], include_directories: [include_directories('.', 'include')]))
include_directories: [include_directories('.', 'include')], endforeach
)
)
if get_option('server').enabled() if get_option('server').enabled()
scdoc = dependency('scdoc', required: get_option('man-pages'), version: '>= 1.9.7', native: true) scdoc = dependency('scdoc', required: get_option('man-pages'), version: '>= 1.9.7', native: true)