diff options
Diffstat (limited to 'tools/tests/meson.build')
-rw-r--r-- | tools/tests/meson.build | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/tools/tests/meson.build b/tools/tests/meson.build new file mode 100644 index 00000000..deed6c3e --- /dev/null +++ b/tools/tests/meson.build @@ -0,0 +1,30 @@ +# SPDX-License-Identifier: GPL-2.0-or-later +# Copyright (C) 2021 IƱigo Martinez <inigomartinez@gmail.com> + +test_conf = { + 'abs_top_builddir': build_root, + 'abs_top_srcdir': source_root, +} + +subdir('services') + +test_wrapper = configure_file( + input: 'test-wrapper.sh.in', + output: '@BASENAME@', + configuration: test_conf, +) + +# common +if enable_gir + test_unit = 'test-stub' + + exe = executable( + test_unit, + test_unit + '.c', + include_directories: [top_inc, src_inc], + dependencies: libmm_glib_dep, + c_args: '-DTEST_SERVICES="@0@"'.format(meson.current_build_dir() / 'services'), + ) + + test(test_unit, exe) +endif |