summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/Makefile.am2
-rw-r--r--test/gvfs-all-tests.in4
-rw-r--r--test/meson.build79
3 files changed, 85 insertions, 0 deletions
diff --git a/test/Makefile.am b/test/Makefile.am
index 3c169e66..3142ce1e 100644
--- a/test/Makefile.am
+++ b/test/Makefile.am
@@ -119,4 +119,6 @@ EXTRA_DIST += \
files/testcert.pem \
files/powershot.ioctl \
files/powershot.umockdev \
+ meson.build \
+ gvfs-all-tests.in \
$(NULL)
diff --git a/test/gvfs-all-tests.in b/test/gvfs-all-tests.in
new file mode 100644
index 00000000..357b5d64
--- /dev/null
+++ b/test/gvfs-all-tests.in
@@ -0,0 +1,4 @@
+[Test]
+Type=session
+Exec=@testdir@/gvfs-test
+Output=TAP
diff --git a/test/meson.build b/test/meson.build
new file mode 100644
index 00000000..f323c1b0
--- /dev/null
+++ b/test/meson.build
@@ -0,0 +1,79 @@
+if enable_installed_tests
+ installed_tests_execdir = join_paths(gvfs_libexecdir, 'installed-tests', gvfs_name)
+ installed_tests_metadir = join_paths(gvfs_datadir, 'installed-tests', gvfs_name)
+
+ tests_conf = configuration_data()
+ tests_conf.set('testdir', installed_tests_execdir)
+
+ session = 'session.conf'
+
+ configure_file(
+ input: session + '.in',
+ output: session,
+ install: true,
+ install_dir: installed_tests_execdir,
+ configuration: tests_conf
+ )
+
+ all_tests = 'gvfs-all-tests'
+
+ configure_file(
+ input: all_tests + '.in',
+ output: all_tests + '.test',
+ install: true,
+ install_dir: installed_tests_metadir,
+ configuration: tests_conf
+ )
+
+ install_subdir(
+ 'files',
+ install_dir: installed_tests_execdir
+ )
+
+ gvfs_test = files('gvfs-test')
+
+ test_data = gvfs_test + [
+ daemon_service,
+ metadata_service
+ ]
+
+ if enable_afc
+ test_data += [afc_monitor, afc_service]
+ endif
+
+ if enable_gdu
+ test_data += [gdu_monitor, gdu_service]
+ endif
+
+ if enable_gphoto2
+ test_data += [gphoto2_monitor, gphoto2_service]
+ endif
+
+ if enable_udisks2
+ test_data += [udisks2_monitor, udisks2_service]
+ endif
+
+ install_data(
+ test_data,
+ install_dir: installed_tests_execdir
+ )
+endif
+
+if enable_devel_utils
+ tests = [
+ 'benchmark-gvfs-big-files',
+ 'benchmark-gvfs-small-files',
+ 'benchmark-posix-big-files',
+ 'benchmark-posix-small-files',
+ 'test-query-info-stream'
+ ]
+
+ foreach test: tests
+ executable(
+ test,
+ test + '.c',
+ include_directories: top_inc,
+ dependencies: glib_deps
+ )
+ endforeach
+endif