summaryrefslogtreecommitdiff
path: root/src/tests/edje/edje_test_edje.c
diff options
context:
space:
mode:
authorNak-Gyeong Kim <nakkyong.kim@samsung.com>2015-05-29 18:11:49 +0200
committerCedric BAIL <cedric@osg.samsung.com>2015-05-29 18:22:09 +0200
commit7d33ae501b2263ff1450c6351dea181573afe517 (patch)
treecd46ff3b8749c8206e433f68a8847e414db3d4f6 /src/tests/edje/edje_test_edje.c
parent7056b2f6e4af9c1ef9445472c018655a19a54e71 (diff)
edje: edje_cc_parse should check pair of parens.
Summary: Fix parens bug. ((x + y)-z) is OK. ((x + y) - z) is NOT OK. This patch can cover this case. @fix Signed-off-by: Nak-Gyeong Kim <nakkyong.kim@samsung.com> Test Plan: Test in edc. ((x + y)-z) is OK. ((x + y) - z) is NOT OK. This patch can cover this case. If parens are not paired, it will notify. Reviewers: raster, Hermet, cedric Subscribers: kimcinoo, jaehwan Differential Revision: https://phab.enlightenment.org/D2554 Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
Diffstat (limited to '')
-rw-r--r--src/tests/edje/edje_test_edje.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/tests/edje/edje_test_edje.c b/src/tests/edje/edje_test_edje.c
index 5a2fcee1dc..5e3485c8e1 100644
--- a/src/tests/edje/edje_test_edje.c
+++ b/src/tests/edje/edje_test_edje.c
@@ -151,6 +151,25 @@ START_TEST(edje_test_complex_layout)
151} 151}
152END_TEST 152END_TEST
153 153
154START_TEST(edje_test_calculate_parens)
155{
156 int x, y, w, h;
157 int r, g, b, a;
158 Evas *evas = EDJE_TEST_INIT_EVAS();
159 Evas_Object *obj;
160 const Evas_Object *bg;
161
162 obj = edje_object_add(evas);
163 fail_unless(edje_object_file_set(obj, test_layout_get("test_parens.edj"), "test_group"));
164
165 evas_object_resize(obj, 100, 100);
166 edje_object_part_geometry_get(obj, "background", &x, &y, &w, &h);
167 fail_if(x != 0 || y != 0 || w != 100 || h != 100);
168
169 EDJE_TEST_FREE_EVAS();
170}
171END_TEST
172
154void edje_test_edje(TCase *tc) 173void edje_test_edje(TCase *tc)
155{ 174{
156 tcase_add_test(tc, edje_test_edje_init); 175 tcase_add_test(tc, edje_test_edje_init);
@@ -158,4 +177,5 @@ void edje_test_edje(TCase *tc)
158 tcase_add_test(tc, edje_test_edje_load); 177 tcase_add_test(tc, edje_test_edje_load);
159 tcase_add_test(tc, edje_test_simple_layout_geometry); 178 tcase_add_test(tc, edje_test_simple_layout_geometry);
160 tcase_add_test(tc, edje_test_complex_layout); 179 tcase_add_test(tc, edje_test_complex_layout);
180 tcase_add_test(tc, edje_test_calculate_parens);
161} 181}