summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorIñigo Martínez <inigomartinez@gmail.com>2019-03-21 16:36:07 +0100
committerIñigo Martínez <inigomartinez@gmail.com>2019-03-30 21:15:41 +0100
commit79bd7e5a84b01e4a50365deca3ef799acd8c998b (patch)
tree1b890c265f020a5a200a9ffc6f66c8efc3fd4218 /tests
parent9b22a0251053b5869d6c2505aa9e9f34f16e0183 (diff)
downloadglade-79bd7e5a84b01e4a50365deca3ef799acd8c998b.tar.gz
build: Port to meson build system
meson is a build system focused on speed an ease of use, which helps speeding up the software development. meson build system has been added along with autotools.
Diffstat (limited to 'tests')
-rw-r--r--tests/meson.build52
1 files changed, 52 insertions, 0 deletions
diff --git a/tests/meson.build b/tests/meson.build
new file mode 100644
index 00000000..52594753
--- /dev/null
+++ b/tests/meson.build
@@ -0,0 +1,52 @@
+test_unit = [
+ ['add-child', {'sources': 'add-child.c'}],
+ ['create-widgets', {'sources': 'create-widgets.c'}],
+]
+
+sources = files('toplevel-order.c')
+
+# Generate resources
+resource_data = files(
+ 'toplevel_order_test2.glade',
+ 'toplevel_order_test3.glade',
+ 'toplevel_order_test4.glade',
+ 'toplevel_order_test5.glade',
+ 'toplevel_order_test6.glade',
+ 'toplevel_order_test.glade'
+)
+
+resource = 'toplevel-order-resources'
+
+sources += gnome.compile_resources(
+ resource,
+ resource + '.gresource.xml',
+ c_name: '_glade',
+ dependencies: resource_data,
+ export: true,
+)
+
+test_unit += [['toplevel-order', {'sources': sources}]]
+
+envs = [
+ 'GLADE_TESTING=1',
+ 'GLADE_CATALOG_SEARCH_PATH=' + (source_root / 'plugins/gtk+'),
+ 'GLADE_MODULE_SEARCH_PATH=' + (build_root / 'plugins/gtk+'),
+ 'GLADE_PIXMAP_DIR=' + (source_root / 'data/icons'),
+ 'GLADE_ICON_THEME_PATH=' + (source_root / 'plugins/gtk+/icons/22x22'),
+]
+
+foreach unit: test_unit
+ exe = executable(
+ unit[0],
+ include_directories: top_inc,
+ dependencies: libgladeui_dep,
+ c_args: common_c_flags,
+ kwargs: unit[1],
+ )
+
+ test(
+ unit[0],
+ exe,
+ env: envs,
+ )
+endforeach