2 * Tested interface: AtkObject
4 * Tested AtkObject: EailActionSlider
6 * Description: Test whether accessible object is successfully registered
7 * in GObject type system and is visible in AtkObject tree.
9 * Test input: accessible object representing EailActionSlider
11 * Expected test result: test should return 0 (success)
14 #include <Elementary.h>
17 #include "eail_test_utils.h"
19 INIT_TEST("EailActionSlider")
22 _init_action_slider(Evas_Object *win)
24 Evas_Object *bg, *bx, *as;
27 elm_win_resize_object_add(win, bg);
28 evas_object_size_hint_weight_set(bg, EVAS_HINT_EXPAND, 0);
31 bx = elm_box_add(win);
32 evas_object_size_hint_weight_set(bx, EVAS_HINT_EXPAND, 0);
33 elm_win_resize_object_add(win, bx);
36 as = elm_actionslider_add(win);
37 evas_object_size_hint_weight_set(as, EVAS_HINT_EXPAND, 0);
38 evas_object_size_hint_align_set(as, EVAS_HINT_FILL, 0);
39 elm_object_part_text_set(as, "left", "left1");
40 elm_object_part_text_set(as, "center", "center1");
41 elm_object_part_text_set(as, "right", "right1");
42 elm_actionslider_indicator_pos_set(as, ELM_ACTIONSLIDER_LEFT);
44 elm_box_pack_end(bx, as);
48 _do_test(AtkObject *obj)
50 g_assert(ATK_IS_OBJECT(obj));
51 g_assert(atk_object_get_role(obj) == ATK_ROLE_SLIDER);
52 atk_object_set_description(obj, "test");
53 g_assert_cmpstr(atk_object_get_description(obj), ==, "test");
54 atk_object_set_name(obj, "test name");
55 g_assert_cmpstr(atk_object_get_name(obj), ==, "test name");
57 eailu_test_code_called = 1;
61 elm_main(int argc, char **argv)
65 win = eailu_create_test_window_with_glib_init(_on_done, _on_focus_in);
67 _init_action_slider(win);
68 evas_object_show(win);