summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPekka Paalanen <pekka.paalanen@collabora.com>2019-02-06 10:53:35 +0200
committerDaniel Stone <daniel@fooishbar.org>2019-02-06 10:58:22 +0000
commita37920e77c1ca8bb5252da38e165cc0da2acadf1 (patch)
tree12da2c032bf6d8365425383c25209e1116a137b6
parent818c20e78bc1ab7d3a5cd58f14a0a66498fde7ba (diff)
downloadweston-a37920e77c1ca8bb5252da38e165cc0da2acadf1.tar.gz
tests: use weston_compositor_exit
Use the proper function to exit instead of the libwayland one, to allow main handle_exit() to be called. This is just to unify the exit paths. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
-rw-r--r--tests/plugin-registry-test.c2
-rw-r--r--tests/surface-global-test.c2
-rw-r--r--tests/surface-test.c2
-rw-r--r--tests/weston-test.c2
4 files changed, 4 insertions, 4 deletions
diff --git a/tests/plugin-registry-test.c b/tests/plugin-registry-test.c
index 81e26cd8..738ccd31 100644
--- a/tests/plugin-registry-test.c
+++ b/tests/plugin-registry-test.c
@@ -85,7 +85,7 @@ runtime_tests(void *data)
api = weston_plugin_api_get(compositor, MY_API_NAME, sz);
assert(api && api->func2 == dummy_func);
- wl_display_terminate(compositor->wl_display);
+ weston_compositor_exit(compositor);
}
WL_EXPORT int
diff --git a/tests/surface-global-test.c b/tests/surface-global-test.c
index 4604d19d..59d4152d 100644
--- a/tests/surface-global-test.c
+++ b/tests/surface-global-test.c
@@ -76,7 +76,7 @@ surface_to_from_global(void *data)
weston_view_from_global(view, 5, 10, &ix, &iy);
assert(ix == 0 && iy == 0);
- wl_display_terminate(compositor->wl_display);
+ weston_compositor_exit(compositor);
}
WL_EXPORT int
diff --git a/tests/surface-test.c b/tests/surface-test.c
index 28520aaa..0661cc95 100644
--- a/tests/surface-test.c
+++ b/tests/surface-test.c
@@ -57,7 +57,7 @@ surface_transform(void *data)
weston_view_to_global_float(view, 50, 40, &x, &y);
assert(x == 200 && y == 340);
- wl_display_terminate(compositor->wl_display);
+ weston_compositor_exit(compositor);
}
WL_EXPORT int
diff --git a/tests/weston-test.c b/tests/weston-test.c
index e38aff4c..12ef54ee 100644
--- a/tests/weston-test.c
+++ b/tests/weston-test.c
@@ -72,7 +72,7 @@ test_client_sigchld(struct weston_process *process, int status)
/* In case the child aborted or segfaulted... */
assert(status == 0);
- wl_display_terminate(test->compositor->wl_display);
+ weston_compositor_exit(test->compositor);
}
static void