summaryrefslogtreecommitdiff
path: root/examples/python/meson.build
diff options
context:
space:
mode:
Diffstat (limited to 'examples/python/meson.build')
-rw-r--r--examples/python/meson.build22
1 files changed, 22 insertions, 0 deletions
diff --git a/examples/python/meson.build b/examples/python/meson.build
new file mode 100644
index 000000000..39c464520
--- /dev/null
+++ b/examples/python/meson.build
@@ -0,0 +1,22 @@
+python = find_program('python3')
+
+env = environment()
+env.prepend('GI_TYPELIB_PATH', tracker_sparql_uninstalled_dir)
+env.prepend('LD_LIBRARY_PATH', tracker_sparql_uninstalled_dir)
+env.prepend('PYTHONPATH', tracker_uninstalled_testutils_dir)
+env.set('TRACKER_EXAMPLES_AUTOMATED_TEST', '1')
+env.set('TEST_ONTOLOGIES_DIR', tracker_uninstalled_nepomuk_ontologies_dir)
+
+sandbox_python_args = ['-m', 'trackertestutils', '--store-tmpdir', '--dbus-config', meson.current_build_dir() / '..' / '..' / 'tests' / 'test-bus.conf']
+
+examples = [
+ 'endpoint',
+]
+
+foreach example_name: examples
+ file = meson.current_source_dir() / '@0@.py'.format(example_name)
+ test(example_name, python,
+ args: sandbox_python_args + [file],
+ env: env,
+ suite: 'examples')
+endforeach