summaryrefslogtreecommitdiff
path: root/src/tests/edje/edje_test_edje.c
diff options
context:
space:
mode:
authorJean-Philippe Andre <jp.andre@samsung.com>2015-09-07 19:08:50 +0900
committerJean-Philippe Andre <jp.andre@samsung.com>2015-10-01 20:10:54 +0900
commit35fe059ec8091a7635117abfddb5ed3f83e2101e (patch)
tree235d727d5e92dcf89298baf5ced90fbadfbfddee /src/tests/edje/edje_test_edje.c
parent6ac4f7154b7750b7c9765f74428e2ebcc83290d9 (diff)
Edje: Add test case for SNAPSHOT
This is mostly an edje_cc compilation test.
Diffstat (limited to '')
-rw-r--r--src/tests/edje/edje_test_edje.c25
1 files changed, 25 insertions, 0 deletions
diff --git a/src/tests/edje/edje_test_edje.c b/src/tests/edje/edje_test_edje.c
index bf32f6d2e2..43eacdcc65 100644
--- a/src/tests/edje/edje_test_edje.c
+++ b/src/tests/edje/edje_test_edje.c
@@ -243,6 +243,30 @@ START_TEST(edje_test_filters)
243} 243}
244END_TEST 244END_TEST
245 245
246START_TEST(edje_test_snapshot)
247{
248 Evas *evas = EDJE_TEST_INIT_EVAS();
249 const Evas_Object *sub;
250 Evas_Object *obj, *src = NULL;
251 Eina_Bool b;
252
253 setenv("EVAS_DATA_DIR", EVAS_DATA_DIR, 1);
254
255 obj = edje_object_add(evas);
256 fail_unless(edje_object_file_set(obj, test_layout_get("test_snapshot.edj"), "test_group"));
257
258 evas_object_resize(obj, 200, 200);
259
260 /* check value of no_render flag as seen from evas land */
261 sub = edje_object_part_object_get(obj, "snap");
262 fail_if(!eo_do_ret(sub, b, evas_obj_image_snapshot_get()));
263
264 // TODO: Verify that evas snapshot actually works (and has a filter)
265
266 EDJE_TEST_FREE_EVAS();
267}
268END_TEST
269
246void edje_test_edje(TCase *tc) 270void edje_test_edje(TCase *tc)
247{ 271{
248 tcase_add_test(tc, edje_test_edje_init); 272 tcase_add_test(tc, edje_test_edje_init);
@@ -253,4 +277,5 @@ void edje_test_edje(TCase *tc)
253 tcase_add_test(tc, edje_test_calculate_parens); 277 tcase_add_test(tc, edje_test_calculate_parens);
254 tcase_add_test(tc, edje_test_masking); 278 tcase_add_test(tc, edje_test_masking);
255 tcase_add_test(tc, edje_test_filters); 279 tcase_add_test(tc, edje_test_filters);
280 tcase_add_test(tc, edje_test_snapshot);
256} 281}