[PATCH 13/14] tests: test set for ivi-shell notification in bad condition with helper client
Nobuhiko Tanibata
nobuhiko_tanibata at xddp.denso.co.jp
Sun Jun 21 23:36:21 PDT 2015
From: Nobuhiko Tanibata <NOBUHIKO_TANIBATA at xddp.denso.co.jp>
These tests are implemented on test suite framework, which provides
helper client.
Following features are tested,
- add notfication of ivi-surface with bad condition
Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA at xddp.denso.co.jp>
Reviewed-by: Pekka Paalanen <pekka.paalanen at collabora.co.uk>
---
tests/ivi_layout-test-plugin.c | 22 ++++++++++++++++++++++
tests/ivi_layout-test.c | 1 +
2 files changed, 23 insertions(+)
diff --git a/tests/ivi_layout-test-plugin.c b/tests/ivi_layout-test-plugin.c
index 28afac9..5ac0135 100644
--- a/tests/ivi_layout-test-plugin.c
+++ b/tests/ivi_layout-test-plugin.c
@@ -1049,3 +1049,25 @@ RUNNER_TEST(surface_remove_notification_p3)
{
runner_assert(ctx->user_flags == 0);
}
+
+static void
+test_surface_bad_properties_changed_notification_callback(struct ivi_layout_surface *ivisurf,
+ const struct ivi_layout_surface_properties *prop,
+ enum ivi_layout_notification_mask mask,
+ void *userdata)
+{
+}
+
+RUNNER_TEST(surface_bad_properties_changed_notification)
+{
+ const struct ivi_controller_interface *ctl = ctx->controller_interface;
+ struct ivi_layout_surface *ivisurf;
+
+ ivisurf = ctl->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
+ runner_assert(ivisurf != NULL);
+
+ runner_assert(ctl->surface_add_notification(
+ NULL, test_surface_bad_properties_changed_notification_callback, NULL) == IVI_FAILED);
+ runner_assert(ctl->surface_add_notification(
+ ivisurf, NULL, NULL) == IVI_FAILED);
+}
diff --git a/tests/ivi_layout-test.c b/tests/ivi_layout-test.c
index 7091c9f..6c739da 100644
--- a/tests/ivi_layout-test.c
+++ b/tests/ivi_layout-test.c
@@ -197,6 +197,7 @@ const char * const basic_test_names[] = {
"surface_source_rectangle",
"surface_bad_opacity",
"surface_properties_changed_notification",
+ "surface_bad_properties_changed_notification",
};
const char * const surface_property_commit_changes_test_names[] = {
--
1.8.3.1
More information about the wayland-devel
mailing list