summaryrefslogtreecommitdiff
path: root/cmake/test
AgeCommit message (Collapse)AuthorFilesLines
2014-01-17Let cmake 'make check' run test applications as test group.Ralf Habacker1-11/+1
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=73495 Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
2014-01-17Rename spawn-test to test-spawn to match common test application naming scheme.Ralf Habacker1-2/+2
[Same change as for shell-test in the previous commit. -smcv] Bug: https://bugs.freedesktop.org/show_bug.cgi?id=73495 Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
2014-01-17Rename shell-test to test-shell to match common test application naming scheme.Ralf Habacker1-3/+3
[Add its source file to SOURCES: this test was previously relying on the Automake feature that the default value of foo_bar_SOURCES is foo-bar.c. -smcv] Bug: https://bugs.freedesktop.org/show_bug.cgi?id=73495 Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
2014-01-10Use macros for test and helper executable targets on cmake build system.Ralf Habacker2-89/+30
The new macros add_test_executables and add helper_executables provides a platform independent way for specifing dbus test and service applications. On native Windows and Linux/UNIX systems the test applications are directly runable. When cross compiling for Windows on Linux test applications could be executed on the Linux host system with the help of wine and activated binfmt_misc support for wine. Bug: https://bugs.freedesktop.org/show_bug.cgi?id=41252 Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
2014-01-10Add 'check' cmake target to keep in sync with autotools.Ralf Habacker1-0/+14
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=41252 Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
2014-01-10Create session.conf and system.conf for test/data/valid-config-files from ↵Ralf Habacker1-2/+5
*.in files on cmake. We need to patch the listen address. Bug: https://bugs.freedesktop.org/show_bug.cgi?id=41252 Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
2014-01-10Define TEST_BUS_LAUNCH_BINARY for cmake to keep in sync with autotools.Ralf Habacker1-4/+0
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=41252 Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
2014-01-08Remove obsolete cmake project tags in sub directories; we only have one project.Ralf Habacker1-1/+0
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=68506 Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
2014-01-07Add glib support to cmake buildsystem.Ralf Habacker1-0/+46
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=68506 Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
2013-09-03Tests: allow dbus-glib to be replaced with use of libdbus-internalSimon McVittie1-1/+1
We only use dbus-glib for its main loop; within dbus, DBusLoop is available as an alternative, although it isn't thread-safe and isn't public API. For tests that otherwise only use libdbus public API, it's desirable to be able to avoid DBusLoop, so we can run them against an installed libdbus as an integration test. However, if we don't have dbus-glib, we're going to have to use an in-tree main loop, which might as well be DBusLoop. The major disadvantage of using dbus-glib is that it isn't safe to link both dbus-1 and dbus-internal at the same time. This is awkward for a future test case that wants to use _dbus_getsid() in dbus-daemon.c, but only on Windows (fd.o #54445). If we use the same API wrapper around both dbus-glib and DBusLoop, we can compile that test against dbus-glib or against DBusLoop, depending on the platform. Bug: https://bugs.freedesktop.org/show_bug.cgi?id=68852 Reviewed-by: Ralf Habacker <ralf.habacker@freenet.de>
2013-06-28tests to embedded tests: replaced in cmake filesChengwei Yang1-2/+2
Signed-off-by: Chengwei Yang <chengwei.yang@intel.com> Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk> Bug: https://bugs.freedesktop.org/show_bug.cgi?id=66291
2012-01-04Revert "made session service dirs customizable: cmake part"Simon McVittie1-3/+0
This reverts commit 89e453216c02bb85c5e53d459997f8bc3b2c73d4. It makes the tests fail under autotools.
2011-11-21made session service dirs customizable: cmake partRalf Habacker1-0/+3
2011-09-28Remove EXT variable from CMake, just use Automake-compatible EXEEXTSimon McVittie1-1/+1
According to Ralf, there's no standard name for this in CMake, so we might as well use the standard Automake name. Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk> Reviewed-by: Ralf Habacker <ralf.habacker@freenet.de> Bug: https://bugs.freedesktop.org/show_bug.cgi?id=41222
2011-09-28Merge tests' cmake and autotools bus configurationSimon McVittie1-4/+0
In Unix, the tests listened on both debug-pipe (which is a socketpair, or a TCP emulation of socketpair on Windows) and a Unix socket. In the Windows port, the tests were hard-coded to listen on a particular port, which allowed the dispatch test to connect to that port, as long as no two tests ran simultaneously (which I don't think was ever guaranteed - make -j can violate this). That's valid out-of-process, and also fully-specified, so they only needed one <listen> directive, so the CMake input only had one. To make the tests work under CMake on Unix, there was a hack: the string substituted for the content of the <listen> directive contained </listen><listen> to get the other address in, which is pretty nasty. Instead of doing that, I've made both build systems, on both Unix and Windows, use both debug-pipe and a more normal transport (Unix or TCP). debug-pipe has a Windows implementation and it's used in dbus-spawn-win.c, so it'd better work. The use of debug-pipe is now hard-coded rather than being a configure parameter (there's no reason to vary it in different builds), and I used TEST_LISTEN as the name of the Unix/TCP address, because it's a "vague" address (no specific Unix path, no TCP port), that you can listen on but not connect to. This in turn means that we can merge the Autoconf .in and CMake .cmake files, similar to Bug #41033. You might wonder why I've kept debug-pipe. I did try to get rid of it, but it turns out that the tests in dispatch.c rely on dbus_connection_open_private() not blocking, and normal socket connections block on connect(). Until we fix that by adding an async version of dbus_connection_open_private(), it won't be safe to have a test like dispatch.c that "talks to itself", unless it uses a transport as trivial as debug-pipe in which neither end has to block on the other. Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk> Reviewed-by: Ralf Habacker <ralf.habacker@freenet.de> Bug: https://bugs.freedesktop.org/show_bug.cgi?id=41222
2011-07-29Simplify linking for tests that use libdbus-testutilsSimon McVittie2-15/+9
This is the library used by tests that link libdbus-internal and DBusLoop. By linking libdbus-internal into it, we can avoid having to repeat that dependency all over the place - libtool and cmake both know how to follow recursive dependencies. In cmake, also use libdbus-testutils for more tests, in preference to repeating its source files.
2011-02-17Import compiler.m4 and lcov.am from telepathy-glib, and use them to replace gcovSimon McVittie1-7/+0
Reviewed-by: Colin Walters <walters@verbum.org> Bug: https://bugs.freedesktop.org/show_bug.cgi?id=10887
2010-12-04Keep in sync with automake.Ralf Habacker1-0/+4
2010-04-13Added missing test libraries and tools to keep in sync with autotools.Ralf Habacker2-0/+26
2010-04-13Keep test file directories in sync with autotoolsRalf Habacker1-10/+12
2010-04-11Cmake build system cleanup.Ralf Habacker1-57/+57
Converted tabs to spaces and removed trailing spaces in test dir.
2010-04-11Cmake support for cross plattform usable test files.Ralf Habacker1-7/+0
Recent test configuration files contains 'unix:...' bus adresses which do not work on windows. For cross plattform usable test files the whole listen tag entry has to be set by the build system, which is available with a new build system variable named TEST_LISTEN. To have the client client side definition in sync, TEST_CONNECTION has been moved from c file into cmake build system.
2010-04-09Simplified cmake specific test file generating.Ralf Habacker1-67/+24
If there is a *.cmake test file available for a related *.in file, take the *.cmake test file instead of the *.in file as test file source. Also added some messages.
2010-03-22Keep cmake build system in sync with commit ↵Ralf Habacker1-5/+0
d47154c28b68b32177773bd489fdae62b440f38c.
2010-03-22Make the windows binaries and build match the linux one with cmake buildsystem.unknown1-0/+2
This is performed by including the files from the client lib in the internal one and by removing the linking to dbus-1 for targets using the internal library.
2010-03-20CMake dbus libraries usage cleanup.Ralf Habacker2-14/+12
Renamed DBUS_LIBRARIES to DBUS_INTERNAL_LIBRARIES and moved to top level CMakeLists.txt. Removed obsolate references of dbus-internal library. Added DBUS_LIBRARIES definition which contains only the dbus library.
2010-03-08fixed bus-test sha1 connection address on unix with cmake build systemRalf Habacker1-1/+6
2010-02-07commented bits cleanupRomain Pokrzywka2-36/+0
2010-02-07now fix the build for the tests; turns out we need another set of exports, ↵Romain Pokrzywka2-12/+14
since some tests are compiled in the client lib and some are in the internal lib...
2009-12-01readded test files required for windowsRalf Habacker1-0/+10
2009-11-30do not run test binaries as unit tests if they aren't unit tests (cherry ↵Frank Osterfeld1-10/+0
picked from commit 5281f5b113bd97152d1c9eac050432bda3274748)
2009-11-30fix warning, use Sleep, not _sleep on windows (cherry picked from commit ↵Frank Osterfeld1-4/+0
ea36c743ad60a2dd5c6286571d1a475903519809)
2009-11-30fix TEST_SOCKET_DIR on windows, do not override value from top-level in ↵Frank Osterfeld1-2/+0
test/ (cherry picked from commit fde144333281348cda2d533331946996d7a09bff)
2009-11-30bus-test-launch-helper is a unit test, test-service and test-shell-service ↵Frank Osterfeld1-11/+4
are not. Rename test-shell to shell-test to match autotools (cherry picked from commit b106387b73d6a300a013a15f6507244e82f007ed)
2009-11-30Use correct sources to build test-shell-service, fixes a hang in bus-test ↵Frank Osterfeld1-1/+1
(cherry picked from commit 0afe04db5152b57582863bef83a55d78020a79c6)
2009-11-30removed obsolate filesRalf Habacker2-31/+0
2009-11-30cleanup: these files are already generated elsewhere (cherry picked from ↵Frank Osterfeld1-16/+0
commit 21f66df24affd4a4d2fb3324fb51899c811530da)
2009-11-30rename test-spawn to spawn-test, to match autotools. test-sleep-forever is ↵Frank Osterfeld1-6/+4
not a stand-alone test but called from other tests (cherry picked from commit 41bf95167cfc17b564594eab0a1901e46eaab5fe)
2009-11-30fix test and binary names (cherry picked from commit ↵Frank Osterfeld1-2/+2
18bcf5f2d474456c57cd94da234005a23e2589a7)
2009-11-30rename second test-names to test-names2 to avoid confusion (cherry picked ↵Frank Osterfeld1-4/+3
from commit c83a2d79bb215b19b02987c9a45ed1bf07e5eeaf)
2009-11-30generate all config files from the .in files. Set some of the required ↵Frank Osterfeld1-0/+19
variables replaced in the .in files by configure_file (cherry picked from commit 4980ffa1093877af182e032a13f6162df57be09f)
2009-11-30merge changes done to the cmake-buildsystem from the sf.net windbus-svn ↵Christian Ehrlicher2-31/+32
trunk. tested and works fine with at least msvc2008. (cherry picked from commit 45c168fd61e3f6447e014df4bb6417efbe725ccd)
2007-04-28* cmake/: don't install test applications and service files, moved ↵Ralf Habacker2-10/+10
CMAKE_DEBUG_POSTFIX to top level CMakeLists.txt
2007-03-03* cmake: new directory, contains cmake build support.Ralf Habacker4-0/+306
See http://www.cmake.org for more informations. Currently only unix will be buildable because some win32 required files are still missing.