summaryrefslogtreecommitdiff
path: root/glib/tests/path-test-subdir
diff options
context:
space:
mode:
authorSimon McVittie <smcv@collabora.com>2021-01-28 18:16:36 +0000
committerSimon McVittie <smcv@collabora.com>2021-01-28 18:37:45 +0000
commit82adfd7e3aa6a14fee78bc89fd9a2e3bb4617538 (patch)
tree807fccbd30f38b09ae6b8ee4592ac63165a4ab6f /glib/tests/path-test-subdir
parent7ff0fb3af53a32d0094cf4767bbd019b1cfe550e (diff)
downloadglib-82adfd7e3aa6a14fee78bc89fd9a2e3bb4617538.tar.gz
Add test coverage for G_SPAWN_SEARCH_PATH
For manual test coverage that would reproduce the bug fixed in !1902, copy /bin/true (or any other harmless executable) to /usr/bin/spawn-test-helper. Signed-off-by: Simon McVittie <smcv@collabora.com>
Diffstat (limited to 'glib/tests/path-test-subdir')
-rw-r--r--glib/tests/path-test-subdir/meson.build6
-rw-r--r--glib/tests/path-test-subdir/spawn-test-helper.c7
2 files changed, 13 insertions, 0 deletions
diff --git a/glib/tests/path-test-subdir/meson.build b/glib/tests/path-test-subdir/meson.build
new file mode 100644
index 000000000..351254cd8
--- /dev/null
+++ b/glib/tests/path-test-subdir/meson.build
@@ -0,0 +1,6 @@
+executable('spawn-test-helper', 'spawn-test-helper.c',
+ c_args : test_cargs,
+ dependencies : test_deps,
+ install_dir: join_paths(installed_tests_execdir, 'path-test-subdir'),
+ install: installed_tests_enabled,
+)
diff --git a/glib/tests/path-test-subdir/spawn-test-helper.c b/glib/tests/path-test-subdir/spawn-test-helper.c
new file mode 100644
index 000000000..f9f2cee84
--- /dev/null
+++ b/glib/tests/path-test-subdir/spawn-test-helper.c
@@ -0,0 +1,7 @@
+#include <stdio.h>
+
+int main (void)
+{
+ fprintf (stderr, "this is spawn-test-helper from path-test-subdir\n");
+ return 5;
+}