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>
diff --git a/tests/surface-test.c b/tests/surface-test.c
index 28520aa..0661cc9 100644
--- a/tests/surface-test.c
+++ b/tests/surface-test.c
@@ -57,7 +57,7 @@
 	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