summaryrefslogtreecommitdiff
path: root/bus
diff options
context:
space:
mode:
authorSimon McVittie <smcv@collabora.com>2018-07-12 17:38:04 +0100
committerSimon McVittie <smcv@collabora.com>2018-11-16 15:16:21 +0000
commit2908a4da6a4da4d3c86839730808a6a79a2e73e4 (patch)
tree46f8841f4145d7cb222eb21524143e72036f2640 /bus
parentdd4fb66f67869487af071a53987a8f337913ef77 (diff)
downloaddbus-2908a4da6a4da4d3c86839730808a6a79a2e73e4.tar.gz
embedded tests: Make it easier to run a single test-case
When running tests under "make check" or similar to take advantage of facilities like AM_TESTS_ENVIRONMENT and AX_VALGRIND_CHECK, it's more straightforward to set an environment variable than to pass a command-line option. Signed-off-by: Simon McVittie <smcv@collabora.com> Reviewed-by: Philip Withnall <withnall@endlessm.com> Bug: https://gitlab.freedesktop.org/dbus/dbus/issues/218
Diffstat (limited to 'bus')
-rw-r--r--bus/test-main.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/bus/test-main.c b/bus/test-main.c
index ba73a1b4..d2229f75 100644
--- a/bus/test-main.c
+++ b/bus/test-main.c
@@ -96,7 +96,7 @@ main (int argc, char **argv)
if (argc > 2)
only = argv[2];
else
- only = NULL;
+ only = _dbus_getenv ("DBUS_TEST_ONLY");
if (dir == NULL)
_dbus_test_fatal ("Must specify test data directory as argv[1] or in DBUS_TEST_DATA env variable");