aboutsummaryrefslogtreecommitdiffstats
path: root/tests/resources-test.c
diff options
context:
space:
mode:
authorKristian Høgsberg <krh@bitplanet.net>2014-01-20 15:07:55 -0800
committerKristian Høgsberg <krh@bitplanet.net>2014-01-20 15:07:55 -0800
commit3b8a1c7fed80dc9465115888610b82cd2fed1bd0 (patch)
tree4df85cfd33c71103b0c8887b547a67f6d7a3dae1 /tests/resources-test.c
parentprotocol: Clarify semantics of wl_subsurface.set_position (diff)
downloadwayland-3b8a1c7fed80dc9465115888610b82cd2fed1bd0.tar
wayland-3b8a1c7fed80dc9465115888610b82cd2fed1bd0.tar.gz
wayland-3b8a1c7fed80dc9465115888610b82cd2fed1bd0.tar.bz2
wayland-3b8a1c7fed80dc9465115888610b82cd2fed1bd0.tar.lz
wayland-3b8a1c7fed80dc9465115888610b82cd2fed1bd0.tar.xz
wayland-3b8a1c7fed80dc9465115888610b82cd2fed1bd0.tar.zst
wayland-3b8a1c7fed80dc9465115888610b82cd2fed1bd0.zip
resources-test: Don't send invalid event
Even if nothing receives the even, the arguments still need to be valid. The test is sending out event 0 from the wl_display interface, which is the error event. This requires arg 0 to be a valid object and arg 2 to be a non-null string. The test just leaves that undefined, causing intermittent test failures. As it is, the resource destroy test doesn't need to send an event to validate the various resource destroy hooks, so we can just remove the call to wl_resource_post_event() alltogether. Thanks to Matt Turner <mattst88@gmail.com> for pointing out the failure.
Diffstat (limited to 'tests/resources-test.c')
-rw-r--r--tests/resources-test.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/tests/resources-test.c b/tests/resources-test.c
index 514c031..a6ce3ae 100644
--- a/tests/resources-test.c
+++ b/tests/resources-test.c
@@ -107,9 +107,6 @@ TEST(destroy_res_tst)
wl_resource_set_implementation(res, NULL, &destroyed, res_destroy_func);
wl_resource_add_destroy_listener(res, &destroy_listener);
- /* without implementation this should be ignored .. */
- wl_resource_post_event(res, 0);
-
id = wl_resource_get_id(res);
link = wl_resource_get_link(res);
assert(link);