about summary refs log tree commit diff
path: root/libnm-util/tests/meson.build
diff options
context:
space:
mode:
authorIain Lane <iain@orangesquash.org.uk>2018-09-24 09:29:55 +0100
committerIain Lane <iain@orangesquash.org.uk>2018-09-24 09:29:55 +0100
commite152ec7bf4ba252ff9d3eb13eabd417b931dac9a (patch)
treec323cf856ee0bb8e44590670dd54c19653a55748 /libnm-util/tests/meson.build
parentee9c73a923909e23a649407be77e25235d769e25 (diff)
Import Upstream version 1.12.2
Diffstat (limited to 'libnm-util/tests/meson.build')
-rw-r--r--libnm-util/tests/meson.build45
1 files changed, 45 insertions, 0 deletions
diff --git a/libnm-util/tests/meson.build b/libnm-util/tests/meson.build
new file mode 100644
index 00000000..cf46ad14
--- /dev/null
+++ b/libnm-util/tests/meson.build
@@ -0,0 +1,45 @@
+deps = [
+  dbus_dep,
+  dbus_glib_dep,
+  libnm_util_dep,
+  shared_dep
+]
+
+cflags = common_cflags + [
+  '-DNETWORKMANAGER_COMPILATION_TEST',
+] + nm_build_cflags
+
+test = 'test-libnm-linking'
+
+test_libnm_linking = executable(
+  test,
+  test + '.c',
+  dependencies: deps + [libnm_dep],
+  c_args: cflags
+)
+
+test_units = [
+  ['test-crypto', [libtest_crypto], []],
+  ['test-general', [], [test_libnm_linking]],
+  ['test-secrets', [], []],
+  ['test-setting-8021x', [], []],
+  ['test-setting-dcb', [], []],
+  ['test-settings-defaults', [], []]
+]
+
+foreach test_unit: test_units
+  exe = executable(
+    'libnm-util-' + test_unit[0],
+    test_unit[0] + '.c',
+    dependencies: deps,
+    c_args: cflags,
+    link_with: test_unit[1],
+    link_depends: test_unit[2]
+  )
+
+  test(
+    'libnm-util/' + test_unit[0],
+    test_script,
+    args: test_args + [exe.full_path()]
+  )
+endforeach