summaryrefslogtreecommitdiff
path: root/test/relay.c
diff options
context:
space:
mode:
authorMarc-André Lureau <marcandre.lureau@redhat.com>2022-02-09 12:23:56 +0400
committerSimon McVittie <smcv@collabora.com>2022-07-15 16:26:54 +0100
commit01b293027ee1b4be10cfd19f0cd1727fe7a1bef2 (patch)
tree0ff29548bb2da48d982fc9e3529c1e12bc14d274 /test/relay.c
parent03dac62937639dd4c701a582c26bb3bd35cc8028 (diff)
downloaddbus-01b293027ee1b4be10cfd19f0cd1727fe7a1bef2.tar.gz
test: enable AF_UNIX relay tests on !unix
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Diffstat (limited to 'test/relay.c')
-rw-r--r--test/relay.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/test/relay.c b/test/relay.c
index 77a40849..8bddec8c 100644
--- a/test/relay.c
+++ b/test/relay.c
@@ -129,9 +129,10 @@ setup (Fixture *f,
dbus_error_init (&f->e);
g_queue_init (&f->messages);
- if ((g_str_has_prefix (address, "tcp:") ||
- g_str_has_prefix (address, "nonce-tcp:")) &&
- !test_check_tcp_works ())
+ if ((g_str_has_prefix (address, "unix:") && !test_check_af_unix_works ()) ||
+ ((g_str_has_prefix (address, "tcp:") ||
+ g_str_has_prefix (address, "nonce-tcp:")) &&
+ !test_check_tcp_works ()))
{
f->skip = TRUE;
return;
@@ -354,14 +355,12 @@ main (int argc,
g_test_add ("/limit/tcp", Fixture, "tcp:host=127.0.0.1", setup,
test_limit, teardown);
-#ifdef DBUS_UNIX
g_test_add ("/connect/unix", Fixture, unix_tmpdir, setup,
test_connect, teardown);
g_test_add ("/relay/unix", Fixture, unix_tmpdir, setup,
test_relay, teardown);
g_test_add ("/limit/unix", Fixture, unix_tmpdir, setup,
test_limit, teardown);
-#endif
ret = g_test_run ();
dbus_shutdown ();