1 X server test suite 2 3This suite contains a set of tests to verify the behaviour of functions used 4internally to the server. This test suite is based on glib's testing 5framework [1]. 6 7= How it works = 8Through some automake abuse, we link the test programs with the same static 9libraries as the Xorg binary. The test suites can then call various functions 10and verify their behaviour - without the need to start the server or connect 11clients. 12 13This testing only works for functions that do not rely on a particular state 14of the X server. Unless the test suite replicates the expected state, which 15may be difficult. 16 17= How to run the tests = 18Run "make check" the test directory. This will compile the tests and execute 19them in the order specified in the TESTS variable in test/Makefile.am. 20 21Each set of tests related to a subsystem are available as a binary that can be 22executed directly. For example, run "xkb" to perform some xkb-related tests. 23 24== Adding a new test == 25When adding a new test, ensure that you add a short description of what the 26test does and what the expected outcome is. If the test reproduces a 27particular bug, using g_test_bug(). 28 29== Misc == 30 31The programs "gtester" and "gtester-report" may be used to generate XML/HTML 32log files of tests succeeded and failed. 33 34--------- 35 36[1] http://library.gnome.org/devel/glib/stable/glib-Testing.html 37