summaryrefslogtreecommitdiff
path: root/src/tests/evas
diff options
context:
space:
mode:
authorabdulleh Ghujeh <a.ghujeh@samsung.com>2020-02-06 15:36:30 +0900
committerWooHyun Jung <wh0705.jung@samsung.com>2020-02-06 15:36:30 +0900
commitf5e13284d7d6cb2f8795e1ae87ff5b407ed56837 (patch)
tree424f2e861f14a31cbaefd793829087245fc67c65 /src/tests/evas
parente710d42fc0b112ba753ceeb10f2a1b27a398cfef (diff)
Evas Textblock: update obstacle test
Summary: Update the test to check that the first character is rendered after the obstacle. To ensure that the obstacle feature keeps working correctly. Reviewers: ali.alzyod, woohyun Reviewed By: ali.alzyod Subscribers: segfaultxavi, cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D11033
Diffstat (limited to 'src/tests/evas')
-rw-r--r--src/tests/evas/evas_test_textblock.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/tests/evas/evas_test_textblock.c b/src/tests/evas/evas_test_textblock.c
index d4b036c53f..a4e493a428 100644
--- a/src/tests/evas/evas_test_textblock.c
+++ b/src/tests/evas/evas_test_textblock.c
@@ -4094,6 +4094,8 @@ EFL_START_TEST(evas_textblock_obstacle)
4094 evas_object_resize(rect, 50, 50); 4094 evas_object_resize(rect, 50, 50);
4095 evas_object_resize(rect2, 50, 50); 4095 evas_object_resize(rect2, 50, 50);
4096 evas_object_resize(rect3, 50, 50); 4096 evas_object_resize(rect3, 50, 50);
4097 evas_object_resize(tb, 300, 400);
4098
4097 evas_object_textblock_text_markup_set(tb, buf); 4099 evas_object_textblock_text_markup_set(tb, buf);
4098 evas_textblock_cursor_format_prepend(cur, "<wrap=word>"); 4100 evas_textblock_cursor_format_prepend(cur, "<wrap=word>");
4099 evas_object_textblock_size_formatted_get(tb, &fw, &fh); 4101 evas_object_textblock_size_formatted_get(tb, &fw, &fh);
@@ -4110,6 +4112,11 @@ EFL_START_TEST(evas_textblock_obstacle)
4110 evas_object_show(rect2); 4112 evas_object_show(rect2);
4111 evas_object_show(rect3); 4113 evas_object_show(rect3);
4112 4114
4115 /*check if first character after the obstacle*/
4116 Evas_Coord cx;
4117 evas_textblock_cursor_char_geometry_get(cur, &cx, NULL, NULL, NULL);
4118 ck_assert_int_eq(cx, 50);
4119
4113 /* Compare formatted size with and without obstacle */ 4120 /* Compare formatted size with and without obstacle */
4114 _obstacle_run(tb, rect, 0, fw, fh / 2, fh / 2, fh); 4121 _obstacle_run(tb, rect, 0, fw, fh / 2, fh / 2, fh);
4115 /* Now, with bigger obstacles */ 4122 /* Now, with bigger obstacles */