test/x11comp.c


Log

Author Commit Date CI Message
Pierre Le Marre a4038a47 2025-02-12T09:50:36 Miscellaneous int types fixes
Ran Benita e120807b 2025-01-29T15:35:22 Update license notices to SDPX short identifiers + update LICENSE Fix #628. Signed-off-by: Ran Benita <ran@unusedvar.com>
Pierre Le Marre 0ed9390c 2024-03-14T09:08:55 test(x11): Do not skip test when setup fails With the current setup, the tests passes even if there is an issue with the setup. X11 tests are already guarded with `enable-x11=true`, so there is no reason to skip these tests if we built the X11 support. Meson supports the GNU convention for exit code in tests: - 77: test skipped; already used in xkbcommon: `SKIP_TEST`. - 99: hard error/setup failure; introduced in this commit: `TEST_SETUP_FAILURE`. Meson reports setup failure as `ERROR`, while a test failure is reported as `FAIL`. In both cases it will make the CI fail, allowing us to correctly detect any errors. Fixed: - Use `TEST_SETUP_FAILURE` instead of `SKIP_TEST` for X11 setup failures. - Xvfb wrapper: Add verbosity for debugging.
Pierre Le Marre e325e65e 2024-02-20T08:13:37 Add test_unit to all tests Currently it only ensure we do not buffer `stdout`.
Pierre Le Marre fe9cd66f 2023-09-18T13:17:30 Test: Enable x11comp and use the xvfb wrapper This test was previously disabled in 914e84e0188b5fbd67855f38f4499bb1412f4516. Note that it requires a recent version of xkeyboard-config to succeed.
Ran Benita 40aab05e 2019-12-27T13:03:20 build: include config.h manually Previously we included it with an `-include` compiler directive. But that's not portable. And it's better to be explicit anyway. Every .c file should have `include "config.h"` first thing. Signed-off-by: Ran Benita <ran@unusedvar.com>
Ran Benita 2d964065 2017-07-29T23:31:19 test/x11comp: fix compiler warnings Signed-off-by: Ran Benita <ran234@gmail.com>
Ran Benita 5d821aed 2017-04-11T20:19:15 test/x11comp: be a bit more careful with kill() We did it correctly but better be safe and appease clang. Signed-off-by: Ran Benita <ran234@gmail.com>
Ran Benita 37ee8e65 2016-03-13T22:56:48 test/x11comp: fix memory leak Signed-off-by: Ran Benita <ran234@gmail.com>
Kazunobu Kuriyama 91a19905 2015-08-24T13:44:20 test/x11comp: Fix contention between X11 and Xvfb on Mac OS X - Abandon use of -displayfd. - Have x11comp itself look for an unused X11 display number instead.
Ran Benita bdf68803 2015-08-23T22:22:11 test/x11comp: small simplifications xkbcomp doesn't need the search-path argument, since we pass an absolute path. Keep the plain -I which clears the search path just to be sure. Signed-off-by: Ran Benita <ran234@gmail.com>
Pino Toscano e95fb475 2014-09-06T11:05:44 Remove <linux/input.h> include from test/x11comp.c libxkbcommon 0.4.3 introduces a new test, x11comp, which does not build on non-Linux OSes because of the unconditional <linux/input.h> include. This seems not needed even on Linux, so attached there is a simple patch to remove it. https://bugs.freedesktop.org/show_bug.cgi?id=83551 Signed-off-by: Ran Benita <ran234@gmail.com>
Ran Benita fc95057c 2014-09-01T17:20:40 test/x11comp: don't hang if Xvfb is not available If Xvfb is not present, posix_spawn still forks, but the child fails. In that case, since we left the write fd of the pipe open in the parent, we just kept waiting on the read() without noticing that the other side is dead. Signed-off-by: Ran Benita <ran234@gmail.com>
Ran Benita a95c4e83 2014-08-18T19:47:10 test/x11comp: server writes \n to displayfd Signed-off-by: Ran Benita <ran234@gmail.com>
Ran Benita 4df720b4 2014-08-09T22:14:34 test/x11-keyseq: new test It is like test/stringcomp, only instead of using xkb_keymap_new_from_string(), it uses xkbcomp to upload the keymap to a dummy Xvfb X server and then xkb_x11_keymap_new_from_device(). If any of these components are not present or fails, the test is shown as skipped. The test is messy, fragile, limited and depends on external tools, but I will improve on that later -- it's better to have a test. Signed-off-by: Ran Benita <ran234@gmail.com>