diff options
author | Benjamin Berg <bberg@redhat.com> | 2022-06-20 15:17:52 +0200 |
---|---|---|
committer | Benjamin Berg <bberg@redhat.com> | 2022-06-20 15:17:52 +0200 |
commit | ed42a0c5da70a7e786b55b86bcbd0dc4017fc467 (patch) | |
tree | f0086bf4f7c1059c20e1be4792f9895bdcc49dcb /tests/meson.build | |
parent | 51869ed6e6606ca1a1c200d518a83a5a609ac510 (diff) | |
download | libgudev-ed42a0c5da70a7e786b55b86bcbd0dc4017fc467.tar.gz |
tests: Add a test for g_udev_device_get_tags
Diffstat (limited to 'tests/meson.build')
-rw-r--r-- | tests/meson.build | 26 |
1 files changed, 15 insertions, 11 deletions
diff --git a/tests/meson.build b/tests/meson.build index 55fd09d..8c382ae 100644 --- a/tests/meson.build +++ b/tests/meson.build @@ -1,34 +1,38 @@ libgudev_tests = { + 'test-gudevdevice': { + 'dependencies': [gio_dep, libgudev_dep], + 'link_with': [libgudev], + 'sources': ['../gudev/gudevdevice.c'], + 'include_directories': [include_directories('../')], + }, 'test-enumerator-filter': { - 'dependencies': [gio_dep, umockdev_dep], + 'dependencies': [libgudev_dep, gio_dep, umockdev_dep], 'environment': ['LD_PRELOAD=libumockdev-preload.so.0'], }, 'test-sysfsattr': { - 'dependencies': [gio_dep, umockdev_dep], + 'dependencies': [libgudev_dep, gio_dep, umockdev_dep], 'environment': ['LD_PRELOAD=libumockdev-preload.so.0'], }, 'test-double': { - 'dependencies': [gio_dep, umockdev_dep], + 'dependencies': [libgudev_dep, gio_dep, umockdev_dep], 'environment': ['LD_PRELOAD=libumockdev-preload.so.0', 'LC_NUMERIC=fr_FR.UTF-8'], }, } -libgudev_tests_deps = [ - libgudev_dep, -] - foreach test_name, test_extras: libgudev_tests test_sources = ['@0@.c'.format(test_name)] - test_deps = libgudev_tests_deps - test_env = [] - test_deps += test_extras.get('dependencies', []) - test_env += test_extras.get('environment', []) + test_sources += test_extras.get('sources', []) + test_deps = test_extras.get('dependencies', []) + test_env = test_extras.get('environment', []) + test_include = test_extras.get('include_directories', []) test_exe = executable( test_name, test_sources, dependencies: test_deps, + include_directories: test_include, + c_args: ['-D_GUDEV_COMPILATION'] ) test( |