mirror of
https://gitlab.freedesktop.org/wayland/weston
synced 2024-09-06 18:05:39 +00:00
tests: migrate xwayland
Move xwayland test to the new harness. This is the only test that can actually skip. It does it by exit(77) and that is fine, because there is only one test case in the file so far. To get rid of the exit() calls we need to return a value from the TEST() function but that is a big surgery for another time. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
This commit is contained in:
parent
dd13498862
commit
56b94b5894
|
@ -208,7 +208,10 @@ if get_option('xwayland')
|
||||||
if not d.found()
|
if not d.found()
|
||||||
error('Xwayland tests require libX11 which was not found. Or, you can use \'-Dxwayland=false\'.')
|
error('Xwayland tests require libX11 which was not found. Or, you can use \'-Dxwayland=false\'.')
|
||||||
endif
|
endif
|
||||||
tests_weston += [ [ 'xwayland', [], d ] ]
|
tests += {
|
||||||
|
'name': 'xwayland',
|
||||||
|
'dep_objs': d,
|
||||||
|
}
|
||||||
endif
|
endif
|
||||||
|
|
||||||
# Manual test plugin, not used in the automatic suite
|
# Manual test plugin, not used in the automatic suite
|
||||||
|
|
|
@ -42,6 +42,19 @@
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
|
||||||
#include "weston-test-runner.h"
|
#include "weston-test-runner.h"
|
||||||
|
#include "weston-test-fixture-compositor.h"
|
||||||
|
|
||||||
|
static enum test_result_code
|
||||||
|
fixture_setup(struct weston_test_harness *harness)
|
||||||
|
{
|
||||||
|
struct compositor_setup setup;
|
||||||
|
|
||||||
|
compositor_setup_defaults(&setup);
|
||||||
|
setup.xwayland = true;
|
||||||
|
|
||||||
|
return weston_test_harness_execute_as_client(harness, &setup);
|
||||||
|
}
|
||||||
|
DECLARE_FIXTURE_SETUP(fixture_setup);
|
||||||
|
|
||||||
TEST(xwayland_client_test)
|
TEST(xwayland_client_test)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue