]> git.ipfire.org Git - thirdparty/dbus.git/commitdiff
test-privserver: Move helper executable out of name-test/
authorSimon McVittie <smcv@collabora.com>
Tue, 11 Dec 2018 11:52:38 +0000 (11:52 +0000)
committerSimon McVittie <smcv@collabora.com>
Thu, 13 Dec 2018 13:08:00 +0000 (13:08 +0000)
This means we don't need to distinguish between DBUS_NAME_TEST_EXEC and
DBUS_TEST_EXEC any more, because all test helper executables are in the
same place, both during build and when installed (we don't install
test-privserver since no installed test requires it yet, but in
principle we could).

Signed-off-by: Simon McVittie <smcv@collabora.com>
cmake/CMakeLists.txt
cmake/test/CMakeLists.txt
cmake/test/name-test/CMakeLists.txt
configure.ac
test/.gitignore
test/Makefile.am
test/data/valid-service-files/org.freedesktop.DBus.TestSuite.PrivServer.service.in
test/name-test/.gitignore
test/name-test/Makefile.am
test/test-privserver.c [moved from test/name-test/test-privserver.c with 99% similarity]

index b0aa760e7cbc9d3395ddd3627ae0f78aa0b0c0e4..884b277fda6e24179b7a70f4d1f6e5474b43d1e5 100644 (file)
@@ -483,7 +483,6 @@ add_definitions(${DBUS_BUS_CFLAGS})
 if (DBUS_BUILD_TESTS)
     # set variables used for the .in files (substituted by configure_file) in test/data:
     set(DBUS_TEST_EXEC ${Z_DRIVE_IF_WINE}${EXECUTABLE_OUTPUT_PATH}${IDE_BIN})
-    set(DBUS_NAME_TEST_EXEC ${DBUS_TEST_EXEC})
     set(DBUS_TEST_DATA ${Z_DRIVE_IF_WINE}${CMAKE_BINARY_DIR}/test/data)
     set(TEST_LAUNCH_HELPER_BINARY ${Z_DRIVE_IF_WINE}${EXECUTABLE_OUTPUT_PATH}/dbus-daemon-launch-helper-test)
     if (UNIX)
index dc83f7724d1e70c5168e6235673a583c43867f3d..b505cc6172bae7d74def8a204dd3d01c15f4e02e 100644 (file)
@@ -74,6 +74,7 @@ add_helper_executable(test-service ${test-service_SOURCES} dbus-testutils)
 add_helper_executable(test-names ${test-names_SOURCES} dbus-testutils)
 add_test_executable(test-shell ${test-shell_SOURCES} ${DBUS_INTERNAL_LIBRARIES})
 add_test_executable(test-printf ${TEST_DIR}/internals/printf.c dbus-testutils)
+add_helper_executable(test-privserver ${TEST_DIR}/test-privserver.c dbus-testutils)
 add_helper_executable(test-shell-service ${test-shell-service_SOURCES} dbus-testutils)
 add_helper_executable(test-spawn ${test-spawn_SOURCES} ${DBUS_INTERNAL_LIBRARIES})
 add_helper_executable(test-exit ${test-exit_SOURCES} ${DBUS_INTERNAL_LIBRARIES})
index 029b69176881e672500c4316020647ba30e04d12..338720dfa924bbd4fdbffaa9c836ff74e85e40a0 100644 (file)
@@ -9,7 +9,6 @@ add_helper_executable(test-pending-call-timeout ${NAME_TEST_DIR}/test-pending-ca
 add_helper_executable(test-thread-init ${NAME_TEST_DIR}/test-threads-init.c ${DBUS_INTERNAL_LIBRARIES})
 add_helper_executable(test-ids ${NAME_TEST_DIR}/test-ids.c ${DBUS_INTERNAL_LIBRARIES})
 add_helper_executable(test-shutdown ${NAME_TEST_DIR}/test-shutdown.c dbus-testutils)
-add_helper_executable(test-privserver ${NAME_TEST_DIR}/test-privserver.c dbus-testutils)
 add_helper_executable(test-privserver-client ${NAME_TEST_DIR}/test-privserver-client.c dbus-testutils)
 add_helper_executable(test-autolaunch ${NAME_TEST_DIR}/test-autolaunch.c dbus-testutils)
 endif (DBUS_ENABLE_EMBEDDED_TESTS)
index 4636062ab08fd5a47ea58a730267f26f364891e5..bdd82d4604d18f7b483a8e6525989c5390631cff 100644 (file)
@@ -1556,12 +1556,10 @@ AC_ARG_WITH(dbus-test-dir, AS_HELP_STRING([--with-dbus-test-dir=[dirname]],[path
                           DBUS_PWD=$withval)
 
 DBUS_TEST_EXEC="$DBUS_PWD/test"
-DBUS_NAME_TEST_EXEC="$DBUS_PWD/test/name-test"
 DBUS_TEST_DATA="$DBUS_PWD/test/data"
 
 AC_SUBST([DBUS_TEST_DATA])
 AC_SUBST([DBUS_TEST_EXEC])
-AC_SUBST([DBUS_NAME_TEST_EXEC])
 
 AC_DEFINE_UNQUOTED([DBUS_EXEEXT], ["$EXEEXT"],
                    [Extension for executables, typically empty or .exe])
index 4eaae4a4e206ef74ee6f93d0acbb93f60ffc797d..597dbc60e978b0b15e9b15456e16870a7e4a83ba 100644 (file)
@@ -33,6 +33,7 @@ manual-dir-iter
 manual-tcp
 test-dbus-daemon-eavesdrop
 test-printf
+/test-privserver
 test-refs
 test-syntax
 test-syslog
index b8df15acd16c67fc0115332a5a4c1590e77c9991..1e7c2db44ec1de58e0add14d298d924a73e351a0 100644 (file)
@@ -66,6 +66,7 @@ TEST_BINARIES = \
        test-spawn \
        test-exit \
        test-names \
+       test-privserver \
        test-segfault \
        test-shell-service \
        $(NULL)
@@ -100,6 +101,7 @@ test_segfault_CFLAGS =
 
 test_service_LDADD = libdbus-testutils.la
 test_names_LDADD = libdbus-testutils.la
+test_privserver_LDADD = libdbus-testutils.la
 ## break_loader_LDADD = $(top_builddir)/dbus/libdbus-internal.la
 test_shell_service_LDADD = libdbus-testutils.la
 test_shell_SOURCES = shell-test.c
@@ -626,7 +628,6 @@ uninstalled-config-local:
                sed \
                        -e 's,[@]DBUS_SESSION_CONF_MAYBE_AUTH_EXTERNAL[@],$(DBUS_SESSION_CONF_MAYBE_AUTH_EXTERNAL),' \
                        -e 's,[@]DBUS_SESSION_BUS_LISTEN_ADDRESS[@],$(DBUS_SESSION_BUS_LISTEN_ADDRESS),' \
-                       -e 's,[@]DBUS_NAME_TEST_EXEC[@],$(DBUS_NAME_TEST_EXEC),' \
                        -e 's,[@]DBUS_TEST_DATA[@],@abs_builddir@/data,' \
                        -e 's,[@]DBUS_TEST_EXEC[@],@abs_builddir@,' \
                        -e 's,[@]DBUS_USER[@],$(DBUS_USER),' \
@@ -644,7 +645,6 @@ if DBUS_ENABLE_INSTALLED_TESTS
                sed \
                        -e 's,[@]DBUS_SESSION_CONF_MAYBE_AUTH_EXTERNAL[@],$(DBUS_SESSION_CONF_MAYBE_AUTH_EXTERNAL),' \
                        -e 's,[@]DBUS_SESSION_BUS_LISTEN_ADDRESS[@],$(DBUS_SESSION_BUS_LISTEN_ADDRESS),' \
-                       -e 's,[@]DBUS_NAME_TEST_EXEC[@],$(DBUS_NAME_TEST_EXEC),' \
                        -e 's,[@]DBUS_TEST_DATA[@],$(testexecdir)/data,' \
                        -e 's,[@]DBUS_TEST_EXEC[@],$(testexecdir),' \
                        -e 's,[@]DBUS_USER[@],$(DBUS_USER),' \
index 788d37a1cb087911d3568dedbde8552ce4cb22af..e2ac080be86b40fb3797284f284f3933c67222a0 100644 (file)
@@ -1,4 +1,4 @@
 [D-BUS Service]
 Name=org.freedesktop.DBus.TestSuite.PrivServer
-Exec=@DBUS_NAME_TEST_EXEC@/test-privserver@EXEEXT@
+Exec=@DBUS_TEST_EXEC@/test-privserver@EXEEXT@
 
index 2bf313a5fb11277100396d0016571a1d3574b72a..0ecde2f2c47cd61cb688af941fb8db60d7a23060 100644 (file)
@@ -8,7 +8,6 @@ test-ids
 test-names
 test-pending-call-dispatch
 test-pending-call-timeout
-test-privserver
 test-privserver-client
 test-shutdown
 test-threads-init
index 280eb8ea045527a5d7e00b2d6580fc0c0839a985..37d1472d61318843a1ea5173fb94b7ab7559ff8c 100644 (file)
@@ -66,7 +66,7 @@ if DBUS_ENABLE_EMBEDDED_TESTS
 
 ## we use noinst_PROGRAMS not check_PROGRAMS for TESTS so that we
 ## build even when not doing "make check"
-noinst_PROGRAMS=test-pending-call-dispatch test-pending-call-timeout test-pending-call-disconnected test-threads-init test-ids test-shutdown test-privserver test-privserver-client test-autolaunch
+noinst_PROGRAMS=test-pending-call-dispatch test-pending-call-timeout test-pending-call-disconnected test-threads-init test-ids test-shutdown test-privserver-client test-autolaunch
 
 test_pending_call_dispatch_LDADD=$(top_builddir)/dbus/libdbus-1.la
 test_pending_call_timeout_LDADD=$(top_builddir)/dbus/libdbus-1.la
@@ -75,7 +75,6 @@ test_threads_init_LDADD=$(top_builddir)/dbus/libdbus-1.la
 test_ids_LDADD=$(top_builddir)/dbus/libdbus-1.la
 
 test_shutdown_LDADD=../libdbus-testutils.la
-test_privserver_LDADD=../libdbus-testutils.la
 test_privserver_client_LDADD=../libdbus-testutils.la
 test_autolaunch_LDADD=../libdbus-testutils.la
 
similarity index 99%
rename from test/name-test/test-privserver.c
rename to test/test-privserver.c
index 58eca1e90c60090810a35dc7676af848efb060ae..3c512d99a83894af6fec3d7e87da7d380fdb0b6c 100644 (file)
@@ -27,7 +27,7 @@
 
 #include <config.h>
 #include <dbus/dbus-valgrind-internal.h>
-#include "../test-utils.h"
+#include "test-utils.h"
 
 static void die (const char *message,
                  ...) _DBUS_GNUC_NORETURN _DBUS_GNUC_PRINTF (1, 2);