This commits imports final version of generate_wrapper.py.
Replaces mockups from original commit with new versions.
Change-Id: Ied824e80e25d544528f0c058c62c4918d70c5f3c
# FIND ALL SOURCE IN A SOURCE DIRECTORY
#AUX_SOURCE_DIRECTORY(${CMAKE_SOURCE_DIR}/src SRCS)
+#this values are required to generate mockups
+#SET(CMAKE_EXPORT_COMPILE_COMMANDS "ON")
+#ADD_DEFINITIONS("-DTIZEN_GTEST")
+
SET(SRCS ${CMAKE_SOURCE_DIR}/src/app_tracker.c
${CMAKE_SOURCE_DIR}/src/flat_navi.c
${CMAKE_SOURCE_DIR}/src/main.c
-DTZ_SYS_RO_PACKAGES=%{TZ_SYS_RO_PACKAGES} \
-DSEC_FEATURE_TAPI_ENABLE=${SEC_FEATURE_TAPI_ENABLE}
-make %{?jobs:-j%jobs} \
+VERBOSE=1 make %{?jobs:-j%jobs} \
2>&1 | sed \
-e 's%^.*: error: .*$%\x1b[37;41m&\x1b[m%' \
-e 's%^.*: warning: .*$%\x1b[30;43m&\x1b[m%'
#include <symbols.h>
#include <utils.h>
+#ifndef TIZEN_GTEST
+#define TIZEN_PROD_STATIC static
+#else
+#define TIZEN_PROD_STATIC
+#endif
+
#define HAPTIC_VIBRATE_DURATION 30
#define HAPTIC_VIBRATE_INTENSITY 50
#define DEBUG_MODE
-static void _highlight_on_slider(Eina_Bool is_slider);
+TIZEN_PROD_STATIC void _highlight_on_slider(Eina_Bool is_slider);
typedef struct {
int x;
}
-static void _wm_text_selection_mode_set(NavigatorData *nd, Eina_Bool is_selection_mode)
+TIZEN_PROD_STATIC void _wm_text_selection_mode_set(NavigatorData *nd, Eina_Bool is_selection_mode)
{
Eldbus_Connection *conn;
Eldbus_Object *dobj;
}
-static void _highlight_on_slider(Eina_Bool is_slider)
+TIZEN_PROD_STATIC void _highlight_on_slider(Eina_Bool is_slider)
{
Eldbus_Connection *conn;
Eldbus_Object *dobj;
}
-static void _send_highlighted_object_info(NavigatorData *nd, AtspiAccessible *obj, Gesture_Info *info)
+TIZEN_PROD_STATIC void _send_highlighted_object_info(NavigatorData *nd, AtspiAccessible *obj, Gesture_Info *info)
{
Eina_Bool keyboard_status;
Eldbus_Connection *conn;
}
-static bool _widget_has_state(AtspiAccessible *obj, AtspiStateType type)
+TIZEN_PROD_STATIC bool _widget_has_state(AtspiAccessible *obj, AtspiStateType type)
{
Eina_Bool ret = EINA_FALSE;
AtspiStateSet *st = atspi_accessible_get_state_set(obj);
g_free(tmp2);
}
-static Eina_Bool _do_action(AtspiAccessible *obj, char *expected_action)
+TIZEN_PROD_STATIC Eina_Bool _do_action(AtspiAccessible *obj, char *expected_action)
{
AtspiAction *action;
GError *err = NULL;
/* This function will set highlight information such as how an object gets highlight,
HIGHLIGHT_FIRST means the highlight moves from previous highlighted object,
adn HIGHLIGHT_LAST means the highlight moves from next highlighted object. */
-static void _highlight_type_set(AtspiAccessible *obj, Highlight_Type h_type)
+TIZEN_PROD_STATIC void _highlight_type_set(AtspiAccessible *obj, Highlight_Type h_type)
{
char *expected_action = NULL;
_do_action(obj, expected_action);
}
-static Eina_Bool _highlight_access_object(AtspiAccessible *obj, Highlight_Type h_type)
+TIZEN_PROD_STATIC Eina_Bool _highlight_access_object(AtspiAccessible *obj, Highlight_Type h_type)
{
char *expected_action = NULL;
return _do_action(obj, expected_action);
}
-static void _current_highlight_object_set(NavigatorData *nd, AtspiAccessible * obj, Highlight_Type h_type)
+TIZEN_PROD_STATIC void _current_highlight_object_set(NavigatorData *nd, AtspiAccessible * obj, Highlight_Type h_type)
{
DEBUG("START");
GError *err = NULL;
}
/* change context root if bus name of window at point is different from bus name of context root */
-static void _window_at_point_check(NavigatorData *nd, int x, int y)
+TIZEN_PROD_STATIC void _window_at_point_check(NavigatorData *nd, int x, int y)
{
AtspiAccessible *touched_window = NULL;
AtspiAccessible *context_root = NULL;
g_free(context_root_bus_name);
}
-static void _focus_widget(NavigatorData *nd, Gesture_Info *info)
+TIZEN_PROD_STATIC void _focus_widget(NavigatorData *nd, Gesture_Info *info)
{
DEBUG("START");
DEBUG("END");
}
-static Eina_Bool _focus_next_prev_is_movable(AtspiAccessible *obj)
+TIZEN_PROD_STATIC Eina_Bool _focus_next_prev_is_movable(AtspiAccessible *obj)
{
AtspiRole role = atspi_accessible_get_role(obj, NULL);
if (role == ATSPI_ROLE_POPUP_MENU || role == ATSPI_ROLE_DIALOG)
return ret;
}
-static void _focus_next(NavigatorData *nd)
+TIZEN_PROD_STATIC void _focus_next(NavigatorData *nd)
{
DEBUG("START");
}
}
-static void _focus_prev(NavigatorData *nd)
+TIZEN_PROD_STATIC void _focus_prev(NavigatorData *nd)
{
DEBUG("START");
AppTrackerContextValidility val = app_tracker_context_valid_check(nd->app_tracker_data);
DEBUG("END");
}
-static AtspiAccessible *_get_currently_controlled_accessible(AtspiAccessible *obj)
+TIZEN_PROD_STATIC AtspiAccessible *_get_currently_controlled_accessible(AtspiAccessible *obj)
{
AtspiAccessible *currently_controlled;
AtspiAccessible *relation = flat_navi_get_object_in_relation(obj, ATSPI_RELATION_CONTROLLER_FOR);
return currently_controlled;
}
-static void _caret_move_beg(NavigatorData *nd)
+TIZEN_PROD_STATIC void _caret_move_beg(NavigatorData *nd)
{
AtspiAccessible *current_widget = NULL;
AtspiText *text_interface;
ERROR("No text interface supported!");
}
-static void _caret_move_end(NavigatorData *nd)
+TIZEN_PROD_STATIC void _caret_move_end(NavigatorData *nd)
{
AtspiAccessible *current_widget = NULL;
AtspiText *text_interface;
}
}
-static void _cut_or_copy_selected_text(NavigatorData *nd, Eina_Bool is_cut)
+TIZEN_PROD_STATIC void _cut_or_copy_selected_text(NavigatorData *nd, Eina_Bool is_cut)
{
AtspiAccessible *current_widget = NULL;
AtspiRange *text_selection_range = NULL;
return;
}
-static void _paste_text(NavigatorData *nd)
+TIZEN_PROD_STATIC void _paste_text(NavigatorData *nd)
{
AtspiAccessible *current_widget = NULL;
AtspiRange *text_selection_range = NULL;
return;
}
-static void _select_all_text(NavigatorData *nd)
+TIZEN_PROD_STATIC void _select_all_text(NavigatorData *nd)
{
AtspiAccessible *current_widget = NULL;
AtspiText *text_interface;
return;
}
-static void _select_text_forward(NavigatorData *nd, Eina_Bool forward)
+TIZEN_PROD_STATIC void _select_text_forward(NavigatorData *nd, Eina_Bool forward)
{
AtspiAccessible *current_widget = NULL;
AtspiRange *text_selection_range = NULL;
return;
}
-static void _caret_move_forward(NavigatorData *nd)
+TIZEN_PROD_STATIC void _caret_move_forward(NavigatorData *nd)
{
AtspiAccessible *current_widget = NULL;
AtspiText *text_interface;
}
-static void _caret_move_backward(NavigatorData *nd)
+TIZEN_PROD_STATIC void _caret_move_backward(NavigatorData *nd)
{
AtspiAccessible *current_widget = NULL;
AtspiText *text_interface;
return;
}
-static void _value_inc(NavigatorData *nd, int diff)
+TIZEN_PROD_STATIC void _value_inc(NavigatorData *nd, int diff)
{
AtspiAccessible *current_widget = NULL;
GError *err = NULL;
ERROR("No value interface supported!\n");
}
-static void _value_dec(NavigatorData *nd, int diff)
+TIZEN_PROD_STATIC void _value_dec(NavigatorData *nd, int diff)
{
AtspiAccessible *current_widget = NULL;
GError *err = NULL;
ERROR("No value interface supported!\n");
}
-static void _activate_widget(NavigatorData *nd)
+TIZEN_PROD_STATIC void _activate_widget(NavigatorData *nd)
{
//activate the widget
//only if activate mean click
* @brief Gets 'deepest' Scrollable accessible containing (x,y) point
*/
/*
-static AtspiScrollable*
+TIZEN_PROD_STATIC AtspiScrollable*
_find_scrollable_ancestor_at_xy(int x, int y)
{
AtspiAccessible *ret = NULL;
return NULL;
}
-static void _widget_scroll_begin(Gesture_Info *gi)
+TIZEN_PROD_STATIC void _widget_scroll_begin(Gesture_Info *gi)
{
GError *err = NULL;
}
}
-static void _widget_scroll_continue(Gesture_Info *gi)
+TIZEN_PROD_STATIC void _widget_scroll_continue(Gesture_Info *gi)
{
GError *err = NULL;
if (!scrolled_obj) {
GERROR_CHECK(err)
}
-static void _widget_scroll_end(Gesture_Info *gi)
+TIZEN_PROD_STATIC void _widget_scroll_end(Gesture_Info *gi)
{
GError *err = NULL;
if (!scrolled_obj) {
*/
/*
-static void _widget_scroll(NavigatorData *nd, Gesture_Info *gi)
+TIZEN_PROD_STATIC void _widget_scroll(NavigatorData *nd, Gesture_Info *gi)
{
DEBUG("Recognized gesture state: %d", gi->state);
int x_diff, y_diff;
*/
#ifndef SCREEN_READER_TV
-static void _read_quickpanel(NavigatorData *nd) {
+TIZEN_PROD_STATIC void _read_quickpanel(NavigatorData *nd) {
DEBUG("START");
if (nd->read_quickpanel_cb)
}
#endif
-static void _set_pause(void)
+TIZEN_PROD_STATIC void _set_pause(void)
{
DEBUG("START");
DEBUG("END");
}
-static void auto_review_highlight_set(NavigatorData *nd)
+TIZEN_PROD_STATIC void auto_review_highlight_set(NavigatorData *nd)
{
AtspiAccessible *obj = flat_navi_context_next(nd->flat_navi_context);
DEBUG("END");
}
-static void auto_review_highlight_top(NavigatorData *nd)
+TIZEN_PROD_STATIC void auto_review_highlight_top(NavigatorData *nd)
{
DEBUG("START");
AtspiAccessible *obj = flat_navi_context_current_get(nd->flat_navi_context);
DEBUG("END");
}
-static void _on_auto_review_stop(NavigatorData *nd)
+TIZEN_PROD_STATIC void _on_auto_review_stop(NavigatorData *nd)
{
DEBUG("START");
nd->auto_review_on = false;
DEBUG("END");
}
-static void _on_utterance(void *user_data)
+TIZEN_PROD_STATIC void _on_utterance(void *user_data)
{
DEBUG("START");
DEBUG("END");
}
-static void _review_from_current(NavigatorData *nd)
+TIZEN_PROD_STATIC void _review_from_current(NavigatorData *nd)
{
DEBUG("START");
DEBUG("END");
}
-static void _review_from_top(NavigatorData *nd)
+TIZEN_PROD_STATIC void _review_from_top(NavigatorData *nd)
{
DEBUG("START");
DEBUG("END");
}
-static void _direct_scroll_back(NavigatorData *nd)
+TIZEN_PROD_STATIC void _direct_scroll_back(NavigatorData *nd)
{
DEBUG("ONE_FINGER_FLICK_LEFT_RETURN");
if (!nd || !nd->flat_navi_context) {
g_object_unref(current);
}
-static void _direct_scroll_forward(NavigatorData *nd)
+TIZEN_PROD_STATIC void _direct_scroll_forward(NavigatorData *nd)
{
DEBUG("ONE_FINGER_FLICK_RIGHT_RETURN");
g_object_unref(current);
}
-static void _direct_scroll_to_first(NavigatorData *nd)
+TIZEN_PROD_STATIC void _direct_scroll_to_first(NavigatorData *nd)
{
DEBUG("ONE_FINGER_FLICK_UP_RETURN");
if (!nd || !nd->flat_navi_context) {
DEBUG("END");
}
-static void _direct_scroll_to_last(NavigatorData *nd)
+TIZEN_PROD_STATIC void _direct_scroll_to_last(NavigatorData *nd)
{
DEBUG("ONE_FINGER_FLICK_DOWN_RETURN");
if (!nd || !nd->flat_navi_context) {
DEBUG("END");
}
-static Eina_Bool _has_value(NavigatorData *nd)
+TIZEN_PROD_STATIC Eina_Bool _has_value(NavigatorData *nd)
{
DEBUG("START");
AtspiAccessible *obj = NULL;
return EINA_FALSE;
}
-static Eina_Bool _is_enabled(NavigatorData *nd)
+TIZEN_PROD_STATIC Eina_Bool _is_enabled(NavigatorData *nd)
{
if (nd->current_obj == NULL)
return EINA_FALSE;
return ret;
}
-static Eina_Bool _is_active_entry(NavigatorData *nd)
+TIZEN_PROD_STATIC Eina_Bool _is_active_entry(NavigatorData *nd)
{
DEBUG("START");
return EINA_FALSE;
}
-static Eina_Bool _is_slider(AtspiAccessible *obj)
+TIZEN_PROD_STATIC Eina_Bool _is_slider(AtspiAccessible *obj)
{
DEBUG("START");
return EINA_FALSE;
}
-static Eina_Bool _is_index_item(NavigatorData *nd)
+TIZEN_PROD_STATIC Eina_Bool _is_index_item(NavigatorData *nd)
{
DEBUG("START");
return EINA_FALSE;
}
-static void _move_slider(NavigatorData *nd, Gesture_Info *gi)
+TIZEN_PROD_STATIC void _move_slider(NavigatorData *nd, Gesture_Info *gi)
{
DEBUG("ONE FINGER DOUBLE TAP AND HOLD");
DEBUG("END");
}
-static Eina_Bool _granularity_text_read(NavigatorData *nd, Eina_Bool next)
+TIZEN_PROD_STATIC Eina_Bool _granularity_text_read(NavigatorData *nd, Eina_Bool next)
{
Granularity_Read_Data *grd = granularity_read_data_get();
if (grd) {
return action;
}
-static void _start_stop_signal_send(NavigatorData *nd)
+TIZEN_PROD_STATIC void _start_stop_signal_send(NavigatorData *nd)
{
AtspiAction *action = _get_main_window(nd);
if (action) {
}
}
-static Eina_Bool _check_access_object_internal(NavigatorData *nd, Highlight_Type h_type)
+TIZEN_PROD_STATIC Eina_Bool _check_access_object_internal(NavigatorData *nd, Highlight_Type h_type)
{
AtspiRole role;
AtspiAccessible *obj;
return EINA_FALSE;
}
-static Eina_Bool _gesture_is_consumed(NavigatorData *nd, Gesture_Info *info)
+TIZEN_PROD_STATIC Eina_Bool _gesture_is_consumed(NavigatorData *nd, Gesture_Info *info)
{
Eina_Bool ret = EINA_FALSE;
AtspiAccessible *obj = NULL;
}
/* Call this function if you know the Keypad window is on top */
-static Eina_Bool _current_highlight_on_keyboard_is(NavigatorData *nd)
+TIZEN_PROD_STATIC Eina_Bool _current_highlight_on_keyboard_is(NavigatorData *nd)
{
Eina_Bool ret = EINA_FALSE;
AtspiAccessible *top_window;
return ret;
}
-static void on_gesture_detected(void *data, const Eldbus_Message *msg)
+TIZEN_PROD_STATIC void on_gesture_detected(void *data, const Eldbus_Message *msg)
{
NavigatorData *nd = (NavigatorData *)data;
g_free(info);
}
-static void _send_app_gesture_support( const char* app_gesture_support )
+TIZEN_PROD_STATIC void _send_app_gesture_support( const char* app_gesture_support )
{
Eldbus_Connection *conn = NULL;
Eldbus_Object *dobj = NULL;
}
-static void _check_app_gesture_support(NavigatorData *nd, AtspiAccessible *obj)
+TIZEN_PROD_STATIC void _check_app_gesture_support(NavigatorData *nd, AtspiAccessible *obj)
{
GHashTable *hash_table = atspi_accessible_get_attributes(obj, NULL);
if (hash_table) {
}
}
-static void _view_content_changed(AtspiAccessible *root, AtspiRole role, void *data, Eina_Bool default_label_enabled)
+TIZEN_PROD_STATIC void _view_content_changed(AtspiAccessible *root, AtspiRole role, void *data, Eina_Bool default_label_enabled)
{
DEBUG("START");
NavigatorData *nd = (NavigatorData*)data;
DEBUG("END");
}
-static void _new_highlighted_obj_changed(AtspiAccessible *new_highlighted_obj, AtspiRole role, void *user_data)
+TIZEN_PROD_STATIC void _new_highlighted_obj_changed(AtspiAccessible *new_highlighted_obj, AtspiRole role, void *user_data)
{
gchar *prev_id, *next_id;
NavigatorData *nd = user_data;
DEBUG("END");
}
-static
+TIZEN_PROD_STATIC
void navigator_gestures_tracker_register(NavigatorData *nd, GestureCB gesture_cb)
{
Eldbus_Object *obj;
return;
}
-static
+TIZEN_PROD_STATIC
void navigator_gestures_tracker_unregister(NavigatorData *nd)
{
if (nd->connection)
eldbus_shutdown();
}
-static WindowInfo* app_tracker_top_window_info_get_opaque(void *user_data)
+TIZEN_PROD_STATIC WindowInfo* app_tracker_top_window_info_get_opaque(void *user_data)
{
return app_tracker_top_window_info_get((App_Tracker_Data *)user_data);
}
--- /dev/null
+cmake_minimum_required(VERSION 2.8)
+
+SET(CMAKE_EXPORT_COMPILE_COMMANDS "OFF")
+
+INCLUDE_DIRECTORIES(.)
+
+SET(CMOCKTEST_PATH "${CMAKE_SOURCE_DIR}/cmocktest")
+SET(GOOGLETEST_PATH "${CMAKE_SOURCE_DIR}/googletest")
+SET(TEST_INCLUDES_FLAGS "-I${CMAKE_SOURCE_DIR}/googletest/googletest/include -I${CMAKE_SOURCE_DIR}/googletest/googlemock/include -I${CMAKE_SOURCE_DIR}/cmocktest/include")
+
+SET(CMAKE_TEST_DEFINES "-DTIZEN_GTEST")
+
+# TODO: get googletest / c-mocktest out of repository into its own
+# keep in mind, than googletest needs patch to add -fPIC argument to compile command
+EXEC_PROGRAM("/bin/sh -c \"cd '${GOOGLETEST_PATH}' && cmake -Dgtest_disable_pthreads=ON -DGTEST_HAS_PTHREAD=0 -DBUILD_SHARED_LIBS=OFF -Dgtest_hide_internal_symbols=ON . && make GTEST_HAS_PTHREAD=0\"" OUTPUT_VARIABLE RES)
+
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${TEST_INCLUDES_FLAGS} ${CMAKE_TEST_DEFINES} -DGTEST_HAS_PTHREAD=0")
+SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${TEST_INCLUDES_FLAGS} ${CMAKE_TEST_DEFINES} -DGTEST_HAS_PTHREAD=0")
+SET(CMAKE_C_FLAGS "${SLP_DEBUG_FLAGS} ${SLP_OPT_FLAGS} ${CMAKE_C_FLAGS} ${EXTRA_CFLAGS} ${SLP_COMPILER_FLAGS} -fPIC -I../include")
+SET(CMAKE_CXX_FLAGS "${SLP_DEBUG_FLAGS} ${SLP_OPT_FLAGS} ${CMAKE_CXX_FLAGS} ${EXTRA_CFLAGS} ${SLP_COMPILER_FLAGS} -std=c++11 -fPIC -I../include")
+
+FILE(GLOB WRAPPERS_C_SRC "${CMAKE_SOURCE_DIR}/tests2/wrappers/*.cpp")
+
+ADD_LIBRARY(external_mocks OBJECT "${CMAKE_SOURCE_DIR}/tests2/wrappers/mocked_external.cpp")
+
+# Radoslaw Cybulski:
+# this will create test executable from given TEST_SRC_FILE, linking (only!) against C_SRC_FILE from original source and all neccesary external libraries
+# no other source files will be pulled in
+# all neccesary intermediate libraries will be constructed on demand and only once. you can safely create more, than one test for the same C_SRC_FILE
+# NOTE: all C_SRC_FILE and TEST_SRC_FILE must be simple files (no directories allowed currently).
+FUNCTION(CREATE_TEST_FROM_SOURCE C_SRC_FILE TEST_SRC_FILE)
+ GET_FILENAME_COMPONENT(NAME ${C_SRC_FILE} NAME_WE)
+ GET_FILENAME_COMPONENT(TESTNAME ${TEST_SRC_FILE} NAME_WE)
+
+ IF(NOT TARGET "${NAME}_base")
+ ADD_LIBRARY(${NAME}_base SHARED ${CMAKE_SOURCE_DIR}/src/${C_SRC_FILE})
+ TARGET_LINK_LIBRARIES(${NAME}_base "-Wl,--no-as-needed" ${pkgs_LDFLAGS})
+ ENDIF(NOT TARGET "${NAME}_base")
+
+ IF(NOT TARGET "${NAME}_base_with_wrappers")
+ ADD_LIBRARY(${NAME}_base_with_wrappers SHARED $<TARGET_OBJECTS:external_mocks> "${CMAKE_SOURCE_DIR}/tests2/wrappers/mocked_${C_SRC_FILE}pp")
+ TARGET_LINK_LIBRARIES(${NAME}_base_with_wrappers "-Wl,--no-as-needed -Wl,--start-group -L${CMAKE_SOURCE_DIR}/googletest/googlemock/gtest -L${CMAKE_SOURCE_DIR}/googletest/googlemock -L${LOC_DIR} -Wl,-rpath,${CMAKE_SOURCE_DIR}/tests2 -Wl,-rpath,${CMAKE_SOURCE_DIR}/googletest/googlemock -Wl,-rpath,${CMAKE_SOURCE_DIR}/googletest/googlemock/gtest" ${NAME}_base gmock gtest dl)
+ ENDIF(NOT TARGET "${NAME}_base_with_wrappers")
+
+ ADD_EXECUTABLE(test_${TESTNAME} ${CMAKE_SOURCE_DIR}/tests2/${TEST_SRC_FILE})
+ TARGET_LINK_LIBRARIES(test_${TESTNAME} "-Wl,--no-as-needed -L${CMAKE_SOURCE_DIR}/googletest/googlemock/gtest -L${CMAKE_SOURCE_DIR}/googletest/googlemock -L${LOC_DIR} -Wl,-rpath,${CMAKE_SOURCE_DIR}/tests2 -Wl,-rpath,${CMAKE_SOURCE_DIR}/googletest/googlemock -Wl,-rpath,${CMAKE_SOURCE_DIR}/googletest/googlemock/gtest" gtest_main ${NAME}_base_with_wrappers)
+ ADD_TEST(test_${TESTNAME} ${CMAKE_SOURCE_DIR}/tests2/test_${TESTNAME})
+ENDFUNCTION(CREATE_TEST_FROM_SOURCE)
+
+
+#CREATE_TEST_FROM_SOURCE("screen_reader_vconf.c" "screen_reader_vconf.cpp")
+#CREATE_TEST_FROM_SOURCE("utils.c" "utils.cpp")
+CREATE_TEST_FROM_SOURCE("navigator.c" "navigator.cpp")
+#CREATE_TEST_FROM_SOURCE("utils.c" "utils_display_info.cpp")
+#CREATE_TEST_FROM_SOURCE("utils.c" "utils_description_trait.cpp")
+#CREATE_TEST_FROM_SOURCE("utils.c" "utils_state_trait.cpp")
+#CREATE_TEST_FROM_SOURCE("utils.c" "utils_role_trait.cpp")
+#CREATE_TEST_FROM_SOURCE("utils.c" "utils_text_for_relation_objects.cpp")
--- /dev/null
+#include "navigator.hpp"
+
+TEST_F(ScreenReaderUtilsFixture, WidgetHasNameNullArgs) {
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_state_set, (nullptr)).WillOnce(Return(nullptr));
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (nullptr, ATSPI_STATE_INVALID)).WillOnce(Return(FALSE));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (nullptr));
+
+ EXPECT_EQ(_widget_has_state(nullptr, ATSPI_STATE_INVALID), false);
+}
+
+TEST_F(ScreenReaderUtilsFixture, WidgetHasStateHasNot) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+ AtspiStateType state_ = ATSPI_STATE_INVALID;
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_state_set, (obj_)).WillOnce(Return(stateSet_));
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, state_)).WillOnce(Return(FALSE));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_)).Times(1);
+
+ EXPECT_EQ(_widget_has_state(obj_, state_), false);
+}
+
+TEST_F(ScreenReaderUtilsFixture, WidgetHasStateHas) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+ AtspiStateType state_ = ATSPI_STATE_INVALID;
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_state_set, (obj_)).WillOnce(Return(stateSet_));
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, state_)).WillOnce(Return(TRUE));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_)).Times(1);
+
+ EXPECT_EQ(_widget_has_state(obj_, state_), true);
+}
+
+//TEST_F(ScreenReaderUtilsFixture, WidgetHasActionNullObject) {
+// EXPECT_FUNCTION_CALL(m_atspi_accessible_get_action_iface, (nullptr)).Times(1);
+//
+// EXPECT_EQ(widget_has_action(nullptr, "noaction"), EINA_FALSE);
+//}
--- /dev/null
+#ifndef SCREEN_READER_UTILS_HPP_
+#define SCREEN_READER_UTILS_HPP_
+
+#define DEFINE_MOCKING(mock_name) StrictMock<mock_ ## mock_name> m_ ## mock_name
+
+#include <memory>
+
+#include "wrappers/mocked_navigator.h"
+#include "wrappers/mocked_external.h"
+
+using ::testing::StrictMock;
+
+using ::testing::DoAll;
+using ::testing::Invoke;
+using ::testing::Return;
+using ::testing::SetArgPointee;
+using ::testing::StrEq;
+using ::testing::_;
+
+class ScreenReaderUtilsFixture : public ::testing::Test {
+protected:
+ std::unique_ptr<AtspiAccessible> obj_;
+ AtspiStateSet *stateSet_;
+
+ DEFINE_MOCKING(atspi_accessible_get_state_set);
+ DEFINE_MOCKING(atspi_state_set_contains);
+ DEFINE_MOCKING(g_object_unref);
+
+ DEFINE_MOCKING(atspi_accessible_get_role);
+ DEFINE_MOCKING(atspi_accessible_get_action_iface);
+ DEFINE_MOCKING(atspi_action_get_n_actions);
+ DEFINE_MOCKING(atspi_action_get_action_name);
+ DEFINE_MOCKING(atspi_accessible_get_role_name);
+
+ void NewAtspiAccessibleObject() {
+ obj_.reset(new AtspiAccessible);
+ }
+
+ AtspiStateSet *NewStateSet() {
+ stateSet_ = (AtspiStateSet *)0xdeadbeef;
+ return stateSet_;
+ }
+
+public:
+ void SetUp() {
+ NewAtspiAccessibleObject();
+ NewStateSet();
+ }
+
+ AtspiAccessible *GetAtspiAccessibleObject() {
+ return obj_.get();
+ }
+
+ AtspiStateSet *GetStateSet() {
+ return stateSet_;
+ }
+};
+
+#endif
--- /dev/null
+This directory (CMakeLists.txt and wrappers/generate_wrappers.py) implements testing infrastructure for C-language projects based on tizen.
+
+For now test files must exist in tests2 directory (starting from project's root directory).
+Test source files must be explicitly named in CMakeLists.txt - those will be build and run, when project is being built. Every test source file is "bound" to single source file from project - test source will have access to all project's mocked functions, that are visible from this given source file (and its included headers). Mocks of external functions are always visible.
+
+1. I want to add new test.
+Lets say screen_reader_vconf.c file is what you want to test. Create new test file (lets say tests2/test.cpp), add test code within. You dont need to add main function, but you might. Append following line to CMakeLists.txt:
+
+CREATE_TEST_FROM_SOURCE("screen_reader_vconf.c" "test.cpp")
+
+On beginning of test.cpp include two headers:
+
+#include "wrappers/mocked_screen_reader_vconf.h"
+#include "wrappers/mocked_external.h"
+
+Next time project will be built - the new test will be built and run with it as well.
+
+2. I've added / removed some functions (structures) to project's and i want to test them as well.
+
+Install prerequisites (clang-3.8, pip and clang's python bindings):
+
+sudo apt-get install clang-3.8
+sudo apt-get install python-pip
+sudo pip install clang
+
+Generate compile_commands.json for your project (but not your tests!). The easiest is to use CMake - add
+
+SET(CMAKE_EXPORT_COMPILE_COMMANDS "ON")
+
+to beginning of your CMakeLists.txt and add
+
+SET(CMAKE_EXPORT_COMPILE_COMMANDS "OFF")
+
+to beginning of CMakeListst.txt in any subdirectory, which is not part of project's binary (testing and so on). Build the project, it will create compile_commands.json in project's build directory (for example ~/GBS-ROOT/local/BUILD-ROOTS/scratch.armv7l.0/home/abuild/rpmbuild/BUILD/org.tizen.screen-reader-0.0.8/compile_commands.json). Copy it back to project's source directory - it will be needed in a second.
+Durgin building and all following process flag DEBUG_PRINTING_LEVEL=4 has to be set (look at CMakeList.txt or include/logger.h), it enables all log macros and make generation of mock for all neccessary functions possible.
+Run:
+
+tests2/wrappers/generate_wrappers.py parse --command compile_commands.json --output out --define TIZEN_GTEST
+
+This will parse compile_commands.json for source files and parse those (using clang) to create rtti information tables for source files. You need --define TIZEN_GTEST option to tell clang to define this symbol, so some static function in source code would stop being static (otherwise you wont be able to mock them). generate_wrappers.py also requires information about arm build root path - it defaults to ~/GBS-ROOT/local/BUILD-ROOTS/scratch.armv7l.0 . If your arm root is different, you need to use --arm-root argument (the path is needed, because chroot is executed as part of build process and compile_commands.json is generated from inside that chroot. Once build process exists chroot, paths in compile_commands.json arent valid anymore).
+Next execute:
+
+tests2/wrappers/generate_wrappers.py generate --input out --output tests2/wrappers/
+
+It will create several .h and .cpp files in tests2/wrappers directory. Remember to add / remove them to repository as well.
+
+
+
+CURRENT (2016 X 20) LIMITATIONS:
+All project's source files must exist in single directory ./src .
+All project's test files must exists in single directory ./tests2 .
+You need to change static keyword before function to some macro, and define that macro to be empty if macro TIZEN_GTEST exists, otherwise expands to static.
+Straight static functions cannot be mocked. So cant be inlined functions defined in headers.
+Files ending in .c are consideded "sources". Structures / functions declared in any file, which is not "source" (ends in anything else, than .c) are considered public. All non public structures will be copied, when function using them is mocked. Sometimes the copy is canonical (typedefs are removed), but should be otherwise identical to original. If not - please contact me at r.cybulski@partner.samsung.com .
+You will get mocks of all functions visible from given source file per every source file. Thus lot of mocks will be replicated among wrappers source files, which will increase compilation time.
+
+
+TODO:
+- remove single directory limitations for both source files and test files.
+- split mock declarations / definitions to follow original include structures (so every include file would get its own include file with mocks) - since it will change far more frequiently, it requires auto update of mocks every time build is triggered, which in turn requires rewriting part of generate_wrappers.py to be c++ python module for performance reasons.
+- improve structure copying / dealing with typedefs.
+- add ability to test more, than one source file in given test (intergration tests).
--- /dev/null
+#include "wrappers/mocked_screen_reader_vconf.h"
+#include "wrappers/mocked_external.h"
+
+#define DEFINE_MOCKING(mock_name) StrictMock<mock_ ## mock_name> m_ ## mock_name
+
+// Enforce failure on non-expected calls
+using ::testing::StrictMock;
+
+using ::testing::DoAll;
+using ::testing::Invoke;
+using ::testing::Return;
+using ::testing::SetArgPointee;
+using ::testing::StrEq;
+using ::testing::_;
+using ::testing::AnyNumber;
+
+class ScreenReaderVconfFixture : public ::testing::Test {
+ protected:
+ static const char *vconfLangKey;
+ static const char *vconfReadDescKey;
+ static const char *vconfHapticKey;
+ static const char *vconfKbFeedbackKey;
+ static const char *vconfSoundFeedbackKey;
+ static const int STATUS_OK;
+ static const int STATUS_ERROR;
+ static keynode_t *keynode;
+
+ Screen_Reader_Vconf_Data_t *vconfData_;
+ bool vconfDataOwned_;
+
+ DEFINE_MOCKING(get_pointer_to_service_data_struct);
+ DEFINE_MOCKING(screen_reader_vconf_data_create);
+ DEFINE_MOCKING(screen_reader_vconf_data_destroy);
+ DEFINE_MOCKING(setenv);
+ DEFINE_MOCKING(vconf_set);
+ DEFINE_MOCKING(vconf_keylist_free);
+ DEFINE_MOCKING(vconf_get_bool);
+ DEFINE_MOCKING(vconf_get_str);
+ DEFINE_MOCKING(vconf_notify_key_changed);
+ DEFINE_MOCKING(vconf_ignore_key_changed);
+ DEFINE_MOCKING(vconf_keynode_get_bool);
+
+ Screen_Reader_Vconf_Data_t *newVconfData() {
+ if (vconfDataOwned_) delete vconfData_;
+ vconfData_ = new Screen_Reader_Vconf_Data_t;
+ memset(vconfData_, 0, sizeof(*vconfData_));
+ vconfDataOwned_ = true;
+ return vconfData_;
+ }
+ template <typename T> void setVconfData(T vcdata) {
+ vconfData_ = (Screen_Reader_Vconf_Data_t *)vcdata;
+ vconfDataOwned_ = false;
+ }
+
+ public:
+ typedef void (*vconf_callback_f)(keynode_t *, void *);
+
+ void SetUp() {
+ vconfData_ = 0;
+ vconfDataOwned_ = false;
+ newVconfData();
+ }
+ void TearDown() {
+ if (vconfDataOwned_) delete vconfData_;
+ }
+
+ void expectReadValueAndInstallChangeCallback(bool vconf_value, const char *vconfKey, int get_return,
+ vconf_callback_f cb, void *callback_data, int register_return) {
+ EXPECT_FUNCTION_CALL(m_vconf_get_bool, (StrEq(vconfKey), _))
+ .WillOnce(DoAll(SetArgPointee<1>(vconf_value), Return(get_return)));
+ // TODO: use callback data
+ if (get_return == STATUS_OK) {
+ EXPECT_FUNCTION_CALL(m_vconf_notify_key_changed, (StrEq(vconfKey), cb, callback_data)).
+ WillOnce(Return(register_return));
+ }
+ }
+ void expectBenignVconfKeynodeCall() {
+ // Apparently the vconf_keynode_get_* get non-const pointer to a keynode.
+ EXPECT_FUNCTION_CALL(m_vconf_keynode_get_bool, (keynode)).Times(AnyNumber());
+ }
+ void prepVconfGetBoolRegisterCb(const char *key, bool retVal, bool value) {
+ EXPECT_FUNCTION_CALL(m_vconf_get_bool, (StrEq(key), _))
+ .WillOnce(DoAll(SetArgPointee<1>(value), Return(retVal)))
+ .RetiresOnSaturation();
+ expectBenignVconfKeynodeCall();
+ }
+ void checkVconfGetBoolRegisterCb(const char *vconfKey, bool retVal, bool vconfValue, bool *variable, vconf_callback_f cb) {
+ prepVconfGetBoolRegisterCb(vconfKey, retVal, vconfValue);
+ if (variable) *variable = !vconfValue;
+ // Actual call
+ cb(keynode, vconfData());
+ if (variable) {
+ if (retVal == STATUS_OK) {
+ EXPECT_EQ(vconfValue, *variable);
+ } else {
+ EXPECT_NE(vconfValue, *variable);
+ }
+ }
+ }
+
+ Screen_Reader_Vconf_Data_t *vconfData() { return vconfData_; }
+};
+
+const char *ScreenReaderVconfFixture::vconfLangKey = "db/menu_widget/language";
+const char *ScreenReaderVconfFixture::vconfReadDescKey = "db/setting/accessibility/screen_reader/description";
+const char *ScreenReaderVconfFixture::vconfHapticKey = "db/setting/accessibility/screen_reader/haptic";
+const char *ScreenReaderVconfFixture::vconfKbFeedbackKey = "db/setting/accessibility/screen_reader/keyboard_feedback";
+const char *ScreenReaderVconfFixture::vconfSoundFeedbackKey = "db/setting/accessibility/screen_reader/sound_feedback";
+const int ScreenReaderVconfFixture::STATUS_OK = 0;
+const int ScreenReaderVconfFixture::STATUS_ERROR = -1;
+keynode_t *ScreenReaderVconfFixture::keynode = (keynode_t *)0x11;
+
+TEST_F(ScreenReaderVconfFixture, GetKeyValues_nullptrBailsOut) {
+ EXPECT_EQ(1, get_key_values(nullptr));
+}
+
+TEST_F(ScreenReaderVconfFixture, GetKeyValues_OK) {
+ EXPECT_FUNCTION_CALL(m_vconf_get_str, (StrEq(vconfLangKey)))
+ .WillOnce(Return(strdup("string")));
+ EXPECT_FUNCTION_CALL(m_setenv, (StrEq("LC_MESSAGES"), StrEq("strin"), 1))
+ .WillOnce(Return(0));
+ EXPECT_EQ(0, get_key_values(vconfData()));
+}
+
+TEST_F(ScreenReaderVconfFixture, GetKeyValues_VconfFailFails) {
+ EXPECT_FUNCTION_CALL(m_vconf_get_str, (StrEq(vconfLangKey)))
+ .WillOnce(Return(nullptr));
+ EXPECT_EQ(1, get_key_values(vconfData()));
+}
+
+// TODO: factor the testing schema out for the following four tests, maybe
+TEST_F(ScreenReaderVconfFixture, DescriptionChangedCb) {
+ const char *vconfKey = vconfReadDescKey;
+ bool *variable = &vconfData()->read_description;
+ vconf_callback_f cb = reader_description_cb;
+
+ // false-->true change
+ checkVconfGetBoolRegisterCb(vconfKey, STATUS_OK, true, variable, cb);
+ // true-->false
+ checkVconfGetBoolRegisterCb(vconfKey, STATUS_OK, false, variable, cb);
+ // failed get-->no change
+ setVconfData(0x3);
+ checkVconfGetBoolRegisterCb(vconfKey, STATUS_ERROR, true, nullptr, cb);
+ // nullptr vconf data --> no action
+ setVconfData(nullptr);
+ checkVconfGetBoolRegisterCb(vconfKey, STATUS_OK, true, nullptr, cb);
+}
+
+TEST_F(ScreenReaderVconfFixture, HapticCb) {
+ const char *vconfKey = vconfHapticKey;
+ bool *variable = &vconfData()->haptic;
+ vconf_callback_f cb = haptic_changed_cb;
+
+ /// false-->true change
+ checkVconfGetBoolRegisterCb(vconfKey, STATUS_OK, true, variable, cb);
+ // true-->false
+ checkVconfGetBoolRegisterCb(vconfKey, STATUS_OK, false, variable, cb);
+ // failed get-->no change
+ setVconfData(0x3);
+ checkVconfGetBoolRegisterCb(vconfKey, STATUS_ERROR, true, nullptr, cb);
+ // nullptr vconf data --> no action
+ setVconfData(nullptr);
+ checkVconfGetBoolRegisterCb(vconfKey, STATUS_OK, true, nullptr, cb);
+}
+
+TEST_F(ScreenReaderVconfFixture, SoundCb) {
+ const char *vconfKey = vconfSoundFeedbackKey;
+ bool *variable = &vconfData()->sound_feedback;
+ vconf_callback_f cb = sound_feedback_cb;
+
+ /// false-->true change
+ checkVconfGetBoolRegisterCb(vconfKey, STATUS_OK, true, variable, cb);
+ // true-->false
+ checkVconfGetBoolRegisterCb(vconfKey, STATUS_OK, false, variable, cb);
+ // failed get-->no change
+ setVconfData(0x3);
+ checkVconfGetBoolRegisterCb(vconfKey, STATUS_ERROR, true, nullptr, cb);
+ // nullptr vconf data --> no action
+ setVconfData(nullptr);
+ checkVconfGetBoolRegisterCb(vconfKey, STATUS_OK, true, nullptr, cb);
+}
+
+TEST_F(ScreenReaderVconfFixture, KeyboardCb) {
+ const char *vconfKey = vconfKbFeedbackKey;
+ bool *variable = &vconfData()->keyboard_feedback;
+ vconf_callback_f cb = keyboard_feedback_cb;
+
+ /// false-->true change
+ checkVconfGetBoolRegisterCb(vconfKey, STATUS_OK, true, variable, cb);
+ // true-->false
+ checkVconfGetBoolRegisterCb(vconfKey, STATUS_OK, false, variable, cb);
+ // failed get-->no change
+ setVconfData(0x3);
+ checkVconfGetBoolRegisterCb(vconfKey, STATUS_ERROR, true, nullptr, cb);
+ // nullptr vconf data --> no action
+ setVconfData(nullptr);
+ checkVconfGetBoolRegisterCb(vconfKey, STATUS_OK, true, nullptr, cb);
+}
+
+TEST_F(ScreenReaderVconfFixture, SetNPrintfForwards) {
+ const char *key = "a key";
+ vconf_callback_fn cb = (vconf_callback_fn)0x3;
+ void *udata = (void *)0x5;
+ int retval = 0;
+
+ EXPECT_FUNCTION_CALL(m_vconf_notify_key_changed, (key, cb, udata))
+ .WillOnce(Return(retval)).RetiresOnSaturation();
+ EXPECT_EQ(_set_vconf_callback_and_print_message_on_error_and_return_error_code(key, cb, udata), retval);
+
+ retval = -1;
+ EXPECT_FUNCTION_CALL(m_vconf_notify_key_changed, (key, cb, udata))
+ .WillOnce(Return(retval)).RetiresOnSaturation();
+ EXPECT_EQ(_set_vconf_callback_and_print_message_on_error_and_return_error_code(key, cb, udata), retval);
+}
+
+static int setVconfDataLanguageStr(Screen_Reader_Vconf_Data_t *vconfData, const char *langString, int retval) {
+ snprintf(vconfData->display_language, sizeof(vconfData->display_language), "%s", langString);
+ return retval;
+}
+TEST_F(ScreenReaderVconfFixture, AllOK_GoesOn) {
+ DEFINE_MOCKING(get_key_values);
+ StrictMock<mock__set_vconf_callback_and_print_message_on_error_and_return_error_code> m_set_n_printf;
+ StrictMock<mock__set_vconf_key_changed_callback_reader_description> m_get_n_register_desc;
+ StrictMock<mock__set_vconf_key_changed_callback_reader_haptic> m_get_n_register_haptic;
+ StrictMock<mock__set_vconf_key_changed_callback_reader_keyboard_feedback> m_get_n_register_kb;
+ StrictMock<mock__set_vconf_key_changed_callback_reader_sound_feedback> m_get_n_register_snd;
+
+ EXPECT_FUNCTION_CALL(m_screen_reader_vconf_data_create, ()).WillOnce(Return(vconfData()));
+
+ EXPECT_FUNCTION_CALL(m_vconf_set, (nullptr)).WillOnce(Return(0));
+ EXPECT_FUNCTION_CALL(m_vconf_keylist_free, (nullptr)).WillOnce(Return(0));
+
+ // get_key_values
+ EXPECT_FUNCTION_CALL(m_get_key_values, (vconfData()))
+ .WillOnce(Invoke(::std::bind(setVconfDataLanguageStr, ::std::placeholders::_1, "string", 0 /*retval*/)));
+
+ EXPECT_FUNCTION_CALL(m_set_n_printf, (StrEq(vconfLangKey), display_language_cb, vconfData())).WillOnce(Return(0));
+ EXPECT_FUNCTION_CALL(m_get_n_register_desc, (vconfData())).Times(1);
+ EXPECT_FUNCTION_CALL(m_get_n_register_haptic, (vconfData())).Times(1);
+ EXPECT_FUNCTION_CALL(m_get_n_register_kb, (vconfData())).Times(1);
+ EXPECT_FUNCTION_CALL(m_get_n_register_snd, (vconfData())).Times(1);
+
+ Screen_Reader_Vconf_Data_t *vconfDataPtr = vconf_init();
+ EXPECT_NE(vconfDataPtr, nullptr);
+ // TODO: verify *vconfData
+}
+
+#if defined(GTEST_DEATH_TESTS_WORK)
+TEST_F(ScreenReaderVconfFixture, AllocFails_Crashes) {
+ EXPECT_FUNCTION_CALL(m_screen_reader_vconf_data_create, ()).WillOnce(Return(nullptr));
+
+ ASSERT_EXIT(vconf_init(), ::testing::KilledBySignal(SIGSEGV), ".*");
+}
+#endif
+
+TEST_F(ScreenReaderVconfFixture, AllFail_GoesOn) {
+ DEFINE_MOCKING(get_key_values);
+ StrictMock<mock__set_vconf_callback_and_print_message_on_error_and_return_error_code> m_set_n_printf;
+ StrictMock<mock__set_vconf_key_changed_callback_reader_description> m_get_n_register_desc;
+ StrictMock<mock__set_vconf_key_changed_callback_reader_haptic> m_get_n_register_haptic;
+ StrictMock<mock__set_vconf_key_changed_callback_reader_keyboard_feedback> m_get_n_register_kb;
+ StrictMock<mock__set_vconf_key_changed_callback_reader_sound_feedback> m_get_n_register_snd;
+
+ EXPECT_FUNCTION_CALL(m_screen_reader_vconf_data_create, ()).WillOnce(Return(vconfData()));
+
+ EXPECT_FUNCTION_CALL(m_vconf_set, (nullptr)).WillOnce(Return(-1));
+ EXPECT_FUNCTION_CALL(m_vconf_keylist_free, (nullptr)).WillOnce(Return(-1));
+
+ // get_key_values
+ EXPECT_FUNCTION_CALL(m_get_key_values, (vconfData())).WillOnce(Return(-1));
+
+ EXPECT_FUNCTION_CALL(m_set_n_printf, (StrEq(vconfLangKey), display_language_cb, vconfData())).WillOnce(Return(-1));
+ EXPECT_FUNCTION_CALL(m_get_n_register_desc, (vconfData())).Times(1);
+ EXPECT_FUNCTION_CALL(m_get_n_register_haptic, (vconfData())).Times(1);
+ EXPECT_FUNCTION_CALL(m_get_n_register_kb, (vconfData())).Times(1);
+ EXPECT_FUNCTION_CALL(m_get_n_register_snd, (vconfData())).Times(1);
+
+ Screen_Reader_Vconf_Data_t *vconfDataPtr = vconf_init();
+ EXPECT_EQ(vconfDataPtr, vconfData());
+}
+
+TEST_F(ScreenReaderVconfFixture, ExitRemovesCallbacksAndFreesData) {
+ EXPECT_FUNCTION_CALL(m_vconf_ignore_key_changed, (StrEq(vconfLangKey), display_language_cb)).WillOnce(Return(0));
+ EXPECT_FUNCTION_CALL(m_vconf_ignore_key_changed, (StrEq(vconfReadDescKey), reader_description_cb)).WillOnce(Return(0));
+ EXPECT_FUNCTION_CALL(m_vconf_ignore_key_changed, (StrEq(vconfHapticKey), haptic_changed_cb)).WillOnce(Return(0));
+ EXPECT_FUNCTION_CALL(m_vconf_ignore_key_changed, (StrEq(vconfKbFeedbackKey), keyboard_feedback_cb)).WillOnce(Return(0));
+ EXPECT_FUNCTION_CALL(m_vconf_ignore_key_changed, (StrEq(vconfSoundFeedbackKey), sound_feedback_cb)).WillOnce(Return(0));
+ EXPECT_FUNCTION_CALL(m_screen_reader_vconf_data_destroy, (vconfData()));
+
+ vconf_exit(vconfData());
+}
+
+TEST_F(ScreenReaderVconfFixture, ExitDoesNotFreeNullptr) {
+ setVconfData(nullptr);
+ EXPECT_FUNCTION_CALL(m_vconf_ignore_key_changed, (_, _)).WillRepeatedly(Return(-1));
+
+ vconf_exit(vconfData());
+}
+
+
+class ScreenReaderVconfCallbackFixture : public ScreenReaderVconfFixture {
+ public:
+ typedef void (*sr_vconf_read_n_register_fn)(Screen_Reader_Vconf_Data_t *vconf_data);
+
+ void checkVconfUpdateOnNullNoCrash(const char *vconfKey, sr_vconf_read_n_register_fn setup) {
+ // no data, no crash
+ EXPECT_FUNCTION_CALL(m_vconf_get_bool, (StrEq(vconfKey), _))
+ .WillOnce(DoAll(SetArgPointee<1>(0), Return(0)));
+ setup(nullptr);
+ ::testing::Mock::VerifyAndClearExpectations(&m_vconf_get_bool);
+ }
+ void checkVconfValueTransition(const char *vconfKey, bool vconfValue, int getReturn,
+ vconf_callback_f cb, int registerReturn, sr_vconf_read_n_register_fn setup_f,
+ bool *variable, bool expectedValue) {
+ expectReadValueAndInstallChangeCallback(vconfValue, vconfKey, getReturn, cb, vconfData(), registerReturn);
+ setup_f(vconfData());
+ EXPECT_EQ(*variable, expectedValue);
+ }
+ void checkVconfValueHandling(const char *vconfKey, sr_vconf_read_n_register_fn setup_f, vconf_callback_f cb, bool *variable) {
+ checkVconfUpdateOnNullNoCrash(vconfKey, setup_f);
+
+ // false->true scenario
+ checkVconfValueTransition(vconfKey, true /*vconfValue*/, STATUS_OK /*getReturn*/,
+ cb, STATUS_OK /*registerReturn*/, setup_f,
+ variable, true /*expectedValue*/);
+
+ // no change when vconf_get* fails
+ checkVconfValueTransition(vconfKey, false /*vconfValue*/, STATUS_ERROR /*getReturn*/,
+ nullptr /*vconf_callback_f*/, STATUS_OK /*registerReturn*/, setup_f,
+ variable, true /*expectedValue*/);
+
+ // true->false scenario
+ checkVconfValueTransition(vconfKey, false /*vconfValue*/, STATUS_OK /*getReturn*/,
+ cb, STATUS_OK /*registerReturn*/, setup_f,
+ variable, false /*expectedValue*/);
+
+ // no change when vconf_get* fails
+ checkVconfValueTransition(vconfKey, true /*vconfValue*/, STATUS_ERROR /*getReturn*/,
+ nullptr /*vconf_callback_f*/, STATUS_OK /*registerReturn*/, setup_f,
+ variable, false /*expectedValue*/);
+ }
+};
+
+TEST_F(ScreenReaderVconfCallbackFixture, DescriptionReader) {
+ checkVconfValueHandling(vconfReadDescKey,
+ _set_vconf_key_changed_callback_reader_description,
+ reader_description_cb, &vconfData()->read_description);
+}
+
+TEST_F(ScreenReaderVconfCallbackFixture, Haptic) {
+ checkVconfValueHandling(vconfHapticKey,
+ _set_vconf_key_changed_callback_reader_haptic,
+ haptic_changed_cb, &vconfData()->haptic);
+}
+
+TEST_F(ScreenReaderVconfCallbackFixture, KeyboardFeedback) {
+ checkVconfValueHandling(vconfKbFeedbackKey,
+ _set_vconf_key_changed_callback_reader_keyboard_feedback,
+ keyboard_feedback_cb, &vconfData()->keyboard_feedback);
+}
+
+TEST_F(ScreenReaderVconfCallbackFixture, SoundFeedback) {
+ checkVconfValueHandling(vconfSoundFeedbackKey,
+ _set_vconf_key_changed_callback_reader_sound_feedback,
+ sound_feedback_cb, &vconfData()->sound_feedback);
+}
--- /dev/null
+#include "utils.hpp"
+
+TEST_F(ScreenReaderUtilsFixture, WidgetHasNameNullArgs) {
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_state_set, (nullptr)).WillOnce(Return(nullptr));
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (nullptr, ATSPI_STATE_INVALID)).WillOnce(Return(FALSE));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (nullptr));
+
+ EXPECT_EQ(_widget_has_state(nullptr, ATSPI_STATE_INVALID), false);
+}
+
+TEST_F(ScreenReaderUtilsFixture, WidgetHasStateHasNot) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+ AtspiStateType state_ = ATSPI_STATE_INVALID;
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_state_set, (obj_)).WillOnce(Return(stateSet_));
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, state_)).WillOnce(Return(FALSE));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_)).Times(1);
+
+ EXPECT_EQ(_widget_has_state(obj_, state_), false);
+}
+
+TEST_F(ScreenReaderUtilsFixture, WidgetHasStateHas) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+ AtspiStateType state_ = ATSPI_STATE_INVALID;
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_state_set, (obj_)).WillOnce(Return(stateSet_));
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, state_)).WillOnce(Return(TRUE));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_)).Times(1);
+
+ EXPECT_EQ(_widget_has_state(obj_, state_), true);
+}
+
+//TEST_F(ScreenReaderUtilsFixture, WidgetHasActionNullObject) {
+// EXPECT_FUNCTION_CALL(m_atspi_accessible_get_action_iface, (nullptr)).Times(1);
+//
+// EXPECT_EQ(widget_has_action(nullptr, "noaction"), EINA_FALSE);
+//}
--- /dev/null
+#ifndef SCREEN_READER_UTILS_HPP_
+#define SCREEN_READER_UTILS_HPP_
+
+#define DEFINE_MOCKING(mock_name) StrictMock<mock_ ## mock_name> m_ ## mock_name
+
+#include <memory>
+
+#include "wrappers/mocked_utils.h"
+#include "wrappers/mocked_external.h"
+
+using ::testing::StrictMock;
+
+using ::testing::DoAll;
+using ::testing::Invoke;
+using ::testing::Return;
+using ::testing::SetArgPointee;
+using ::testing::StrEq;
+using ::testing::_;
+
+class ScreenReaderUtilsFixture : public ::testing::Test {
+protected:
+ std::unique_ptr<AtspiAccessible> obj_;
+ AtspiStateSet *stateSet_;
+
+ DEFINE_MOCKING(atspi_accessible_get_state_set);
+ DEFINE_MOCKING(atspi_state_set_contains);
+ DEFINE_MOCKING(g_object_unref);
+
+ DEFINE_MOCKING(atspi_accessible_get_role);
+ DEFINE_MOCKING(atspi_accessible_get_action_iface);
+ DEFINE_MOCKING(atspi_action_get_n_actions);
+ DEFINE_MOCKING(atspi_action_get_action_name);
+ DEFINE_MOCKING(atspi_accessible_get_role_name);
+
+ void NewAtspiAccessibleObject() {
+ obj_.reset(new AtspiAccessible);
+ }
+
+ AtspiStateSet *NewStateSet() {
+ stateSet_ = (AtspiStateSet *)0xdeadbeef;
+ return stateSet_;
+ }
+
+public:
+ void SetUp() {
+ NewAtspiAccessibleObject();
+ NewStateSet();
+ }
+
+ AtspiAccessible *GetAtspiAccessibleObject() {
+ return obj_.get();
+ }
+
+ AtspiStateSet *GetStateSet() {
+ return stateSet_;
+ }
+};
+
+#endif
--- /dev/null
+#include "screen_reader_utils.hpp"
+
+class ScreenReaderUtilsDescritpionTraitFixture : public ScreenReaderUtilsFixture {
+public:
+ DEFINE_MOCKING(atspi_accessible_get_parent);
+ DEFINE_MOCKING(atspi_accessible_get_child_count);
+ DEFINE_MOCKING(atspi_accessible_get_index_in_parent);
+ DEFINE_MOCKING(atspi_accessible_get_selection_iface);
+ DEFINE_MOCKING(atspi_selection_is_child_selected);
+ DEFINE_MOCKING(atspi_selection_get_n_selected_children);
+ DEFINE_MOCKING(atspi_accessible_get_selection);
+ DEFINE_MOCKING(atspi_accessible_get_child_at_index);
+ DEFINE_MOCKING(widget_has_action);
+ DEFINE_MOCKING(_find_popup_list_children_count);
+
+ AtspiAccessible *NewParentObject(AtspiRole role = ATSPI_ROLE_INVALID) {
+ parent_ = (AtspiAccessible *)0xdeadbeef;
+ parentRole_ = role;
+ return parent_;
+ }
+
+ AtspiAccessible *GetParentObject() {
+ return parent_;
+ }
+
+ AtspiRole GetParentRole() {
+ return parentRole_;
+ }
+
+ void SetUp() {
+ NewAtspiAccessibleObject();
+ }
+
+protected:
+ void CallGeneralDependencies(AtspiRole role, AtspiStateSet *stateSet_) {
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_role, (GetAtspiAccessibleObject(), nullptr)).WillOnce(Return(role));
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_state_set, (GetAtspiAccessibleObject())).WillOnce(Return(stateSet_));
+ }
+
+ void CallParentWithRoleDependencies() {
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_parent, (obj_.get(), nullptr)).WillOnce(Return(parent_));
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_role, (parent_, nullptr)).WillOnce(Return(parentRole_));
+ }
+
+ void CallMenuRoleDependencies() {
+ CallParentWithRoleDependencies();
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_child_count, (parent_, nullptr)).Times(1);
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_index_in_parent, (GetAtspiAccessibleObject(), nullptr)).Times(1);
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_selection_iface, (parent_)).Times(1);
+ }
+
+ AtspiAccessible *parent_;
+ AtspiRole parentRole_;
+};
+
+class DescriptionTraitWithAccessibleObjectAndStateSet : public ScreenReaderUtilsDescritpionTraitFixture {
+public:
+ void SetUp() {
+ NewAtspiAccessibleObject();
+ NewStateSet();
+ }
+};
+
+TEST_F(ScreenReaderUtilsDescritpionTraitFixture, NullObject) {
+ EXPECT_STREQ(generate_description_trait(nullptr), "");
+}
+
+TEST_F(ScreenReaderUtilsDescritpionTraitFixture, NoRole) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_role, (obj_, nullptr)).Times(1);
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_state_set, (obj_)).Times(1);
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (nullptr));
+
+ EXPECT_STREQ(generate_description_trait(obj_), "");
+}
+
+TEST_F(DescriptionTraitWithAccessibleObjectAndStateSet, EntryOrPasswordTextFocused) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+ CallGeneralDependencies(ATSPI_ROLE_ENTRY, stateSet_);
+
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_FOCUSED)).WillOnce(Return(true));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_));
+
+ EXPECT_STREQ(generate_description_trait(obj_), "IDS_ST_BODY_EDITING_T_TTS");
+}
+
+TEST_F(DescriptionTraitWithAccessibleObjectAndStateSet, EntryOrPasswordTextNotFocused) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+
+ CallGeneralDependencies(ATSPI_ROLE_ENTRY, stateSet_);
+
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_FOCUSED)).WillOnce(Return(false));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_));
+
+ EXPECT_STREQ(generate_description_trait(obj_), "IDS_ST_BODY_DOUBLE_TAP_TO_ENTER_TEXT_T_TTS");
+}
+
+TEST_F(DescriptionTraitWithAccessibleObjectAndStateSet, MenuItemNoToolbar) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+ NewParentObject();
+
+ CallGeneralDependencies(ATSPI_ROLE_MENU_ITEM, stateSet_);
+ CallParentWithRoleDependencies();
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_)).Times(2);
+
+ EXPECT_STREQ(generate_description_trait(obj_), "");
+}
+
+TEST_F(DescriptionTraitWithAccessibleObjectAndStateSet, MenuItemWithToolbarSelected) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+ NewParentObject(ATSPI_ROLE_TOOL_BAR);
+ CallGeneralDependencies(ATSPI_ROLE_MENU_ITEM, stateSet_);
+ CallMenuRoleDependencies();
+
+ EXPECT_FUNCTION_CALL(m_atspi_selection_is_child_selected, (_, _, _)).WillOnce(Return(true));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (nullptr));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_)).Times(2);
+
+ EXPECT_STREQ(generate_description_trait(obj_), "IDS_ACCS_BODY_TAB_P1SD_OF_P2SD, IDS_ACCS_BODY_SELECTED_TTS");
+}
+
+TEST_F(DescriptionTraitWithAccessibleObjectAndStateSet, MenuItemWithToolbarNotSelected) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+
+ NewParentObject(ATSPI_ROLE_TOOL_BAR);
+ CallGeneralDependencies(ATSPI_ROLE_MENU_ITEM, stateSet_);
+ CallMenuRoleDependencies();
+
+ EXPECT_FUNCTION_CALL(m_atspi_selection_is_child_selected, (_, _, _)).WillOnce(Return(false));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (nullptr));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_)).Times(2);
+
+ EXPECT_STREQ(generate_description_trait(obj_), "IDS_ACCS_BODY_TAB_P1SD_OF_P2SD, IDS_ACCS_BODY_DOUBLE_TAP_TO_SELECT_TTS");
+}
+
+TEST_F(DescriptionTraitWithAccessibleObjectAndStateSet, ListItemNoAdditionalRole) {
+ NewParentObject();
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+ AtspiAccessible *parent_ = GetParentObject();
+
+ CallGeneralDependencies(ATSPI_ROLE_LIST_ITEM, stateSet_);
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_parent, (obj_, nullptr)).WillOnce(Return(parent_));
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_role, (parent_, nullptr)).WillOnce(Return(parentRole_));
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_state_set, (parent_));
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, _)).Times(4);
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (nullptr, _));
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (nullptr));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_)).Times(2);
+
+ EXPECT_STREQ(generate_description_trait(obj_), "");
+}
+
+TEST_F(DescriptionTraitWithAccessibleObjectAndStateSet, ListItemParentIsTreeTableAndNotMultiselectable) {
+ NewParentObject(ATSPI_ROLE_TREE_TABLE);
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+ AtspiAccessible *parent_ = GetParentObject();
+
+ CallGeneralDependencies(ATSPI_ROLE_LIST_ITEM, stateSet_);
+ CallParentWithRoleDependencies();
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_state_set, (parent_)).Times(2);
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (_, ATSPI_STATE_MULTISELECTABLE)).WillOnce(Return(false));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (nullptr)).Times(2);
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_)).Times(3);
+
+ EXPECT_STREQ(generate_description_trait(obj_), "IDS_BR_BODY_IMAGE_T_TTS");
+}
+
+TEST_F(DescriptionTraitWithAccessibleObjectAndStateSet, ListItemParentIsTreeTableAndMultiselectable) {
+ NewParentObject(ATSPI_ROLE_TREE_TABLE);
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+ AtspiAccessible *parent_ = GetParentObject();
+
+ CallGeneralDependencies(ATSPI_ROLE_LIST_ITEM, stateSet_);
+ CallParentWithRoleDependencies();
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_state_set, (parent_)).WillRepeatedly(Return(stateSet_));
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_MULTISELECTABLE)).WillOnce(Return(true));
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_selection, (parent_)).Times(1);
+ EXPECT_FUNCTION_CALL(m_atspi_selection_get_n_selected_children, (_, nullptr)).Times(1);
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (nullptr)).Times(1);
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_)).Times(5);
+
+ EXPECT_STREQ(generate_description_trait(obj_), "IDS_BR_BODY_IMAGE_T_TTSIDS_SCR_BODY_PD_SELECTED_IN_TOTAL_TTS");
+}
+
+TEST_F(DescriptionTraitWithAccessibleObjectAndStateSet, ListItemNotExpandable) {
+ NewParentObject();
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+ AtspiAccessible *parent_ = GetParentObject();
+ const int children_count = 1;
+ AtspiAccessible *childIter = new AtspiAccessible;
+
+ CallGeneralDependencies(ATSPI_ROLE_LIST_ITEM, stateSet_);
+ CallParentWithRoleDependencies();
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_state_set, (parent_)).WillOnce(Return(stateSet_));
+
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_EXPANDABLE)).WillOnce(Return(false));
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_EXPANDED)).WillOnce(Return(true));
+
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_child_count, (obj_, _)).WillOnce(Return(children_count));
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_child_at_index, (obj_, 0, _)).WillOnce(Return(childIter));
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_role, (childIter, _)).WillOnce(Return(ATSPI_ROLE_CHECK_BOX));
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_)).Times(3);
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (childIter));
+
+ EXPECT_STREQ(generate_description_trait(obj_), "IDS_AM_OPT_HEADER_TTS, IDS_SCR_TBOPT_TICKBOX_FOR_ENTIRE_GROUP");
+ delete childIter;
+}
+
+TEST_F(DescriptionTraitWithAccessibleObjectAndStateSet, ListItemExpandableAndExpanded) {
+ NewParentObject();
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+
+ CallGeneralDependencies(ATSPI_ROLE_LIST_ITEM, stateSet_);
+ CallParentWithRoleDependencies();
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_state_set, (parent_)).WillOnce(Return(stateSet_));
+
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_EXPANDABLE)).WillRepeatedly(Return(true));
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_EXPANDED)).WillOnce(Return(true));
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_)).Times(3);
+
+ EXPECT_STREQ(generate_description_trait(obj_), "IDS_TPLATFORM_BODY_EXPANDABLE_LIST, IDS_ACCS_BODY_DOUBLE_TAP_TO_COLLAPSE_THE_LIST_T_TTS");
+}
+
+TEST_F(DescriptionTraitWithAccessibleObjectAndStateSet, ListItemExpandableAndNotExpanded) {
+ NewParentObject();
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+ AtspiAccessible *parent_ = GetParentObject();
+
+ CallGeneralDependencies(ATSPI_ROLE_LIST_ITEM, stateSet_);
+ CallParentWithRoleDependencies();
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_state_set, (parent_)).WillOnce(Return(stateSet_));
+
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_EXPANDABLE)).WillRepeatedly(Return(true));
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_EXPANDED)).WillOnce(Return(false));
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_)).Times(3);
+
+ EXPECT_STREQ(generate_description_trait(obj_), "IDS_TPLATFORM_BODY_EXPANDABLE_LIST, IDS_ACCS_BODY_DOUBLE_TAP_TO_EXPAND_THE_LIST_T_TTS");
+}
+
+TEST_F(DescriptionTraitWithAccessibleObjectAndStateSet, ListItemAnimated) {
+ NewParentObject();
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+ AtspiAccessible *parent_ = GetParentObject();
+
+ CallGeneralDependencies(ATSPI_ROLE_LIST_ITEM, stateSet_);
+ CallParentWithRoleDependencies();
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_state_set, (parent_)).WillOnce(Return(stateSet_));
+
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_EXPANDABLE)).WillRepeatedly(Return(false));
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_EXPANDED)).WillOnce(Return(false));
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_COLLAPSED)).WillOnce(Return(false));
+
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_ANIMATED)).WillOnce(Return(true));
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_)).Times(3);
+
+ EXPECT_STREQ(generate_description_trait(obj_), "IDS_BR_BODY_DOUBLE_TAP_AND_HOLD_THEN_DRAG_TO_REORDER_TTS");
+}
+
+TEST_F(DescriptionTraitWithAccessibleObjectAndStateSet, PopupMenu) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ CallGeneralDependencies(ATSPI_ROLE_POPUP_MENU, stateSet_);
+
+ NewParentObject();
+ CallParentWithRoleDependencies();
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_child_count, (obj_, nullptr));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_)).Times(2);
+
+ EXPECT_STREQ(generate_description_trait(obj_), "IDS_WEBVIEW_BODY_SHOWING_PD_ITEMS_TTS");
+}
+
+TEST_F(DescriptionTraitWithAccessibleObjectAndStateSet, Dialog) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ CallGeneralDependencies(ATSPI_ROLE_DIALOG, stateSet_);
+
+ EXPECT_FUNCTION_CALL(m__find_popup_list_children_count, (obj_)).Times(1);
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_));
+
+ EXPECT_STREQ(generate_description_trait(obj_), "");
+}
+
+TEST_F(DescriptionTraitWithAccessibleObjectAndStateSet, ComboBoxOrGlassPane) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+
+ CallGeneralDependencies(ATSPI_ROLE_COMBO_BOX, stateSet_);
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_));
+
+
+ EXPECT_STREQ(generate_description_trait(obj_), "IDS_ST_BODY_DOUBLE_TAP_TO_OPEN_THE_MENU_T_TTS");
+}
+
+TEST_F(DescriptionTraitWithAccessibleObjectAndStateSet, CheckBoxOrRadioButton) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+
+ CallGeneralDependencies(ATSPI_ROLE_RADIO_BUTTON, stateSet_);
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_parent, (obj_, _)).Times(1);
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_CHECKED)).WillOnce(Return(false));
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_EDITABLE)).WillOnce(Return(true));
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (nullptr));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_));
+
+ EXPECT_STREQ(generate_description_trait(obj_), "WDS_TTS_TBBODY_DOUBLE_TAP_TO_EDIT");
+}
+
+TEST_F(DescriptionTraitWithAccessibleObjectAndStateSet, ProgressBar) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+
+ CallGeneralDependencies(ATSPI_ROLE_PROGRESS_BAR, stateSet_);
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_));
+
+ EXPECT_STREQ(generate_description_trait(obj_), "IDS_ACCS_TBBODY_IN_PROGRESS");
+}
+
+TEST_F(DescriptionTraitWithAccessibleObjectAndStateSet, Slider) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+
+ CallGeneralDependencies(ATSPI_ROLE_SLIDER, stateSet_);
+
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_ENABLED)).WillOnce(Return(true));
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_));
+
+ EXPECT_STREQ(generate_description_trait(obj_), "IDS_TPLATFORM_BODY_FLICK_UP_AND_DOWN_TO_ADJUST_THE_POSITION_T_TTS");
+}
--- /dev/null
+#include "screen_reader_utils.hpp"
+
+using ::testing::AnyNumber;
+
+class ScreenReaderUtilsDisplayInfoFixture : public ::testing::Test {
+protected:
+ AtspiAccessible *obj_;
+ AtspiComponent *comp_;
+
+ DEFINE_MOCKING(atspi_accessible_get_child_count);
+ DEFINE_MOCKING(atspi_accessible_get_component_iface);
+ DEFINE_MOCKING(atspi_component_get_highlight_index);
+ DEFINE_MOCKING(atspi_accessible_get_index_in_parent);
+ DEFINE_MOCKING(atspi_accessible_get_object_locale);
+
+ AtspiAccessible *newAtspiAccessibleObject() {
+ if (obj_)
+ delete obj_;
+
+ obj_ = new AtspiAccessible;
+
+ return obj_;
+ }
+
+ AtspiComponent *newAtspiComponentObject() {
+ if (comp_)
+ delete comp_;
+
+ comp_ = new AtspiComponent;
+
+ return comp_;
+ }
+
+public:
+ void SetUp() {
+ obj_ = nullptr;
+ comp_ = nullptr;
+ }
+
+ void TearDown() {
+ if (obj_)
+ delete obj_;
+
+ if (comp_)
+ delete comp_;
+ }
+};
+
+class ScreenReaderUtilsDisplayInfoMainFunctionFixture : public ScreenReaderUtilsDisplayInfoFixture {
+protected:
+ DEFINE_MOCKING(_debug_display_object_parent_info);
+
+ DEFINE_MOCKING(_debug_display_object_name);
+ DEFINE_MOCKING(_debug_display_object_role);
+ DEFINE_MOCKING(_debug_display_object_description);
+ DEFINE_MOCKING(_debug_display_object_iface_values);
+ DEFINE_MOCKING(_debug_display_object_states);
+ DEFINE_MOCKING(_debug_display_rect_screen);
+ DEFINE_MOCKING(_debug_display_win_screen);
+ DEFINE_MOCKING(_debug_display_object_ifaces);
+
+ void CallDependenciesWithoutParentInfo(AtspiAccessible *obj_) {
+ EXPECT_FUNCTION_CALL(m__debug_display_object_name, (obj_)).Times(1);
+ EXPECT_FUNCTION_CALL(m__debug_display_object_role, (obj_)).Times(1);
+ EXPECT_FUNCTION_CALL(m__debug_display_object_description, (obj_)).Times(1);
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_child_count, (obj_, nullptr)).Times(AnyNumber());
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_component_iface, (obj_)).Times(1);
+ EXPECT_FUNCTION_CALL(m_atspi_component_get_highlight_index, (nullptr, nullptr)).Times(AnyNumber());
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_index_in_parent, (obj_, nullptr)).Times(AnyNumber());
+ EXPECT_FUNCTION_CALL(m__debug_display_object_iface_values, (obj_)).Times(1);
+ EXPECT_FUNCTION_CALL(m__debug_display_object_states, (obj_)).Times(1);
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_object_locale, (obj_, nullptr)).Times(AnyNumber());
+ EXPECT_FUNCTION_CALL(m__debug_display_rect_screen, (nullptr)).Times(1);
+ EXPECT_FUNCTION_CALL(m__debug_display_win_screen, (nullptr)).Times(1);
+ EXPECT_FUNCTION_CALL(m__debug_display_object_ifaces, (obj_)).Times(1);
+ }
+};
+
+TEST_F(ScreenReaderUtilsDisplayInfoMainFunctionFixture, DisplayInfoWithNullObject) {
+ bool displayParentInfo_ = false;
+ debug_display_info_about_object(nullptr, displayParentInfo_);
+}
+
+TEST_F(ScreenReaderUtilsDisplayInfoMainFunctionFixture, DisplayInfoWithoutParentInfo) {
+ bool displayParentInfo_ = false;
+ AtspiAccessible *obj_ = newAtspiAccessibleObject();
+
+ CallDependenciesWithoutParentInfo(obj_);
+
+ debug_display_info_about_object(obj_, displayParentInfo_);
+}
+
+TEST_F(ScreenReaderUtilsDisplayInfoMainFunctionFixture, DisplayInfoWithParentInfo) {
+ bool displayParentInfo_ = true;
+ AtspiAccessible *obj_ = newAtspiAccessibleObject();
+
+ EXPECT_FUNCTION_CALL(m__debug_display_object_parent_info, (obj_)).Times(1);
+ CallDependenciesWithoutParentInfo(obj_);
+
+ debug_display_info_about_object(obj_, displayParentInfo_);
+}
+
+class ScreenReaderUtilsDisplayInfoDependenciesFixture : public ScreenReaderUtilsDisplayInfoFixture {
+protected:
+ DEFINE_MOCKING(atspi_component_get_extents);
+ DEFINE_MOCKING(atspi_accessible_get_parent);
+ DEFINE_MOCKING(atspi_accessible_get_interfaces);
+ DEFINE_MOCKING(atspi_accessible_get_state_set);
+ DEFINE_MOCKING(atspi_state_set_get_states);
+ DEFINE_MOCKING(atspi_accessible_get_value_iface);
+ DEFINE_MOCKING(atspi_value_get_current_value);
+ DEFINE_MOCKING(atspi_value_get_maximum_value);
+ DEFINE_MOCKING(atspi_value_get_minimum_value);
+ DEFINE_MOCKING(atspi_accessible_get_description);
+ DEFINE_MOCKING(atspi_accessible_get_localized_role_name);
+ DEFINE_MOCKING(atspi_accessible_get_name);
+};
+
+TEST_F(ScreenReaderUtilsDisplayInfoDependenciesFixture, DisplayWinScreenWithNullComponent) {
+ EXPECT_FUNCTION_CALL(m_atspi_component_get_extents, (nullptr, ATSPI_COORD_TYPE_WINDOW, nullptr)).Times(1);
+
+ _debug_display_win_screen(nullptr);
+}
+
+TEST_F(ScreenReaderUtilsDisplayInfoDependenciesFixture, DisplayWinScreenWithNullAtspiRect) {
+ AtspiComponent *comp_ = newAtspiComponentObject();
+ EXPECT_FUNCTION_CALL(m_atspi_component_get_extents, (comp_, ATSPI_COORD_TYPE_WINDOW, nullptr)).WillOnce(Return(nullptr));
+
+ _debug_display_win_screen(comp_);
+}
+
+TEST_F(ScreenReaderUtilsDisplayInfoDependenciesFixture, DisplayWinScreen) {
+ AtspiComponent *comp_ = newAtspiComponentObject();
+ EXPECT_FUNCTION_CALL(m_atspi_component_get_extents, (comp_, ATSPI_COORD_TYPE_WINDOW, nullptr)).Times(1);
+
+ _debug_display_win_screen(comp_);
+}
+
+TEST_F(ScreenReaderUtilsDisplayInfoDependenciesFixture, DisplayRectScreenWithNullComponent) {
+ EXPECT_FUNCTION_CALL(m_atspi_component_get_extents, (nullptr, ATSPI_COORD_TYPE_SCREEN, nullptr)).Times(1);
+
+ _debug_display_rect_screen(comp_);
+}
+
+TEST_F(ScreenReaderUtilsDisplayInfoDependenciesFixture, DisplayRectScreenWithNullAtspiRect) {
+ AtspiComponent *comp_ = newAtspiComponentObject();
+ EXPECT_FUNCTION_CALL(m_atspi_component_get_extents, (comp_, ATSPI_COORD_TYPE_SCREEN, nullptr)).WillOnce(Return(nullptr));
+
+ _debug_display_rect_screen(comp_);
+}
+
+TEST_F(ScreenReaderUtilsDisplayInfoDependenciesFixture, DisplayRectScreen) {
+ AtspiComponent *comp_ = newAtspiComponentObject();
+ EXPECT_FUNCTION_CALL(m_atspi_component_get_extents, (comp_, ATSPI_COORD_TYPE_SCREEN, nullptr)).Times(1);
+
+ _debug_display_rect_screen(comp_);
+}
+
+TEST_F(ScreenReaderUtilsDisplayInfoDependenciesFixture, DisplayParentInfoWithNullParent) {
+ DEFINE_MOCKING(debug_display_info_about_object);
+ newAtspiAccessibleObject();
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_parent, (obj_, nullptr)).WillOnce(Return(nullptr));
+ EXPECT_FUNCTION_CALL(m_debug_display_info_about_object, (nullptr, false)).Times(0);
+
+ _debug_display_object_parent_info(obj_);
+}
+
+TEST_F(ScreenReaderUtilsDisplayInfoDependenciesFixture, DisplayIfacesWithNullObject) {
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_interfaces, (nullptr)).Times(1);
+
+ _debug_display_object_ifaces(nullptr);
+}
+
+TEST_F(ScreenReaderUtilsDisplayInfoDependenciesFixture, DisplayIfacesWithNullIfacesArray) {
+ newAtspiAccessibleObject();
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_interfaces, (obj_)).WillOnce(Return(nullptr));
+
+ _debug_display_object_ifaces(obj_);
+}
+
+TEST_F(ScreenReaderUtilsDisplayInfoDependenciesFixture, DisplayStatesWithNullObject) {
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_state_set, (nullptr)).Times(1);
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_get_states, (nullptr)).Times(1);
+
+ _debug_display_object_states(nullptr);
+}
+
+TEST_F(ScreenReaderUtilsDisplayInfoDependenciesFixture, DisplayIfaceValuesWithNullObject) {
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_value_iface, (nullptr)).Times(1);
+
+ EXPECT_FUNCTION_CALL(m_atspi_value_get_current_value, (nullptr, nullptr)).Times(0);
+ EXPECT_FUNCTION_CALL(m_atspi_value_get_maximum_value, (nullptr, nullptr)).Times(0);
+ EXPECT_FUNCTION_CALL(m_atspi_value_get_minimum_value, (nullptr, nullptr)).Times(0);
+
+ _debug_display_object_iface_values(nullptr);
+}
+
+TEST_F(ScreenReaderUtilsDisplayInfoDependenciesFixture, DisplayDescription) {
+ newAtspiAccessibleObject();
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_description, (obj_, nullptr)).WillOnce(Return(nullptr));
+
+ _debug_display_object_description(obj_);
+}
+
+TEST_F(ScreenReaderUtilsDisplayInfoDependenciesFixture, DisplayRole) {
+ newAtspiAccessibleObject();
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_localized_role_name, (obj_, nullptr)).WillOnce(Return(nullptr));
+
+ _debug_display_object_role(obj_);
+}
+
+TEST_F(ScreenReaderUtilsDisplayInfoDependenciesFixture, DisplayName) {
+ newAtspiAccessibleObject();
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_name, (obj_, nullptr)).WillOnce(Return(nullptr));
+
+ _debug_display_object_name(obj_);
+}
+
+TEST_F(ScreenReaderUtilsDisplayInfoDependenciesFixture, StateToChar) {
+ EXPECT_STREQ(state_to_char(ATSPI_STATE_INVALID), "ATSPI_STATE_INVALID");
+}
--- /dev/null
+#include "screen_reader_utils.hpp"
+
+class RoleTraitFixture : public ScreenReaderUtilsFixture {
+protected:
+ DEFINE_MOCKING(atspi_accessible_get_localized_role_name);
+ DEFINE_MOCKING(atspi_value_get_minimum_increment);
+ DEFINE_MOCKING(atspi_value_get_current_value);
+ DEFINE_MOCKING(atspi_accessible_get_value_iface);
+ DEFINE_MOCKING(atspi_value_get_maximum_value);
+ DEFINE_MOCKING(atspi_value_get_minimum_value);
+ DEFINE_MOCKING(atspi_accessible_get_child_count);
+ DEFINE_MOCKING(atspi_accessible_get_parent);
+ DEFINE_MOCKING(atspi_accessible_get_state_set);
+ DEFINE_MOCKING(atspi_state_set_contains);
+ DEFINE_MOCKING(g_object_unref);
+
+public:
+ void SetUp() {
+ NewAtspiAccessibleObject();
+ NewStateSet();
+ }
+
+ void RunGenRoleTraitAndFreeMemory(AtspiAccessible *obj, const char *string) {
+ char *ret = generate_role_trait(obj);
+ EXPECT_STREQ(ret, string);
+ delete ret;
+ }
+
+ void CallGeneralDependencies(AtspiRole role) {
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_role, (obj_.get(), nullptr)).WillOnce(Return(role));
+ }
+};
+
+TEST_F(RoleTraitFixture, CalcSignificantPosZero) {
+ EXPECT_EQ(calculate_significant_positions(1.0, 15), 0);
+}
+
+TEST_F(RoleTraitFixture, CalcSignificantPosFive) {
+ EXPECT_EQ(calculate_significant_positions(1.1111, 15), 4);
+}
+
+TEST_F(RoleTraitFixture, AddSliderDescriptionNoValueIface) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_localized_role_name, (obj_, nullptr)).WillOnce(Return(nullptr));
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_value_iface, (obj_)).WillOnce(Return(nullptr));
+
+ add_slider_description(nullptr, 0, obj_);
+}
+
+TEST_F(RoleTraitFixture, AddSliderDescriptionWithValueIface) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiValue *valueIface_ = (AtspiValue *)0xBADDCAFE;
+ char dest[] = "TIZEN_RULES";
+ uint dest_size = 12;
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_localized_role_name, (obj_, nullptr)).WillOnce(Return(nullptr));
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_value_iface, (obj_)).WillOnce(Return(valueIface_));
+ EXPECT_FUNCTION_CALL(m_atspi_value_get_current_value, (valueIface_, nullptr)).WillOnce(Return(50));
+ EXPECT_FUNCTION_CALL(m_atspi_value_get_maximum_value, (valueIface_, nullptr)).WillOnce(Return(100));
+ EXPECT_FUNCTION_CALL(m_atspi_value_get_minimum_value, (valueIface_, nullptr)).WillOnce(Return(0));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (valueIface_));
+
+ add_slider_description(dest, dest_size, obj_);
+}
+
+TEST_F(RoleTraitFixture, NullObject) {
+ AtspiAccessible *obj_ = nullptr;
+ RunGenRoleTraitAndFreeMemory(obj_, "");
+}
+
+TEST_F(RoleTraitFixture, InvalidRoleNoRoleName) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+
+ CallGeneralDependencies(ATSPI_ROLE_INVALID);
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_localized_role_name, (obj_, nullptr)).WillOnce(Return(nullptr));
+
+ RunGenRoleTraitAndFreeMemory(obj_, "");
+}
+
+TEST_F(RoleTraitFixture, InvalidRoleWithRoleName) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ const char *str = "TIZEN";
+ char *result = new char[strlen(str) + 1];
+ strcpy(result, str);
+
+ CallGeneralDependencies(ATSPI_ROLE_INVALID);
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_localized_role_name, (obj_, nullptr)).WillOnce(Return(result));
+
+ RunGenRoleTraitAndFreeMemory(obj_, str);
+}
+
+TEST_F(RoleTraitFixture, EntryOrPasswordTextNoRoleName) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+
+ CallGeneralDependencies(ATSPI_ROLE_PASSWORD_TEXT);
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_localized_role_name, (obj_, nullptr)).WillOnce(Return(nullptr));
+
+ RunGenRoleTraitAndFreeMemory(obj_, "");
+}
+
+TEST_F(RoleTraitFixture, EntryOrPasswordTextWithRoleName) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ const char *str = "TIZEN";
+ char *result = new char[strlen(str) + 1];
+ strcpy(result, str);
+
+ CallGeneralDependencies(ATSPI_ROLE_PASSWORD_TEXT);
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_localized_role_name, (obj_, nullptr)).WillOnce(Return(result));
+
+ RunGenRoleTraitAndFreeMemory(obj_, str);
+}
+
+TEST_F(RoleTraitFixture, ComboBox) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ int children_count = 2;
+
+ CallGeneralDependencies(ATSPI_ROLE_COMBO_BOX);
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_child_count, (obj_, nullptr)).WillOnce(Return(children_count));
+
+ RunGenRoleTraitAndFreeMemory(obj_, "IDS_ACCS_BODY_DROPDOWN_LIST_TTS IDS_WEBVIEW_BODY_SHOWING_PD_ITEMS_TTS");
+}
+
+TEST_F(RoleTraitFixture, GlassPane) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiAccessible *parent_ = (AtspiAccessible *)0xbaddcafe;
+ int children_count = 2;
+
+ CallGeneralDependencies(ATSPI_ROLE_GLASS_PANE);
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_parent, (obj_, nullptr)).WillOnce(Return(parent_));
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_child_count, (parent_, nullptr)).WillOnce(Return(children_count));
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (parent_));
+
+ RunGenRoleTraitAndFreeMemory(obj_, "IDS_ACCS_BODY_DROPDOWN_LIST_TTS IDS_WEBVIEW_BODY_SHOWING_PD_ITEMS_TTS");
+}
+
+TEST_F(RoleTraitFixture, ListItemParentNotAnimated) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiAccessible *parent_ = (AtspiAccessible *)0xbaddcafe;
+ AtspiStateSet *parentStateSet_ = (AtspiStateSet *)0xdeadbeef;
+
+ CallGeneralDependencies(ATSPI_ROLE_LIST_ITEM);
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_parent, (obj_, nullptr)).WillOnce(Return(parent_));
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_state_set, (parent_)).WillOnce(Return(parentStateSet_));
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (parentStateSet_, ATSPI_STATE_ANIMATED)).WillOnce(Return(false));
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (parent_));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (parentStateSet_));
+
+ RunGenRoleTraitAndFreeMemory(obj_, "");
+}
+
+TEST_F(RoleTraitFixture, ListItemParentIsAnimated) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiAccessible *parent_ = (AtspiAccessible *)0xbaddcafe;
+ AtspiStateSet *parentStateSet_ = (AtspiStateSet *)0xdeadbeef;
+
+ CallGeneralDependencies(ATSPI_ROLE_LIST_ITEM);
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_parent, (obj_, nullptr)).WillOnce(Return(parent_));
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_state_set, (parent_)).WillOnce(Return(parentStateSet_));
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (parentStateSet_, ATSPI_STATE_ANIMATED)).WillOnce(Return(true));
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (parent_));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (parentStateSet_));
+
+ RunGenRoleTraitAndFreeMemory(obj_, "IDS_GALLERY_OPT_REORDER");
+}
+
+TEST_F(RoleTraitFixture, PushButton) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+
+ CallGeneralDependencies(ATSPI_ROLE_PUSH_BUTTON);
+
+ RunGenRoleTraitAndFreeMemory(obj_, "IDS_ACCS_BODY_BUTTON_TTS");
+}
+
+TEST_F(RoleTraitFixture, ProgressBarNoIfaceValue) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+
+ CallGeneralDependencies(ATSPI_ROLE_PROGRESS_BAR);
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_value_iface, (obj_)).WillOnce(Return(nullptr));
+
+ RunGenRoleTraitAndFreeMemory(obj_, "");
+}
+
+TEST_F(RoleTraitFixture, ProgressBarZeroCurrentValue) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiValue *value = (AtspiValue *)0xdeadbeef;
+ double val = 0.0;
+
+ CallGeneralDependencies(ATSPI_ROLE_PROGRESS_BAR);
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_value_iface, (obj_)).WillOnce(Return(value));
+ EXPECT_FUNCTION_CALL(m_atspi_value_get_current_value, (value, nullptr)).WillOnce(Return(val));
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (value));
+
+ RunGenRoleTraitAndFreeMemory(obj_, "");
+}
+
+TEST_F(RoleTraitFixture, ProgressBarPositiveCurrentValue) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiValue *value = (AtspiValue *)0xdeadbeef;
+ double val = 1.0;
+
+ CallGeneralDependencies(ATSPI_ROLE_PROGRESS_BAR);
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_value_iface, (obj_)).WillOnce(Return(value));
+ EXPECT_FUNCTION_CALL(m_atspi_value_get_current_value, (value, nullptr)).WillOnce(Return(val));
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (value));
+
+ RunGenRoleTraitAndFreeMemory(obj_, "IDS_GCTS_OPT_P1SS_PERCENT_TTS");
+}
+
+TEST_F(RoleTraitFixture, ToggleButton) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+
+ CallGeneralDependencies(ATSPI_ROLE_TOGGLE_BUTTON);
+
+ RunGenRoleTraitAndFreeMemory(obj_, "IDS_ACCS_BODY_BUTTON_TTS");
+}
+
+TEST_F(RoleTraitFixture, Slider) {
+ DEFINE_MOCKING(add_slider_description);
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+
+ CallGeneralDependencies(ATSPI_ROLE_SLIDER);
+ EXPECT_FUNCTION_CALL(m_add_slider_description, (_, _, obj_)).Times(1);
+
+ RunGenRoleTraitAndFreeMemory(obj_, "");
+}
--- /dev/null
+#include "screen_reader_utils.hpp"
+
+class StateTraitFixture : public ScreenReaderUtilsFixture {
+
+protected:
+ DEFINE_MOCKING(atspi_accessible_get_parent);
+
+ void CallGeneralDependencies(AtspiRole role, AtspiStateSet *stateSet_) {
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_role, (obj_.get(), nullptr)).WillOnce(Return(role));
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_state_set, (obj_.get())).WillOnce(Return(stateSet_));
+ }
+
+ AtspiAccessible *GetParentObject() {
+ return parent_;
+ }
+
+ AtspiAccessible *parent_;
+
+public:
+ void SetUp() {
+ NewAtspiAccessibleObject();
+ NewStateSet();
+ NewParentObject();
+ }
+
+ AtspiAccessible *NewParentObject() {
+ parent_ = (AtspiAccessible *)0xBADDCAFE;
+ return parent_;
+ }
+
+ void RunGenStateTraitAndFreeMemory(AtspiAccessible *obj, const char *string) {
+ char *ret = generate_state_trait(obj);
+ EXPECT_STREQ(ret, string);
+ delete ret;
+ }
+};
+
+TEST_F(StateTraitFixture, NullObject) {
+ RunGenStateTraitAndFreeMemory(nullptr, "");
+}
+
+TEST_F(StateTraitFixture, InvalidRole) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+
+ CallGeneralDependencies(ATSPI_ROLE_INVALID, stateSet_);
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_));
+
+ RunGenStateTraitAndFreeMemory(obj_, "");
+}
+
+TEST_F(StateTraitFixture, ListItemParentIsNotTreeTable) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+ AtspiAccessible *parent_ = GetParentObject();
+
+ CallGeneralDependencies(ATSPI_ROLE_LIST_ITEM, stateSet_);
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_parent, (obj_, nullptr)).WillOnce(Return(parent_));
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_role, (parent_, nullptr)).WillOnce(Return(ATSPI_ROLE_INVALID));
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (parent_));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_));
+
+ RunGenStateTraitAndFreeMemory(obj_, "");
+}
+
+TEST_F(StateTraitFixture, ListItemParentIsTreeTableNoSelected) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+ AtspiAccessible *parent_ = GetParentObject();
+
+ CallGeneralDependencies(ATSPI_ROLE_LIST_ITEM, stateSet_);
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_parent, (obj_, nullptr)).WillOnce(Return(parent_));
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_role, (parent_, nullptr)).WillOnce(Return(ATSPI_ROLE_TREE_TABLE));
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (_, ATSPI_STATE_SELECTED)).WillOnce(Return(FALSE));
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (parent_));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_));
+
+ RunGenStateTraitAndFreeMemory(obj_, "");
+}
+
+TEST_F(StateTraitFixture, ListItemParentIsTreeTableIsSelected) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+ AtspiAccessible *parent_ = GetParentObject();
+
+ CallGeneralDependencies(ATSPI_ROLE_LIST_ITEM, stateSet_);
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_parent, (obj_, nullptr)).WillOnce(Return(parent_));
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_role, (parent_, nullptr)).WillOnce(Return(ATSPI_ROLE_TREE_TABLE));
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (_, ATSPI_STATE_SELECTED)).WillOnce(Return(TRUE));
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (parent_));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_));
+
+ RunGenStateTraitAndFreeMemory(obj_, "IDS_ACCS_BODY_SELECTED_TTS");
+}
+
+TEST_F(StateTraitFixture, CheckBoxOrRadioButtonNoTrait) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+ AtspiAccessible *parent_ = GetParentObject();
+
+ CallGeneralDependencies(ATSPI_ROLE_CHECK_BOX, stateSet_);
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_parent, (obj_, nullptr)).WillOnce(Return(parent_));
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_role, (parent_, nullptr)).WillOnce(Return(ATSPI_ROLE_INVALID));
+
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_CHECKED)).WillOnce(Return(false));
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_EDITABLE)).WillOnce(Return(true));
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (parent_));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_));
+
+ RunGenStateTraitAndFreeMemory(obj_, "");
+}
+
+TEST_F(StateTraitFixture, CheckBoxOrRadioButtonSelected) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+ AtspiAccessible *parent_ = GetParentObject();
+
+ CallGeneralDependencies(ATSPI_ROLE_CHECK_BOX, stateSet_);
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_parent, (obj_, nullptr)).WillOnce(Return(parent_));
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_role, (parent_, nullptr)).WillOnce(Return(ATSPI_ROLE_INVALID));
+
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_CHECKED)).WillOnce(Return(true));
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (parent_));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_));
+
+ RunGenStateTraitAndFreeMemory(obj_, "IDS_ACCS_BODY_SELECTED_TTS");
+}
+
+TEST_F(StateTraitFixture, CheckBoxOrRadioButtonParentIsColorChooser) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+ AtspiAccessible *parent_ = GetParentObject();
+
+ CallGeneralDependencies(ATSPI_ROLE_CHECK_BOX, stateSet_);
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_parent, (obj_, nullptr)).WillOnce(Return(parent_));
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_role, (parent_, nullptr)).WillOnce(Return(ATSPI_ROLE_COLOR_CHOOSER));
+
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_CHECKED)).WillOnce(Return(false));
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_EDITABLE)).WillOnce(Return(false));
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (parent_));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_));
+
+ RunGenStateTraitAndFreeMemory(obj_, "");
+}
+
+TEST_F(StateTraitFixture, CheckBoxOrRadioButtonParentIsNotColorChooser) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+ AtspiAccessible *parent_ = GetParentObject();
+
+ CallGeneralDependencies(ATSPI_ROLE_CHECK_BOX, stateSet_);
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_parent, (obj_, nullptr)).WillOnce(Return(parent_));
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_role, (parent_, nullptr)).WillOnce(Return(ATSPI_ROLE_INVALID));
+
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_CHECKED)).WillOnce(Return(false));
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_EDITABLE)).WillOnce(Return(false));
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (parent_));
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_));
+
+ RunGenStateTraitAndFreeMemory(obj_, "IDS_ACCS_OPT_NOT_SELECTED_TTS");
+}
+
+TEST_F(StateTraitFixture, ToggleButtonChecked) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+
+ CallGeneralDependencies(ATSPI_ROLE_TOGGLE_BUTTON, stateSet_);
+
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_CHECKED)).WillOnce(Return(true));
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_));
+
+ RunGenStateTraitAndFreeMemory(obj_, "IDS_MSG_BODY_ON_T_TTS");
+}
+
+TEST_F(StateTraitFixture, ToggleButtonNotChecked) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+
+ CallGeneralDependencies(ATSPI_ROLE_TOGGLE_BUTTON, stateSet_);
+
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, ATSPI_STATE_CHECKED)).WillOnce(Return(false));
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_));
+
+ RunGenStateTraitAndFreeMemory(obj_, "IDS_STORYALBUM_BODY_OFF_T_TTS");
+}
+
+TEST_F(StateTraitFixture, RadioMenuItem) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ AtspiStateSet *stateSet_ = GetStateSet();
+
+ CallGeneralDependencies(ATSPI_ROLE_RADIO_MENU_ITEM, stateSet_);
+
+ EXPECT_FUNCTION_CALL(m_atspi_state_set_contains, (stateSet_, _));
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (stateSet_));
+
+ RunGenStateTraitAndFreeMemory(obj_, "");
+}
--- /dev/null
+#include "screen_reader_utils.hpp"
+
+class TextForRelationObjects : public ScreenReaderUtilsFixture {
+public:
+ void SetUp() {
+ NewAtspiAccessibleObject();
+ callbackVisited = false;
+ }
+
+ static char *TextGenerateCallback(AtspiAccessible *obj) {
+ callbackVisited = true;
+
+ return strdup("TIZEN");
+ }
+
+ static bool IsCallbackVisited() {
+ return callbackVisited;
+ }
+
+ void RunGenTextForRelationsAndFreeMemory(AtspiAccessible *obj, AtspiRelationType search, const char *string) {
+ char *ret = generate_text_for_relation_objects(obj, search, TextGenerateCallback);
+ EXPECT_STREQ(ret, string);
+ delete ret;
+ }
+
+ GArray *CreateRelationsArray(size_t size) {
+ guint element_size = sizeof(AtspiRelation *);
+ GArray *relations = g_array_new(FALSE, FALSE, element_size);
+
+ for (size_t i = 0; i < size; ++i) {
+ g_array_append_val(relations, coockieRelations[i]);
+ EXPECT_FUNCTION_CALL(m_g_object_unref, ((void *) coockieRelations[i]));
+ }
+
+ return relations;
+ }
+
+protected:
+ DEFINE_MOCKING(atspi_accessible_get_relation_set);
+ DEFINE_MOCKING(atspi_relation_get_relation_type);
+ DEFINE_MOCKING(atspi_relation_get_n_targets);
+ DEFINE_MOCKING(atspi_relation_get_target);
+ DEFINE_MOCKING(eina_strbuf_new);
+ DEFINE_MOCKING(eina_strbuf_string_steal);
+
+ std::vector<unsigned> coockieRelations = {0xaaddcafe, 0xbaddcafe, 0xcaddcafe};
+
+private:
+ static bool callbackVisited;
+};
+
+bool TextForRelationObjects::callbackVisited = false;
+
+TEST_F(TextForRelationObjects, NullObject) {
+ RunGenTextForRelationsAndFreeMemory(nullptr, ATSPI_RELATION_NULL, nullptr);
+}
+
+TEST_F(TextForRelationObjects, NoRelationSet) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_relation_set, (obj_, nullptr)).WillOnce(Return(nullptr));
+
+ RunGenTextForRelationsAndFreeMemory(obj_, ATSPI_RELATION_NULL, nullptr);
+}
+
+TEST_F(TextForRelationObjects, RelationSetZeroLen) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ size_t relationsArraySize = 0;
+ GArray *relations = CreateRelationsArray(relationsArraySize);
+
+ EXPECT_FUNCTION_CALL(m_eina_strbuf_new, ()).Times(1);
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_relation_set, (obj_, nullptr)).WillOnce(Return(relations));
+ EXPECT_FUNCTION_CALL(m_eina_strbuf_string_steal, (_)).WillOnce(Return(nullptr));
+
+ RunGenTextForRelationsAndFreeMemory(obj_, ATSPI_RELATION_NULL, nullptr);
+ g_array_free(relations, FALSE);
+}
+
+TEST_F(TextForRelationObjects, RelationSetOneLen) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ size_t relationsArraySize = 1;
+ GArray *relations = CreateRelationsArray(relationsArraySize);
+ AtspiRelationType type = ATSPI_RELATION_FLOWS_FROM;
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_relation_set, (obj_, nullptr)).WillOnce(Return(relations));
+ EXPECT_FUNCTION_CALL(m_eina_strbuf_new, ()).Times(1);
+
+ EXPECT_FUNCTION_CALL(m_atspi_relation_get_relation_type, (_)).WillOnce(Return(type));
+ EXPECT_FUNCTION_CALL(m_eina_strbuf_string_steal, (_)).WillOnce(Return(nullptr));
+
+ RunGenTextForRelationsAndFreeMemory(obj_, ATSPI_RELATION_FLOWS_TO, nullptr);
+ EXPECT_EQ(IsCallbackVisited(), false);
+ g_array_free(relations, FALSE);
+}
+
+TEST_F(TextForRelationObjects, RelationSetTwoLenNoMatches) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ size_t relationsArraySize = 2;
+ size_t matchingTargets = 0;
+ GArray *relations = CreateRelationsArray(relationsArraySize);
+ std::vector<AtspiRelationType> relationTypes = {ATSPI_RELATION_FLOWS_FROM, ATSPI_RELATION_FLOWS_TO};
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_relation_set, (obj_, nullptr)).WillOnce(Return(relations));
+ EXPECT_FUNCTION_CALL(m_eina_strbuf_new, ()).Times(1);
+
+ EXPECT_FUNCTION_CALL(m_atspi_relation_get_relation_type, ((AtspiRelation *)coockieRelations[0])).WillOnce(Return(relationTypes[0]));
+
+ EXPECT_FUNCTION_CALL(m_atspi_relation_get_relation_type, ((AtspiRelation *)coockieRelations[1])).WillOnce(Return(relationTypes[1]));
+ EXPECT_FUNCTION_CALL(m_atspi_relation_get_n_targets, (_)).WillRepeatedly(Return(matchingTargets));
+
+ EXPECT_FUNCTION_CALL(m_eina_strbuf_string_steal, (_)).Times(1);
+
+ RunGenTextForRelationsAndFreeMemory(obj_, ATSPI_RELATION_FLOWS_TO, nullptr);
+ EXPECT_EQ(IsCallbackVisited(), false);
+ g_array_free(relations, FALSE);
+}
+
+TEST_F(TextForRelationObjects, RelationSetTwoLenOneMatches) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ size_t relationsArraySize = 2;
+ size_t matchingTargets = 1;
+ GArray *relations = CreateRelationsArray(relationsArraySize);
+ std::vector<AtspiRelationType> relationTypes = {ATSPI_RELATION_FLOWS_FROM, ATSPI_RELATION_FLOWS_TO};
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_relation_set, (obj_, nullptr)).WillOnce(Return(relations));
+ EXPECT_FUNCTION_CALL(m_eina_strbuf_new, ()).Times(1);
+
+ EXPECT_FUNCTION_CALL(m_atspi_relation_get_relation_type, ((AtspiRelation *)coockieRelations[0])).WillOnce(Return(relationTypes[0]));
+
+ EXPECT_FUNCTION_CALL(m_atspi_relation_get_relation_type, ((AtspiRelation *)coockieRelations[1])).WillOnce(Return(relationTypes[1]));
+ EXPECT_FUNCTION_CALL(m_atspi_relation_get_n_targets, (_)).WillRepeatedly(Return(matchingTargets));
+ EXPECT_FUNCTION_CALL(m_atspi_relation_get_target, ((AtspiRelation *)coockieRelations[1], _)).Times(matchingTargets);
+
+ EXPECT_FUNCTION_CALL(m_eina_strbuf_string_steal, (_)).Times(1);
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (nullptr));
+
+ RunGenTextForRelationsAndFreeMemory(obj_, ATSPI_RELATION_FLOWS_TO, nullptr);
+ EXPECT_EQ(IsCallbackVisited(), true);
+ g_array_free(relations, FALSE);
+}
+
+TEST_F(TextForRelationObjects, RelationSetTwoLenTwoMatches) {
+ AtspiAccessible *obj_ = GetAtspiAccessibleObject();
+ size_t relationsArraySize = 2;
+ size_t matchingTargets = 2;
+ GArray *relations = CreateRelationsArray(relationsArraySize);
+ std::vector<AtspiRelationType> relationTypes = {ATSPI_RELATION_FLOWS_FROM, ATSPI_RELATION_FLOWS_TO};
+
+ EXPECT_FUNCTION_CALL(m_atspi_accessible_get_relation_set, (obj_, nullptr)).WillOnce(Return(relations));
+ EXPECT_FUNCTION_CALL(m_eina_strbuf_new, ()).Times(1);
+
+ EXPECT_FUNCTION_CALL(m_atspi_relation_get_relation_type, ((AtspiRelation *)coockieRelations[0])).WillOnce(Return(relationTypes[0]));
+
+ EXPECT_FUNCTION_CALL(m_atspi_relation_get_relation_type, ((AtspiRelation *)coockieRelations[1])).WillOnce(Return(relationTypes[1]));
+ EXPECT_FUNCTION_CALL(m_atspi_relation_get_n_targets, (_)).WillRepeatedly(Return(matchingTargets));
+ EXPECT_FUNCTION_CALL(m_atspi_relation_get_target, ((AtspiRelation *)coockieRelations[1], _)).Times(matchingTargets);
+
+ EXPECT_FUNCTION_CALL(m_eina_strbuf_string_steal, (_)).Times(1);
+
+ EXPECT_FUNCTION_CALL(m_g_object_unref, (nullptr)).Times(2);
+
+ RunGenTextForRelationsAndFreeMemory(obj_, ATSPI_RELATION_FLOWS_TO, nullptr);
+ EXPECT_EQ(IsCallbackVisited(), true);
+ g_array_free(relations, FALSE);
+}
--- /dev/null
+./tests2/wrappers/generate_wrappers.py parse --arm-root /home/ade/GBS-ROOT/local/BUILD-ROOTS/scratch.i586.0/ --clang /usr/lib/llvm-6.0/lib/libclang.so --output out --commands /home/ade/GBS-ROOT/local/BUILD-ROOTS/scratch.i586.0/home/abuild/rpmbuild/BUILD/org.tizen.screen-reader-0.0.8/compile_commands.json
+
+./tests2/wrappers/generate_wrappers.py generate --output tests2/wrappers --input out
+
--- /dev/null
+#!/usr/bin/env python
+
+# written by Radoslaw Cybulski for Samsung, 2016
+# this tool will build mock objects for functions using clang as C parser to introspect source code
+# this should work on any C project, probably wont work on C++ (due to unique function names assumption)
+# requires clang.cindex ( sudo pip install clang )
+# requires clang ( sudo apt-get install clang-3.8 , you can also use newer version, but you might need to pass path for it using --clang argument )
+# tool assumes all sources exist in single directory - if you need more, contact me
+# as a bonus tool will output functions.txt file with functions from files in source directory and list of other functions every functions call (directly and indirectly)
+#
+#
+# howto:
+# 1. install prerequisites
+# 2. edit main project's CMakeLists.txt and add line
+# SET(CMAKE_EXPORT_COMPILE_COMMANDS "ON")
+# 3. build project. it will create compile_commands.json file somewhere in project's directory.
+# in case of screen-reader its GBS-ROOT/local/BUILD-ROOTS/scratch.armv7l.0/home/abuild/rpmbuild/BUILD/org.tizen.screen-reader-0.0.8/compile_commands.json
+# 4. find entry for one of source files (its json file with list of entries, every entry is dict with keys directory, command and file), copy whole value for command key.
+# 5. run ./generate_wrappers.py parse --input %{path_to_source_directory} --output %{output_database_file} --command-line "%{command_value_from_point_4} - it will print warnings and errors from clang parsing source files (there shouldnt be any errors).
+# 6. run ./generate_wrappers.py generate --input %{output_database_file_from_point_5} --output %{directory_for_wrappers} - note, that this command will remove any *.cpp *.h files in %{directory_for_wrappers} directory.
+#
+# for example for screen-reader you can use (from project's root directory):
+# tests2/wrappers/generate_wrappers.py parse --input src --output out --command-line "-D_TZ_SYS_RO_APP=\\\"/usr/apps\\\" -g -O0 -O2 -g2 -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector -Wformat-security -fmessage-length=0 -Wl,--as-needed --param=ssp-buffer-size=4 -march=armv7-a -mtune=cortex-a8 -mlittle-endian -mfpu=neon -mfloat-abi=softfp -mthumb -Wp,-D__SOFTFP__ -Wl,-O1 -Wl,--hash-style=gnu -Wa,-mimplicit-it=thumb -g -DELM_ACCESS_KEYBOARD -D_REENTRANT -D__TIZEN__ -D__TIZEN_BT__ -pthread -I/usr/include/appcore -I/usr/include/elementary-1 -I/usr/include/efl-1 -I/usr/include/ecore-fb-1 -I/usr/include/efl-1 -I/usr/include/ethumb-client-1 -I/usr/include/efl-1 -I/usr/include/ethumb-1 -I/usr/include/efl-1 -I/usr/include/edje-1 -I/usr/include/efl-1 -I/usr/include/ecore-audio-1 -I/usr/include/efl-1 -I/usr/include/embryo-1 -I/usr/include/efl-1 -I/usr/include/ecore-imf-evas-1 -I/usr/include/efl-1 -I/usr/include/ecore-evas-1 -I/usr/include/efl-1 -I/usr/include/ecore-drm-1 -I/usr/include/libdrm -I/usr/include/exynos -I/usr/include/sprd -I/usr/include/efl-1 -I/usr/include/ecore-input-evas-1 -I/usr/include/efl-1 -I/usr/include/emotion-1 -I/usr/include/efl-1 -I/usr/include/eeze-1 -I/usr/include/libmount -I/usr/include/blkid -I/usr/include/uuid -I/usr/include/efl-1 -I/usr/include/evas-1 -I/usr/include/harfbuzz -I/usr/include/fribidi -I/usr/include/freetype2 -I/usr/include/libpng16 -I/usr/include/freetype2 -I/usr/include/libpng16 -I/usr/include/efl-1 -I/usr/include/ector-1 -I/usr/include/efl-1 -I/usr/include/ecore-imf-1 -I/usr/include/efl-1 -I/usr/include/eldbus-1 -I/usr/include/efl-1 -I/usr/include/efreet-1 -I/usr/include/efl-1 -I/usr/include/efreet-1 -I/usr/include/efl-1 -I/usr/include/efreet-1 -I/usr/include/efl-1 -I/usr/include/ecore-ipc-1 -I/usr/include/efl-1 -I/usr/include/ecore-file-1 -I/usr/include/efl-1 -I/usr/include/ecore-con-1 -I/usr/include/efl-1 -I/usr/include/eio-1 -I/usr/include/efl-1 -I/usr/include/eet-1 -I/usr/include/efl-1 -I/usr/include/emile-1 -I/usr/include/at-spi-2.0 -I/usr/include/dbus-1.0 -I/usr/lib/dbus-1.0/include -I/usr/include/media -I/usr/include/system -I/usr/include/network -I/usr/include/notification -I/usr/include/appfw -I/usr/include/vconf -I/usr/include/appfw -I/usr/include/appcore -I/usr/include/sensor -I/usr/include/aul -I/usr/include/vconf -I/usr/include/ -I/usr/include/network -I/usr/include/telephony-client -I/usr/include/efl-1 -I/usr/include/ecore-wayland-1 -I/usr/include/wayland-extension -I/usr/include/efl-1 -I/usr/include/ecore-input-1 -I/usr/include/efl-1 -I/usr/include/ecore-1 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/efl-1 -I/usr/include/eo-1 -I/usr/include/efl-1 -I/usr/include/eina-1 -I/usr/include/eina-1/eina -I/usr/include/dlog -Wall -Wunused -Wno-format -Wno-format-security -fPIE -I/home/abuild/rpmbuild/BUILD/org.tizen.screen-reader-0.0.8/include -o CMakeFiles/screen-reader.dir/src/flat_navi.c.o -c /home/abuild/rpmbuild/BUILD/org.tizen.screen-reader-0.0.8/src/flat_navi.c"
+# tests2/wrappers/generate_wrappers.py generate --output tests2/wrappers --input out
+# and files in tests2/wrappers will be rebuilt
+
+from __future__ import print_function
+
+import os, sys, codecs, subprocess, argparse, cPickle, collections, shlex, json, itertools
+sys.dont_write_bytecode = True
+
+try:
+ import clang.cindex
+except Exception:
+ print('failed to import clang.cindex', file=sys.stderr)
+ sys.exit(1)
+
+clang.cindex.Type.__hash__ = lambda self: hash(self.spelling)
+
+cc = clang.cindex
+CursorKind = cc.CursorKind
+TypeKind = cc.TypeKind
+AccessSpecifier = cc.AccessSpecifier
+source_extensions = ('.c', '.cpp', '.cc', '.cxx')
+
+def cache(fnc):
+ res = {}
+ def f(v, *a, **k):
+ try:
+ return res[v]
+ except KeyError:
+ z = fnc(v, *a, **k)
+ res[v] = z
+ return z
+ if hasattr(fnc, '__name__'):
+ f.__name__ = fnc.__name__
+ return f
+def self_cache(fnc):
+ res = {}
+ def f(v, *a, **k):
+ try:
+ return res[v]
+ except KeyError:
+ z = fnc(v, *a, **k)
+ res[v] = z
+ return z
+ if hasattr(fnc, '__name__'):
+ f.__name__ = fnc.__name__
+ return f
+
+class user_type_parser(object):
+ def __init__(self, pvis):
+ self.pvis = pvis
+ self.cache = {}
+
+ def __call__(self, t, *args, **kw):
+ self.real_name = None
+ return self.get(t, *args, **kw)
+
+ def get(self, t, *args, **kw):
+ z = self.cache.get(t, None)
+ if z is None:
+ k = str(t.kind)[9:]
+ z = getattr(self, 'f_' + k)(t, *args, **kw)
+ self.cache[t] = z
+ return z
+ def f_TYPEDEF(self, t):
+ name = t.spelling
+ if name == 'test_e' or name == 'test_t':
+ name = name
+ if name and name.replace('_', '').isalnum():
+ self.real_name = name
+ d = t.get_declaration()
+ assert d is not None, t.spelling
+ tt = d.underlying_typedef_type
+ assert tt is not None, t.spelling
+ return self.get(tt)
+ def f_UNEXPOSED(self, t):
+ t2 = t.get_canonical()
+ if t2.kind != TypeKind.UNEXPOSED:
+ return self.get(t2)
+ return None, False
+ def f_VOID(self, t): return None, False
+ def f_BOOL(self, t): return None, False
+ def f_CHAR_U(self, t): return None, False
+ def f_UCHAR(self, t): return None, False
+ def f_CHAR16(self, t): return None, False
+ def f_CHAR32(self, t): return None, False
+ def f_USHORT(self, t): return None, False
+ def f_UINT(self, t): return None, False
+ def f_ULONG(self, t): return None, False
+ def f_ULONGLONG(self, t): return None, False
+ def f_UINT128(self, t): return None, False
+ def f_CHAR_S(self, t): return None, False
+ def f_SCHAR(self, t): return None, False
+ def f_WCHAR(self, t): return None, False
+ def f_SHORT(self, t): return None, False
+ def f_INT(self, t): return None, False
+ def f_LONG(self, t): return None, False
+ def f_LONGLONG(self, t): return None, False
+ def f_INT128(self, t): return None, False
+ def f_FLOAT(self, t): return None, False
+ def f_DOUBLE(self, t): return None, False
+ def f_LONGDOUBLE(self, t): return None, False
+ def f_NULLPTR(self, t): return None, False
+ def f_POINTER(self, t): return self.get(t.get_pointee())[0], True
+ def f_RECORD(self, t): return self.pvis.construct_struct(t, self.real_name), False
+ def f_ENUM(self, t): return self.pvis.construct_struct(t, self.real_name), False
+ def f_FUNCTIONNOPROTO(self, t): return None, False
+ def f_FUNCTIONPROTO(self, t): return None, False
+ def f_CONSTANTARRAY(self, t): return self.get(t.get_array_element_type())[0], True
+ def f_VECTOR(self, t): return self.get(t.get_array_element_type())[0], True
+ def f_INCOMPLETEARRAY(self, t): return self.get(t.get_array_element_type())[0], True
+ def f_VARIABLEARRAY(self, t): return self.get(t.get_array_element_type())[0], True
+ def f_DEPENDENTSIZEDARRAY(self, t): return self.get(t.get_array_element_type())[0], True
+ def f_MEMBERPOINTER(self, t): return self.get(t.get_pointee())[0], True
+ def f_ELABORATED(self, t): return None, False
+
+class base(object):
+ def __init__(self, name, full_name, raw_full_name):
+ self.name = name
+ self.full_name = full_name
+ self.raw_full_name = raw_full_name
+
+ def get_compare_ident(self):
+ return self.full_name
+ def __le__(self, other):
+ return self.get_compare_ident() < other.get_compare_ident()
+ def __eq__(self, other):
+ return self.get_compare_ident() == other.get_compare_ident()
+ def __ne__(self, other):
+ return self.get_compare_ident() != other.get_compare_ident()
+ def __hash__(self):
+ return hash(self.get_compare_ident())
+
+local_source_directory = None
+class location(object):
+ @staticmethod
+ def file_is_source(file):
+ return file.lower().endswith(source_extensions)
+
+ @staticmethod
+ def file_is_local_directory(file):
+ return local_source_directory and file.startswith(local_source_directory)
+
+ def __init__(self, node):
+ self.file = ''
+ self.line = self.column = 0
+ self.is_source = False
+ self.is_local_directory = False
+ if node._tu is not None:
+ loc = node.location
+ if loc.file is not None:
+ loc2 = clang.cindex.SourceLocation.from_offset(node._tu, loc.file, loc.offset)
+ self.file = loc2.file.name
+ self.line = loc2.line
+ self.column = loc2.column
+ self.is_source = self.file_is_source(self.file)
+ self.is_local_directory = self.file_is_local_directory(self.file)
+ if self.is_local_directory:
+ q = self.file[len(local_source_directory):]
+ assert q.startswith(os.path.sep)
+ self.local_name = q[1:]
+ else:
+ self.local_name = None
+
+ def __hash__(self):
+ return hash((self.file, self.line, self.column))
+
+ def __eq__(self, other):
+ if other is None:
+ return False
+ return self.file == other.file and self.line == other.line and self.column == other.column
+
+ def __ne__(self, other):
+ return not self == other
+
+ def __repr__(self):
+ return '<location %s:%s:%s>' % (self.file, self.line, self.column)
+
+class type_info(base):
+ def __init__(self, full_name, raw_full_name, user_type, is_ptr):
+ base.__init__(self, full_name, full_name, raw_full_name)
+ self.user_type_if_any = user_type
+ self.is_pointer = is_ptr
+ def __repr__(self):
+ return '<type %s>' % (self.full_name)
+
+class argument(base):
+ def __init__(self, name, full_name, raw_full_name, type):
+ base.__init__(self, name, full_name, raw_full_name)
+ self.type = type
+ def __repr__(self):
+ return '<argument %s %s>' % (self.type.full_name, self.name)
+
+class enum_value(base):
+ def __init__(self, name, full_name, value):
+ base.__init__(self, name, full_name, full_name)
+ self.value = value
+
+class symbol(base):
+ def __init__(self, name, full_name, raw_full_name, usr):
+ base.__init__(self, name, full_name, raw_full_name)
+ self.usr = usr
+ self.def_location = None
+ self.decl_locations = set()
+ self.includes = collections.OrderedDict()
+
+ @property
+ def hidden(self):
+ return not self.includes
+
+ @property
+ def public(self):
+ for d in self.decl_locations:
+ if d.file.endswith('.h'):
+ return True
+ return False
+
+ def add_location(self, loc, decl, include=None):
+ if decl:
+ self.decl_locations.add(loc)
+ else:
+ if self.def_location is not None and self.def_location != loc:
+ print('warning: function %s is multiply defined, in %s and %s' % (self.full_name, self.def_location, loc))
+ else:
+ self.def_location = loc
+ if include is not None:
+ self.includes[include.include_text] = include
+
+ def get_location(self):
+ if self.def_location:
+ return self.def_location
+ else:
+ return list(self.decl_locations)[0]
+
+class struct(symbol):
+ def __init__(self, name, full_name, usr, members, kind, typedefed=None):
+ symbol.__init__(self, name, full_name, full_name, usr)
+ self.members = members
+ self.kind = kind
+ self.typedefed = typedefed
+
+ def get_compare_ident(self):
+ return self.full_name or self.typedefed
+ def __repr__(self):
+ v = self.get_location()
+ return '<struct %s:%s:%s %s>' % (v.file, v.line, v.column, self.full_name)
+
+class function(symbol):
+ def __init__(self, name, full_name, raw_full_name, usr, arguments, return_type, is_variadic):
+ symbol.__init__(self, name, full_name, raw_full_name, usr)
+ self.arguments = arguments
+ self.return_type = return_type
+ self.is_variadic = is_variadic
+ self.static = False
+
+ def __repr__(self):
+ v = self.get_location()
+ return '<function %s:%s:%s %s>' % (v.file, v.line, v.column, self.full_name)
+
+class visitor(object):
+ def __init__(self):
+ self.stack = []
+
+ def __call__(self, node, *args, **kw):
+ kind = self.get_kind(node)
+ return self.call_f(kind, node, *args, **kw)
+
+ def get_kind(self, node):
+ return str(node.kind).split('.')[1]
+
+ def call_f(self, kind, node, *args, **kw):
+ if kind is None:
+ kind = self.get_kind(node)
+ f = getattr(self, 'f_' + kind, self.f_default)
+ return f(kind, node, *args, **kw)
+
+ def f_default(self, kind, *args, **kw):
+ pass
+
+class recursive_visitor(visitor):
+ def __init__(self):
+ visitor.__init__(self)
+ self.stack = []
+
+ def recurse(self, kind, node, *args, **kw):
+ self.stack.append(node)
+ try:
+ for n in node.get_children():
+ nk = self.get_kind(n)
+ f = getattr(self, 'f_' + nk, self.f_default)
+ f(nk, n, *args, **kw)
+ finally:
+ self.stack.pop()
+
+ def call_p(self, kind, node, *args, **kw):
+ if kind is None:
+ kind = self.get_kind(node)
+ f = getattr(self, 'p_' + kind, self.p_default)
+ return f(kind, node, *args, **kw)
+
+ def p_default(self, *args, **kw):
+ pass
+
+ def f_default(self, kind, *args, **kw):
+ if not self.call_p(kind, *args, **kw):
+ return self.recurse(kind, *args, **kw)
+
+def normalize(pth):
+ v = os.path.normpath(os.path.abspath(pth))
+ v2 = v.rstrip(os.path.sep)
+ return v2
+
+class include_info(object):
+ def __init__(self, include_text, included_file_path, include_stack):
+ assert all(isinstance(q, basestring) for q in (include_text, included_file_path))
+ self.include_text = include_text
+ self.is_source = location.file_is_source(included_file_path)
+ self.is_local_directory = location.file_is_local_directory(included_file_path)
+ self.included_file_path = included_file_path
+ self.include_stack = tuple(include_stack)
+ if not (include_stack and include_stack[-1] == include_text):
+ pass
+ assert include_stack and include_stack[-1] == include_text, (include_text, include_stack)
+
+class parsing_visitor(recursive_visitor):
+ def __init__(self):
+ recursive_visitor.__init__(self)
+ self.function = None
+ self.includes = None
+ self.types_cache = {}
+ self.functions = {}
+ self.structs = {}
+ self.called_functions = collections.defaultdict(set)
+ self.include_files = {}
+ self.include_text_cache = {}
+ self.source_directory = None
+
+ def process(self, tu, include_directories, local_source_directory_):
+ self.includes = include_directories
+ self.include_list = list(tu.get_includes())
+ self.source_file = sp = self.include_list[0].source.name
+ self.source_directory = os.path.dirname(sp)
+ self.include_text_cache = {}
+ self.basic_include_map_cache = {}
+ self.type_parser = user_type_parser(self)
+ self.local_source_directory = local_source_directory_
+
+ global local_source_directory
+ local_source_directory = local_source_directory_
+
+ direct_includes = collections.OrderedDict()
+ external_includes = collections.OrderedDict()
+ all_includes = collections.OrderedDict()
+ basic_include_map_cache = self.basic_include_map_cache
+ local_depth = 0
+ include_stack = []
+ for e, inc in enumerate(self.include_list):
+ include_path = inc.include.name
+ depth = inc.depth
+ del include_stack[depth - 1:]
+ include_name = self.get_include_text_from_full_path(include_path)
+ include_stack.append(include_name)
+
+ if depth == 1:
+ current = act = include_info(include_name, include_path, include_stack)
+ direct_includes[act.included_file_path] = act
+ else:
+ act = basic_include_map_cache.get(include_path, None)
+ if act is None:
+ act = include_info(include_name, include_path, include_stack)
+ basic_include_map_cache[include_path] = current
+
+ all_includes[act.included_file_path] = act
+ if local_depth >= depth:
+ local_depth = depth - 1
+ if local_depth == depth - 1:
+ is_local = act.is_local_directory
+ if is_local:
+ local_depth = depth
+ elif act.include_text not in external_includes:
+ external_includes[act.include_text] = act
+
+ #sys.exit(1)
+ z = self(tu.cursor)
+ self.include_files[sp] = direct_includes, external_includes, all_includes
+ return z
+
+ def get_include_text_from_full_path(self, pth):
+ cache = self.include_text_cache
+ z = cache.get(pth, None)
+ if z is None:
+ def proc(i):
+ if not i:
+ if pth.find('/') >= 0:
+ return None
+ return pth
+ if pth.startswith(i):
+ text = pth[len(i):]
+ if text.startswith('/'):
+ text = text[1:]
+ return text
+ return None
+ for i in self.includes:
+ z = proc(i)
+ if z is not None:
+ break
+ else:
+ z = proc(self.source_directory)
+ if z is None:
+ print('fatal: cant find include directory for file %s' % pth)
+ sys.exit(1)
+ cache[pth] = z
+ return z
+
+ def f_ENUM_CONSTANT_DECL(self, kind, node, depth, *args, **kw):
+ p = node.lexical_parent
+ assert p.kind == CursorKind.ENUM_DECL, (node.spelling, p.spelling)
+ s = self.construct_struct(p)
+ name = node.spelling
+ l = len(s.used)
+ s.used.add(name)
+ if len(s.used) > l:
+ ev = enum_value(node.spelling, '%s = %s' % (node.spelling, node.enum_value), node.enum_value)
+ s.members.append(ev)
+ return self.f_default(kind, node, depth, *args, **kw)
+
+ def f_ENUM_DECL(self, kind, node, depth, *args, **kw):
+ s = self.construct_struct(node)
+ return self.f_default(kind, node, depth, *args, **kw)
+
+ def f_UNION_DECL(self, kind, node, depth, *args, **kw):
+ s = self.construct_struct(node)
+ return self.f_default(kind, node, depth, *args, **kw)
+
+ def f_STRUCT_DECL(self, kind, node, depth, *args, **kw):
+ s = self.construct_struct(node)
+ return self.f_default(kind, node, depth, *args, **kw)
+
+ def f_FUNCTION_DECL(self, kind, node, depth, *args, **kw):
+ f = self.construct_function(node)
+ assert self.function is None
+ self.function = f
+ v = self.f_default(kind, node, depth, *args, **kw)
+ self.function = None
+ return v
+
+ def do_function(self, node):
+ f = self.construct_function(node)
+ self.called_functions[self.function].add(f)
+ return f
+
+ def check_ptr_to_func(self, ref):
+ if ref.kind == CursorKind.FUNCTION_DECL:
+ return self.do_function(ref)
+
+ def p_DECL_REF_EXPR(self, kind, node, depth, *args, **kw):
+ ref = node.referenced
+ assert ref is not None, node.spelling
+ f = self.check_ptr_to_func(ref)
+ return self.p_default(kind, node, depth, *args, **kw)
+
+ def __call__(self, node):
+ z = recursive_visitor.__call__(self, node, 0)
+ return z
+
+ def construct_type(self, type):
+ v = self.types_cache.get(type.spelling, None)
+ if v is None:
+ full_name = type.spelling.strip()
+ if full_name.endswith('restrict'):
+ full_name = full_name[:-8].strip()
+ can = type.get_canonical()
+ raw_full_name = can.spelling.strip()
+ if raw_full_name.endswith('restrict'):
+ raw_full_name = raw_full_name[:-8].strip()
+ user_type, is_ptr = self.type_parser(type)
+ if user_type and 'anonymous ' in full_name:
+ res = [ '%s {' % user_type.kind ]
+ for m in user_type.members:
+ res.extend('\t' + q + ';' for q in m.full_name.splitlines())
+ res.append('}')
+ full_name = raw_full_name = '\n'.join(res)
+ v = type_info(full_name, raw_full_name, user_type, is_ptr)
+ self.types_cache[type.spelling] = v
+ return v
+
+ def construct_argument(self, arg):
+ name = arg.spelling
+ tp = self.construct_type(arg.type)
+
+ def get(type_name):
+ i = type_name.find('(*)')
+ if i >= 0:
+ return type_name[:i].strip() + ' (*' + name + ')' + type_name[i+3:].strip()
+ i = type_name.find('[')
+ if i >= 0:
+ return type_name[:i].strip() + ' ' + name + type_name[i:].strip()
+ else:
+ return type_name + ' ' + name
+
+ full_name = get(tp.full_name)
+ raw_full_name = get(tp.raw_full_name)
+ return argument(name, full_name, raw_full_name, tp)
+
+ def calculate_usr(self, node, real_name):
+ usr = node.get_usr()
+ name = node.spelling
+ if not name:
+ assert node.is_definition()
+ loc = location(node)
+ usr = usr, loc.file, loc.line, loc.column
+ if real_name:
+ name = real_name
+ return name, usr
+
+ def construct_struct(self, node, real_name=None):
+ if type(node) is clang.cindex.Type:
+ t = node
+ node = node.get_declaration()
+ assert node is not None, t.spelling
+ orig_loc = location(node)
+ node_def = node.get_definition()
+ definition = node_def is not None and node_def is not node
+ if definition:
+ node = node_def
+ name, usr = self.calculate_usr(node, real_name)
+ if 'anonymous ' in name:
+ assert False, name
+
+ s = self.structs.get(usr, None)
+ if s is None:
+ if usr and 'test_e' in usr[0]:
+ pass
+ members = []
+ kind = {
+ CursorKind.STRUCT_DECL: 'struct',
+ CursorKind.UNION_DECL: 'union',
+ CursorKind.ENUM_DECL: 'enum',
+ }[node.kind]
+ s = struct(name, name, usr, members, kind, typedefed=real_name)
+ self.structs[usr] = s
+ if kind == 'enum':
+ s.used = set()
+ if real_name:
+ assert not s.typedefed or s.typedefed == real_name
+ s.typedefed = real_name
+ if definition and s.members is not None and not s.members:
+ members = s.members
+ if s.kind != 'enum':
+ s.members = None
+ for f in node.type.get_fields():
+ a = self.construct_argument(f)
+ members.append(a)
+ s.members = members
+ if definition:
+ loc = location(node)
+ s.add_location(loc, False)
+ if orig_loc.file and orig_loc.file != self.source_file:
+ inc = self.basic_include_map_cache[orig_loc.file]
+ else:
+ inc = None
+ s.add_location(orig_loc, True, include=inc)
+ return s
+
+ def construct_function(self, node):
+ orig_loc = location(node)
+ node_def = node.get_definition()
+ definition = node_def is not None and node_def is not node
+ if definition:
+ node = node_def
+
+ func_name, usr = self.calculate_usr(node, None)
+ f = self.functions.get(usr, None)
+ if f is None:
+ args = []
+ for a in node.get_arguments():
+ args.append(self.construct_argument(a))
+ return_type = self.construct_type(node.result_type)
+ is_variadic = node.type.kind == TypeKind.FUNCTIONPROTO and node.type.is_function_variadic()
+
+ lst = [ return_type.full_name, ' ', func_name, '(' ]
+ raw_lst = [ return_type.raw_full_name, ' ', func_name, '(' ]
+ first = True
+ for a in args:
+ if first:
+ first = False
+ else:
+ lst.append(', ')
+ raw_lst.append(', ')
+ lst.append(a.full_name)
+ raw_lst.append(a.raw_full_name)
+ if is_variadic:
+ assert not first
+ lst.append(', ...')
+ raw_lst.append(', ...')
+ lst.append(')')
+ raw_lst.append(')')
+ full_name = ''.join(lst)
+ raw_full_name = ''.join(raw_lst)
+
+ f = function(func_name, full_name, raw_full_name, usr, args, return_type, is_variadic)
+ self.functions[usr] = f
+ if definition:
+ loc = location(node)
+ f.add_location(loc, False)
+ if orig_loc.file and orig_loc.file != self.source_file:
+ inc = self.basic_include_map_cache[orig_loc.file]
+ else:
+ inc = None
+ f.add_location(orig_loc, True, include=inc)
+ if (node_def and node_def.storage_class == clang.cindex.StorageClass.STATIC) or (node and node.storage_class == clang.cindex.StorageClass.STATIC):
+ f.static = True
+ return f
+
+def parse_command_line_for_includes_and_defines(cmd, chroot, clang):
+ if isinstance(cmd, basestring):
+ cmd = shlex.split(cmd)
+
+ clang_dir = os.path.join(os.path.dirname(clang), 'clang')
+ if not os.path.isdir(clang_dir):
+ print('missing directory %s' % clang_dir, file=sys.stderr)
+ sys.exit(1)
+ for f in sorted(os.listdir(clang_dir), reverse=True):
+ f = os.path.join(clang_dir, f, 'include')
+ if os.path.isdir(f):
+ clang_dir2 = f
+ break
+ else:
+ print('missing subdirectory %s/X.Y.Z/include' % clang_dir, file=sys.stderr)
+ sys.exit(1)
+
+ if chroot is not None:
+ chroot = normalize(os.path.expanduser(chroot))
+
+ includes = collections.OrderedDict()
+ defines = collections.OrderedDict()
+ for c in cmd:
+ if c.startswith('-D'):
+ defines[c[2:]] = True
+ elif c.startswith('-Wp,-D'):
+ defines[c[6:]] = True
+ elif not c.startswith('-I') or c == '-I-':
+ continue
+ else:
+ c = c[2:]
+ assert os.path.isabs(c)
+ c = chroot + c
+ c = c.rstrip(os.path.sep).rstrip(os.path.sep + '.')
+ includes[c] = True
+ includes[clang_dir2] = True
+ includes['/usr/include'] = True
+ return list(includes), list(defines)
+
+# def construct_command_line_from_compile_commands(compile_commands):
+# with codecs.open(compile_commands, 'rb', encoding='utf8') as input:
+# cc = json.load(input)
+# cmd = []
+# for entry in cc:
+# cmd.append(entry["command"])
+# return ' '.join(cmd)
+#
+# def get_includes_and_defines_from_args(args):
+# arm_root = args.arm_root
+# includes = args.include
+# command_line = args.command_line
+# clang = args.clang
+# if os.path.isfile(command_line):
+# command_line = construct_command_line_from_compile_commands(command_line)
+# if command_line is not None:
+# incs, defs = parse_command_line_for_includes_and_defines(command_line, arm_root, clang)
+# includes += incs
+# else:
+# defs = []
+# return includes, defs
+
+def p_print_include_paths(args):
+ assert False
+ # includes, _ = get_includes_and_defines_from_args(args)
+ # for p in includes:
+ # print(p)
+
+class clang_parser(object):
+ def __init__(self, includes, defines):
+ self.index = clang.cindex.Index.create()
+ self.parsing_args = [ '-I' + q for q in includes ] + [ '-fsyntax-only' ] + [ '-D' + q for q in defines ]
+ self.includes = includes
+
+ def __call__(self, filename):
+ try:
+ tu = self.index.parse(filename, self.parsing_args, options=clang.cindex.TranslationUnit.PARSE_DETAILED_PROCESSING_RECORD)
+ except Exception as e:
+ raise
+
+ severity_map = { 2: 'warning', 3: 'error', 4: 'error' }
+ for diag in tu.diagnostics:
+ if diag.severity >= 3:
+ loc = diag.location
+ severity = severity_map[diag.severity]
+ opt = '[%s]' % diag.option if diag.option else ''
+ print('%s:%d:%d: %s: %s %s' % (loc.file, loc.line, loc.column, severity, diag.spelling, opt))
+
+ return tu
+
+def yield_commands_from_commands_file(pth, arm_root, clang_path):
+ with codecs.open(pth, 'rb', encoding='utf8') as input:
+ cc = json.load(input)
+ for entry in cc:
+ directory = entry["directory"].rstrip(os.path.sep)
+ command = entry["command"]
+ file = entry["file"].rstrip(os.path.sep)
+
+ assert os.path.isabs(directory), directory
+ assert os.path.isabs(file), file
+
+ includes, defines = parse_command_line_for_includes_and_defines(command, arm_root, clang_path)
+ for i in includes:
+ assert os.path.isabs(i), 'include: ' + i
+
+ yield defines, includes, arm_root + file, arm_root + directory
+
+def run_all_files(defines, commands, arm_root, clang_path):
+ pvis = parsing_visitor()
+
+ def run_file(name):
+ print('%s' % name)
+ source, defs, includes, directory = tmp[name]
+ cp = clang_parser(includes, defs + defines)
+ tu = cp(source)
+ if tu:
+ pvis.process(tu, includes, directory)
+
+ tmp = {}
+ source_files = set()
+ for defs, includes, source, directory in yield_commands_from_commands_file(commands, arm_root, clang_path):
+ assert source.startswith(directory), (source, directory)
+ assert not directory.endswith(os.path.sep)
+ name = source[len(directory)+1:]
+ assert name not in tmp, name
+ tmp[name] = source, defs, includes, directory
+ source_files.add(source)
+ #run_file('src/main.c')
+ for source in sorted(tmp):
+ run_file(source)
+
+ for f in itertools.chain(pvis.functions.values(), pvis.structs.values()):
+ f.is_local_source_file = f.def_location and f.def_location.file in source_files
+
+ return pvis
+
+def p_parse(args):
+ output = args.output
+ clang = args.clang
+ arm_root = normalize(os.path.expanduser(args.arm_root))
+
+ if not os.path.isfile(clang):
+ print('failed to find clang lib (%s)' % clang)
+ sys.exit(1)
+ cc.Config.set_library_file(clang)
+ defines = args.define
+
+ pvis = run_all_files(defines, args.commands, arm_root, clang)
+ data = pvis.functions, pvis.structs, pvis.called_functions, pvis.include_files, arm_root
+ with open(output, 'wb') as out:
+ cPickle.dump(data, out)
+
+forbidden_names_text = 'strlen strrchr strncpy strcmp calloc malloc realloc memset memcpy free _Exit g_logv'
+forbidden_names = set(forbidden_names_text.split())
+
+def calculate_all_called_functions(called_functions):
+ all_called_functions = set()
+ for fncs in called_functions.values():
+ all_called_functions.update(fncs)
+ return all_called_functions
+
+def filter_functions(functions, called_functions, source_files):
+ all_called_functions = calculate_all_called_functions(called_functions)
+ emit_functions = set()
+ for f in functions:
+ if f.name in forbidden_names:
+ continue
+ if f.name.startswith('pthread_'):
+ continue
+ if f.name.startswith('__'):
+ continue
+ if f.is_variadic or f.static:
+ continue
+ if len(f.arguments) > 10:
+ # RC: some macro in googletest cant handle functions with more than 10 arguments
+ continue
+ def_loc = f.def_location
+ if def_loc is not None and not def_loc.is_source:
+ continue
+ emit_functions.add(f)
+ emit_functions2 = sorted(emit_functions, key=lambda x: x.name)
+ emit_functions3 = [q for q in emit_functions2 if q in all_called_functions or (q.def_location and q.def_location.file in source_files)]
+ return emit_functions3
+
+functions_to_emit = []
+def emit(f):
+ functions_to_emit.append(f)
+ return f
+class emitter(object):
+ def __init__(self, path):
+ self.path = path
+ assert not os.path.splitext(path)[1], path
+ self.includes = collections.OrderedDict()
+ self.types = collections.OrderedDict()
+ self.functions = collections.OrderedDict()
+
+ def add_include(self, io, in_header, in_source, extern_c):
+ self.includes[io.included_file_path] = (io, in_header, in_source, extern_c)
+
+ def add_type(self, s):
+ if s in self.types:
+ return True
+ self.types[s] = True
+ return False
+
+ def add_function(self, f, emit_declaration, emit_mock):
+ self.functions[f] = emit_declaration, emit_mock
+
+ @emit
+ def emit_pragma_once(self, header, source):
+ header('#pragma once')
+
+ @emit
+ def emit_includes(self, header, source):
+ in_extern_c = False
+
+ source('#include "%s.h"' % os.path.basename(self.path))
+ for io, h, s, extern_c in self.includes.values():
+ if extern_c and not in_extern_c:
+ header('extern "C" {')
+ in_extern_c = True
+ elif not extern_c and in_extern_c:
+ header('}')
+ in_extern_c = False
+ text = io.include_text
+ if io.is_local_directory:
+ pre = post = '"'
+ else:
+ pre = '<'
+ post = '>'
+
+ if h:
+ header('#include %s%s%s' % (pre, text, post))
+ if s:
+ source('#include %s%s%s' % (pre, text, post))
+ if in_extern_c:
+ header('}')
+
+ @emit
+ def emit_types(self, header, source):
+ for t in self.types:
+ if t.kind != 'enum':
+ if t.name:
+ header('%s%s %s%s;' % ('typedef ' if t.typedefed else '', t.kind, t.name, (' ' + t.typedefed if t.typedefed else '')))
+ else:
+ header('%s%s %s {' % ('typedef ' if t.typedefed else '', t.kind, t.name))
+ for m in t.members:
+ header('\t%s,' % m.full_name)
+ header('}%s;' % (' ' + t.typedefed if t.typedefed else ''))
+
+ done = set()
+ def emit_struct(t, depth=0):
+ header('%s%s %s {' % ('typedef ' if not t.name and t.typedefed else '', t.kind, t.name))
+ depth += 1
+ for m in t.members:
+ lst = m.full_name.splitlines()
+ for x in range(len(lst)):
+ q = ';' if x == len(lst) - 1 else ''
+ header('\t' + lst[x] + q)
+ header('}%s;' % (' ' + t.typedefed if not t.name and t.typedefed else ''))
+
+ def emit(t, depth=0):
+ if t.kind != 'enum' and (not t.name or t.name not in done):
+ done.add(t.name)
+ for m in t.members:
+ if m.type.name and m.type.user_type_if_any and m.type.raw_full_name == m.type.user_type_if_any.raw_full_name:
+ emit(m.type.user_type_if_any, depth + 1)
+ emit_struct(t, depth=depth)
+ return True
+ return False
+ for t in self.types:
+ if t.kind != 'enum' and t.def_location is not None:
+ emit(t)
+
+ @emit
+ def emit_functions(self, header, source):
+ for f, (emit_declaration, emit_mock) in self.functions.items():
+ if emit_declaration:
+ header('extern "C" %s;' % f.full_name)
+
+ for f, (emit_declaration, emit_mock) in self.functions.items():
+ if emit_mock:
+ name = f.name
+ return_type = f.return_type.full_name
+ args = ', '.join(q.type.full_name for q in f.arguments)
+ s = len(f.arguments)
+ header('DECLARE_FUNCTION_MOCK%s(mock_%s, %s, %s(%s));' % ( s, name, name, return_type, args))
+ source('IMPLEMENT_FUNCTION_MOCK%s(mock_%s, %s, %s(%s));' % (s, name, name, return_type, args))
+
+ def emit_all(self):
+ class writter(object):
+ def __init__(self, target):
+ self.file = target
+ self.written = False
+ def __call__(self, txt):
+ print(txt, file=self.file)
+ self.written = True
+ s1 = self.path + '.h'
+ s2 = self.path + '.cpp'
+ with codecs.open(s1, 'wb', encoding='utf8') as header, codecs.open(s2, 'wb', encoding='utf8') as source:
+ h = writter(header)
+ s = writter(source)
+
+ for fnc in functions_to_emit:
+ h.written = s.written = False
+ fnc(self, h, s)
+ if h.written:
+ h('')
+ if s.written:
+ s('')
+ return s1, s2
+
+def remove_unnecessary_files(output, created_files):
+ created_files2 = set(os.path.basename(v) for v in created_files)
+ files_in_dir = set(q for q in os.listdir(output) if q.endswith(('.h', '.cpp')))
+ for x in sorted(files_in_dir - created_files2):
+ f = os.path.join(output, x)
+ if os.path.isfile(f):
+ print('removing unused file %s' % f)
+ os.remove(f)
+
+def generate_external_mock(output, emit_functions, include_files):
+ em = emitter(os.path.join(output, 'mocked_external'))
+
+ di = set()
+ for _, external_includes, _ in include_files.values():
+ for d in external_includes.values():
+ assert not d.is_local_directory, d.include_text
+ q = d.include_text
+ if q not in di:
+ di.add(q)
+ em.add_include(d, True, False, True)
+
+ for f in emit_functions:
+ if f.def_location and f.def_location.is_local_directory:
+ continue
+ if not f.includes:
+ print('warning: non-declared function %s called (c allows this), the function wont be mocked' % f.full_name)
+ assert not f.def_location
+ continue
+ assert f.includes, (f.full_name, f.def_location)
+ em.add_function(f, False, True)
+ em.add_include(include_info('cmock/cmock.h', '', ['cmock/cmock.h']), True, False, False)
+ return em.emit_all()
+
+def generate_source_file(output, emit_functions, src, include_files):
+ name = os.path.basename(src)
+ name2 = os.path.splitext(name)[0]
+ em = emitter(os.path.join(output, 'mocked_' + name2))
+ direct_includes, _, _ = include_files[src]
+ direct_includes_set = set()
+ for d in direct_includes.values():
+ em.add_include(d, True, False, True)
+ direct_includes_set.add(d.included_file_path)
+
+ def use(s):
+ if s is None:
+ return False
+ if s.name.startswith('__'):
+ return False
+ if not s.def_location:
+ return False
+ return True
+ def add_type(s):
+ if s.name or s.typedefed:
+ s2 = s.user_type_if_any
+ if use(s2) and s2.def_location.file == src:
+ v = em.add_type(s2)
+ if not v and s2.kind != 'enum':
+ for m in s2.members:
+ add_type(m.type)
+ def use_f(f):
+ if f.def_location.file == src:
+ return True
+ for q in f.includes.values():
+ if q.included_file_path in direct_includes_set:
+ return True
+ return False
+ for f in emit_functions:
+ if use(f) and use_f(f):
+ for s in itertools.chain((f.return_type, ), (q.type for q in f.arguments)):
+ add_type(s)
+ em.add_function(f, f.hidden, True)
+ em.add_include(include_info('cmock/cmock.h', '', ['cmock/cmock.h']), True, False, False)
+ return em.emit_all()
+
+def generate_source_files(output, emit_functions, include_files):
+ created_files = []
+
+ def proc(src):
+ print(src)
+ created_files.extend(generate_source_file(output, emit_functions, src, include_files))
+
+ #proc('/home/r.cybulski/GBS-ROOT/local/BUILD-ROOTS/scratch.armv7l.0/home/abuild/rpmbuild/BUILD/org.tizen.screen-reader-0.0.8/src/screen_reader_vconf.c')
+ #sys.exit(1)
+ for src in sorted(include_files):
+ proc(src)
+
+ return created_files
+
+def p_generate(args):
+ with open(args.input, 'rb') as inp:
+ functions, structs, called_functions, include_files, arm_root = cPickle.load(inp)
+ output = args.output
+
+ emit_functions = filter_functions(functions.values(), called_functions, set(include_files))
+
+ created_files = generate_source_files(output, emit_functions, include_files)
+ created_files.extend(generate_external_mock(output, emit_functions, include_files))
+
+ remove_unnecessary_files(output, created_files)
+
+main_parser = argparse.ArgumentParser(description='(Re)Generate stubs for C tests.')
+subparsers = main_parser.add_subparsers()
+parser = subparsers.add_parser('parse', help='parses source files and builds rtti structures')
+parser.add_argument('--clang', default=r'/usr/lib/llvm-3.8/lib/libclang.so', required=False, help='path to clang libclang.so library')
+parser.add_argument('--output', required=True, help='path to output file with rtti structures')
+parser.add_argument('--commands', required=True, help='path to compile_commands.json created via SET(CMAKE_VERBOSE_MAKEFILE "ON") in CMake')
+parser.add_argument('--define', default=[], nargs='*', help='values to define (-D will be added by script)')
+parser.add_argument('--arm-root', default=r'~/GBS-ROOT/local/BUILD-ROOTS/scratch.armv7l.0', required=False, help='path to arm root, usually default (~/GBS-ROOT/local/BUILD-ROOTS/scratch.armv7l.0) works')
+parser.set_defaults(func=p_parse)
+
+parser = subparsers.add_parser('generate', help='generates tests stubs based upon rtti structures')
+parser.add_argument('--output', required=True, help='output directory to put files in')
+parser.add_argument('--input', required=True, help='path to file with rtti structures generated via parse command')
+parser.set_defaults(func=p_generate)
+
+parser = subparsers.add_parser('print-include-paths', help='prints absolute include paths used')
+parser.add_argument('root', help='path to root project')
+parser.add_argument('--clang', default=r'/usr/lib/llvm-3.8/lib/libclang.so', required=False, help='path to clang libclang.so library')
+parser.add_argument('--commands', required=True, help='path to compile_commands.json created via SET(CMAKE_VERBOSE_MAKEFILE "ON") in CMake')
+parser.add_argument('--arm-root', default=r'~/GBS-ROOT/local/BUILD-ROOTS/scratch.armv7l.0', required=False, help='path to arm root, usually default (~/GBS-ROOT/local/BUILD-ROOTS/scratch.armv7l.0) works')
+parser.set_defaults(func=p_print_include_paths)
+
+args = main_parser.parse_args()
+args.func(args)
--- /dev/null
+#include "mocked_app_tracker.h"
+
+IMPLEMENT_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK3(mock_app_tracker_at_point_window_get, app_tracker_at_point_window_get, AtspiAccessible *(App_Tracker_Data *, int, int));
+IMPLEMENT_FUNCTION_MOCK1(mock_app_tracker_context_valid_check, app_tracker_context_valid_check, AppTrackerContextValidility(App_Tracker_Data *));
+IMPLEMENT_FUNCTION_MOCK2(mock_app_tracker_init, app_tracker_init, App_Tracker_Data *(AppTrackerEventWithDefaultLabelInfoCB, NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK3(mock_app_tracker_new_obj_highlighted_callback_register, app_tracker_new_obj_highlighted_callback_register, void(App_Tracker_Data *, AppTrackerEventCB, void *));
+IMPLEMENT_FUNCTION_MOCK1(mock_app_tracker_new_obj_highlighted_callback_unregister, app_tracker_new_obj_highlighted_callback_unregister, void *(App_Tracker_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_app_tracker_scroll_gesture_required_object_info_send, app_tracker_scroll_gesture_required_object_info_send, void(App_Tracker_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_app_tracker_shutdown, app_tracker_shutdown, void(App_Tracker_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_app_tracker_top_window_get, app_tracker_top_window_get, AtspiAccessible *(App_Tracker_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_app_tracker_top_window_info_get, app_tracker_top_window_info_get, WindowInfo *(App_Tracker_Data *));
+IMPLEMENT_FUNCTION_MOCK2(mock_cycle_detection_check_if_in_cycle, cycle_detection_check_if_in_cycle, Eina_Bool(cycle_detection_data *, const void *));
+IMPLEMENT_FUNCTION_MOCK2(mock_cycle_detection_initialize, cycle_detection_initialize, void(cycle_detection_data *, const void *));
+IMPLEMENT_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+IMPLEMENT_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK3(mock_generate_what_to_read_and_speak, generate_what_to_read_and_speak, void(NavigatorData *, AtspiAccessible *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK2(mock_get_accuracy, get_accuracy, int(double, int));
+IMPLEMENT_FUNCTION_MOCK1(mock_get_objects_attributes, get_objects_attributes, unsigned short(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK0(mock_get_pointer_to_service_data_struct, get_pointer_to_service_data_struct, Service_Data *());
+IMPLEMENT_FUNCTION_MOCK0(mock_granularity_read_data_get, granularity_read_data_get, Granularity_Read_Data *());
+IMPLEMENT_FUNCTION_MOCK0(mock_granularity_read_init, granularity_read_init, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_granularity_read_terminate, granularity_read_terminate, void());
+IMPLEMENT_FUNCTION_MOCK2(mock_granularity_read_text_get, granularity_read_text_get, char *(AtspiAccessible *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK0(mock_granularity_read_text_list_init, granularity_read_text_list_init, void());
+IMPLEMENT_FUNCTION_MOCK1(mock_granularity_read_type_set, granularity_read_type_set, void(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK0(mock_granularity_read_ui_popup_show, granularity_read_ui_popup_show, void());
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_focus_next_visible, navigator_focus_next_visible, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_focus_prev_visible, navigator_focus_prev_visible, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_flat_navi_context, navigator_get_flat_navi_context, FlatNaviContext *(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_ignore_keyboard_feedback, navigator_get_ignore_keyboard_feedback, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_is_text_selection_mode, navigator_get_is_text_selection_mode, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK0(mock_navigator_init, navigator_init, NavigatorData *());
+IMPLEMENT_FUNCTION_MOCK2(mock_navigator_set_ignore_keyboard_feedback, navigator_set_ignore_keyboard_feedback, void(NavigatorData *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK4(mock_navigator_set_read_quickpanel_cb, navigator_set_read_quickpanel_cb, void(NavigatorData *, read_quickpanel_cb_t, void *, read_quickpanel_cb_t));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_shutdown, navigator_shutdown, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_defunct_state, object_has_defunct_state, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_highlighted_state, object_has_highlighted_state, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_modal_role, object_has_modal_role, Eina_Bool(AtspiRole));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_data_free, reading_composer_data_free, void(ReadingComposerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_data_get, reading_composer_data_get, ReadingComposerData *(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_description_get, reading_composer_description_get, char *(ReadingComposerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_extended_description_get, reading_composer_extended_description_get, char *(ReadingComposerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_name_get, reading_composer_name_get, char *(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_create_service, screen_reader_create_service, int(Service_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_terminate_service, screen_reader_terminate_service, int(Service_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_ui_launch, screen_reader_ui_launch, void(const char *));
+IMPLEMENT_FUNCTION_MOCK0(mock_screen_reader_ui_terminate, screen_reader_ui_terminate, void());
+IMPLEMENT_FUNCTION_MOCK1(mock_sound_n_vibration_feedback_generate, sound_n_vibration_feedback_generate, void(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK0(mock_spi_init, spi_init, SpiData *());
+IMPLEMENT_FUNCTION_MOCK1(mock_spi_shutdown, spi_shutdown, void(SpiData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_symbol_lookup, symbol_lookup, const gchar *(const gchar *));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_init, tw_init, _Bool());
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_pause_get, tw_pause_get, Eina_Bool());
+IMPLEMENT_FUNCTION_MOCK1(mock_tw_pause_set, tw_pause_set, Eina_Bool(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK1(mock_tw_purge, tw_purge, void(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK3(mock_tw_set_utterance_cb, tw_set_utterance_cb, void(utterance_cb_t, void *, utterance_cb_t));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_shutdown, tw_shutdown, void());
+IMPLEMENT_FUNCTION_MOCK2(mock_tw_speak, tw_speak, Read_Command *(char *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK5(mock_tw_speak_customized, tw_speak_customized, Read_Command *(char *, Eina_Bool, Eina_Bool, AtspiAccessible *, unsigned int));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_stop_set, tw_stop_set, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_utils_a11y_bus_connection_get, utils_a11y_bus_connection_get, Eldbus_Connection *());
+IMPLEMENT_FUNCTION_MOCK1(mock_utils_a11y_bus_connection_set, utils_a11y_bus_connection_set, void(Eldbus_Connection *));
+IMPLEMENT_FUNCTION_MOCK1(mock_utils_enum_to_string, utils_enum_to_string, const char *(Gesture));
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_exit, vc_exit, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_haptic, vc_get_haptic, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_keyboard_feedback, vc_get_keyboard_feedback, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_lcd_backlight_timeout, vc_get_lcd_backlight_timeout, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_read_description, vc_get_read_description, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_sound_feedback, vc_get_sound_feedback, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_init, vc_init, void());
+IMPLEMENT_FUNCTION_MOCK1(mock_window_tracker_active_window_request, window_tracker_active_window_request, void(WindowTrackerData *));
+IMPLEMENT_FUNCTION_MOCK3(mock_window_tracker_at_point_window_get, window_tracker_at_point_window_get, AtspiAccessible *(WindowTrackerData *, int, int));
+IMPLEMENT_FUNCTION_MOCK0(mock_window_tracker_init, window_tracker_init, WindowTrackerData *());
+IMPLEMENT_FUNCTION_MOCK1(mock_window_tracker_keyboard_window_append, window_tracker_keyboard_window_append, void(WindowTrackerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_window_tracker_keyboard_window_remove, window_tracker_keyboard_window_remove, void(WindowTrackerData *));
+IMPLEMENT_FUNCTION_MOCK3(mock_window_tracker_register, window_tracker_register, void(WindowTrackerData *, WindowTrackerCb, void *));
+IMPLEMENT_FUNCTION_MOCK1(mock_window_tracker_shutdown, window_tracker_shutdown, void(WindowTrackerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_window_tracker_subroot_get, window_tracker_subroot_get, AtspiAccessible *(WindowTrackerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_window_tracker_top_win_get, window_tracker_top_win_get, AtspiAccessible *(WindowTrackerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_window_tracker_top_window_get, window_tracker_top_window_get, AtspiAccessible *(WindowTrackerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_window_tracker_top_window_info_get, window_tracker_top_window_info_get, WindowInfo *(WindowTrackerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_window_tracker_unregister, window_tracker_unregister, void *(WindowTrackerData *));
+IMPLEMENT_FUNCTION_MOCK2(mock_window_tracker_window_activate_info_type_get, window_tracker_window_activate_info_type_get, WindowActivateInfoType(WindowTrackerData *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK3(mock_window_tracker_window_append, window_tracker_window_append, void(WindowTrackerData *, AtspiAccessible *, AtspiRole));
+IMPLEMENT_FUNCTION_MOCK2(mock_window_tracker_window_remove, window_tracker_window_remove, void(WindowTrackerData *, AtspiAccessible *));
+
--- /dev/null
+#pragma once
+
+extern "C" {
+#include <ctype.h>
+#include "app_tracker.h"
+#include "logger.h"
+#include "reading_composer.h"
+#include "screen_reader_tts.h"
+#include "screen_reader_vconf.h"
+#include "symbols.h"
+#include "utils.h"
+#include "window_tracker.h"
+#include "granularity_read.h"
+}
+#include <cmock/cmock.h>
+
+DECLARE_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK3(mock_app_tracker_at_point_window_get, app_tracker_at_point_window_get, AtspiAccessible *(App_Tracker_Data *, int, int));
+DECLARE_FUNCTION_MOCK1(mock_app_tracker_context_valid_check, app_tracker_context_valid_check, AppTrackerContextValidility(App_Tracker_Data *));
+DECLARE_FUNCTION_MOCK2(mock_app_tracker_init, app_tracker_init, App_Tracker_Data *(AppTrackerEventWithDefaultLabelInfoCB, NavigatorData *));
+DECLARE_FUNCTION_MOCK3(mock_app_tracker_new_obj_highlighted_callback_register, app_tracker_new_obj_highlighted_callback_register, void(App_Tracker_Data *, AppTrackerEventCB, void *));
+DECLARE_FUNCTION_MOCK1(mock_app_tracker_new_obj_highlighted_callback_unregister, app_tracker_new_obj_highlighted_callback_unregister, void *(App_Tracker_Data *));
+DECLARE_FUNCTION_MOCK1(mock_app_tracker_scroll_gesture_required_object_info_send, app_tracker_scroll_gesture_required_object_info_send, void(App_Tracker_Data *));
+DECLARE_FUNCTION_MOCK1(mock_app_tracker_shutdown, app_tracker_shutdown, void(App_Tracker_Data *));
+DECLARE_FUNCTION_MOCK1(mock_app_tracker_top_window_get, app_tracker_top_window_get, AtspiAccessible *(App_Tracker_Data *));
+DECLARE_FUNCTION_MOCK1(mock_app_tracker_top_window_info_get, app_tracker_top_window_info_get, WindowInfo *(App_Tracker_Data *));
+DECLARE_FUNCTION_MOCK2(mock_cycle_detection_check_if_in_cycle, cycle_detection_check_if_in_cycle, Eina_Bool(cycle_detection_data *, const void *));
+DECLARE_FUNCTION_MOCK2(mock_cycle_detection_initialize, cycle_detection_initialize, void(cycle_detection_data *, const void *));
+DECLARE_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+DECLARE_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK3(mock_generate_what_to_read_and_speak, generate_what_to_read_and_speak, void(NavigatorData *, AtspiAccessible *, Eina_Bool));
+DECLARE_FUNCTION_MOCK2(mock_get_accuracy, get_accuracy, int(double, int));
+DECLARE_FUNCTION_MOCK1(mock_get_objects_attributes, get_objects_attributes, unsigned short(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK0(mock_get_pointer_to_service_data_struct, get_pointer_to_service_data_struct, Service_Data *());
+DECLARE_FUNCTION_MOCK0(mock_granularity_read_data_get, granularity_read_data_get, Granularity_Read_Data *());
+DECLARE_FUNCTION_MOCK0(mock_granularity_read_init, granularity_read_init, void());
+DECLARE_FUNCTION_MOCK0(mock_granularity_read_terminate, granularity_read_terminate, void());
+DECLARE_FUNCTION_MOCK2(mock_granularity_read_text_get, granularity_read_text_get, char *(AtspiAccessible *, Eina_Bool));
+DECLARE_FUNCTION_MOCK0(mock_granularity_read_text_list_init, granularity_read_text_list_init, void());
+DECLARE_FUNCTION_MOCK1(mock_granularity_read_type_set, granularity_read_type_set, void(Eina_Bool));
+DECLARE_FUNCTION_MOCK0(mock_granularity_read_ui_popup_show, granularity_read_ui_popup_show, void());
+DECLARE_FUNCTION_MOCK1(mock_navigator_focus_next_visible, navigator_focus_next_visible, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_focus_prev_visible, navigator_focus_prev_visible, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_flat_navi_context, navigator_get_flat_navi_context, FlatNaviContext *(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_ignore_keyboard_feedback, navigator_get_ignore_keyboard_feedback, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_is_text_selection_mode, navigator_get_is_text_selection_mode, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK0(mock_navigator_init, navigator_init, NavigatorData *());
+DECLARE_FUNCTION_MOCK2(mock_navigator_set_ignore_keyboard_feedback, navigator_set_ignore_keyboard_feedback, void(NavigatorData *, Eina_Bool));
+DECLARE_FUNCTION_MOCK4(mock_navigator_set_read_quickpanel_cb, navigator_set_read_quickpanel_cb, void(NavigatorData *, read_quickpanel_cb_t, void *, read_quickpanel_cb_t));
+DECLARE_FUNCTION_MOCK1(mock_navigator_shutdown, navigator_shutdown, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_defunct_state, object_has_defunct_state, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_highlighted_state, object_has_highlighted_state, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_modal_role, object_has_modal_role, Eina_Bool(AtspiRole));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_data_free, reading_composer_data_free, void(ReadingComposerData *));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_data_get, reading_composer_data_get, ReadingComposerData *(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_description_get, reading_composer_description_get, char *(ReadingComposerData *));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_extended_description_get, reading_composer_extended_description_get, char *(ReadingComposerData *));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_name_get, reading_composer_name_get, char *(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_create_service, screen_reader_create_service, int(Service_Data *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_terminate_service, screen_reader_terminate_service, int(Service_Data *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_ui_launch, screen_reader_ui_launch, void(const char *));
+DECLARE_FUNCTION_MOCK0(mock_screen_reader_ui_terminate, screen_reader_ui_terminate, void());
+DECLARE_FUNCTION_MOCK1(mock_sound_n_vibration_feedback_generate, sound_n_vibration_feedback_generate, void(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK0(mock_spi_init, spi_init, SpiData *());
+DECLARE_FUNCTION_MOCK1(mock_spi_shutdown, spi_shutdown, void(SpiData *));
+DECLARE_FUNCTION_MOCK1(mock_symbol_lookup, symbol_lookup, const gchar *(const gchar *));
+DECLARE_FUNCTION_MOCK0(mock_tw_init, tw_init, _Bool());
+DECLARE_FUNCTION_MOCK0(mock_tw_pause_get, tw_pause_get, Eina_Bool());
+DECLARE_FUNCTION_MOCK1(mock_tw_pause_set, tw_pause_set, Eina_Bool(Eina_Bool));
+DECLARE_FUNCTION_MOCK1(mock_tw_purge, tw_purge, void(Eina_Bool));
+DECLARE_FUNCTION_MOCK3(mock_tw_set_utterance_cb, tw_set_utterance_cb, void(utterance_cb_t, void *, utterance_cb_t));
+DECLARE_FUNCTION_MOCK0(mock_tw_shutdown, tw_shutdown, void());
+DECLARE_FUNCTION_MOCK2(mock_tw_speak, tw_speak, Read_Command *(char *, Eina_Bool));
+DECLARE_FUNCTION_MOCK5(mock_tw_speak_customized, tw_speak_customized, Read_Command *(char *, Eina_Bool, Eina_Bool, AtspiAccessible *, unsigned int));
+DECLARE_FUNCTION_MOCK0(mock_tw_stop_set, tw_stop_set, void());
+DECLARE_FUNCTION_MOCK0(mock_utils_a11y_bus_connection_get, utils_a11y_bus_connection_get, Eldbus_Connection *());
+DECLARE_FUNCTION_MOCK1(mock_utils_a11y_bus_connection_set, utils_a11y_bus_connection_set, void(Eldbus_Connection *));
+DECLARE_FUNCTION_MOCK1(mock_utils_enum_to_string, utils_enum_to_string, const char *(Gesture));
+DECLARE_FUNCTION_MOCK0(mock_vc_exit, vc_exit, void());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_haptic, vc_get_haptic, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_keyboard_feedback, vc_get_keyboard_feedback, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_lcd_backlight_timeout, vc_get_lcd_backlight_timeout, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_read_description, vc_get_read_description, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_sound_feedback, vc_get_sound_feedback, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_init, vc_init, void());
+DECLARE_FUNCTION_MOCK1(mock_window_tracker_active_window_request, window_tracker_active_window_request, void(WindowTrackerData *));
+DECLARE_FUNCTION_MOCK3(mock_window_tracker_at_point_window_get, window_tracker_at_point_window_get, AtspiAccessible *(WindowTrackerData *, int, int));
+DECLARE_FUNCTION_MOCK0(mock_window_tracker_init, window_tracker_init, WindowTrackerData *());
+DECLARE_FUNCTION_MOCK1(mock_window_tracker_keyboard_window_append, window_tracker_keyboard_window_append, void(WindowTrackerData *));
+DECLARE_FUNCTION_MOCK1(mock_window_tracker_keyboard_window_remove, window_tracker_keyboard_window_remove, void(WindowTrackerData *));
+DECLARE_FUNCTION_MOCK3(mock_window_tracker_register, window_tracker_register, void(WindowTrackerData *, WindowTrackerCb, void *));
+DECLARE_FUNCTION_MOCK1(mock_window_tracker_shutdown, window_tracker_shutdown, void(WindowTrackerData *));
+DECLARE_FUNCTION_MOCK1(mock_window_tracker_subroot_get, window_tracker_subroot_get, AtspiAccessible *(WindowTrackerData *));
+DECLARE_FUNCTION_MOCK1(mock_window_tracker_top_win_get, window_tracker_top_win_get, AtspiAccessible *(WindowTrackerData *));
+DECLARE_FUNCTION_MOCK1(mock_window_tracker_top_window_get, window_tracker_top_window_get, AtspiAccessible *(WindowTrackerData *));
+DECLARE_FUNCTION_MOCK1(mock_window_tracker_top_window_info_get, window_tracker_top_window_info_get, WindowInfo *(WindowTrackerData *));
+DECLARE_FUNCTION_MOCK1(mock_window_tracker_unregister, window_tracker_unregister, void *(WindowTrackerData *));
+DECLARE_FUNCTION_MOCK2(mock_window_tracker_window_activate_info_type_get, window_tracker_window_activate_info_type_get, WindowActivateInfoType(WindowTrackerData *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK3(mock_window_tracker_window_append, window_tracker_window_append, void(WindowTrackerData *, AtspiAccessible *, AtspiRole));
+DECLARE_FUNCTION_MOCK2(mock_window_tracker_window_remove, window_tracker_window_remove, void(WindowTrackerData *, AtspiAccessible *));
+
--- /dev/null
+#include "mocked_dbus_direct_reading_adapter.h"
+
+IMPLEMENT_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK2(mock_cycle_detection_check_if_in_cycle, cycle_detection_check_if_in_cycle, Eina_Bool(cycle_detection_data *, const void *));
+IMPLEMENT_FUNCTION_MOCK2(mock_cycle_detection_initialize, cycle_detection_initialize, void(cycle_detection_data *, const void *));
+IMPLEMENT_FUNCTION_MOCK3(mock_dbus_direct_reading_adapter_emit, dbus_direct_reading_adapter_emit, int(Reading_Adapter_Data *, const Signal, const void *));
+IMPLEMENT_FUNCTION_MOCK0(mock_dbus_direct_reading_init, dbus_direct_reading_init, Reading_Adapter_Data *());
+IMPLEMENT_FUNCTION_MOCK1(mock_dbus_direct_reading_shutdown, dbus_direct_reading_shutdown, void(Reading_Adapter_Data *));
+IMPLEMENT_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+IMPLEMENT_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK3(mock_generate_what_to_read_and_speak, generate_what_to_read_and_speak, void(NavigatorData *, AtspiAccessible *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK2(mock_get_accuracy, get_accuracy, int(double, int));
+IMPLEMENT_FUNCTION_MOCK1(mock_get_objects_attributes, get_objects_attributes, unsigned short(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK0(mock_get_pointer_to_service_data_struct, get_pointer_to_service_data_struct, Service_Data *());
+IMPLEMENT_FUNCTION_MOCK1(mock_get_signal_name, get_signal_name, const char *(const Signal));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_focus_next_visible, navigator_focus_next_visible, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_focus_prev_visible, navigator_focus_prev_visible, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_flat_navi_context, navigator_get_flat_navi_context, FlatNaviContext *(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_ignore_keyboard_feedback, navigator_get_ignore_keyboard_feedback, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_is_text_selection_mode, navigator_get_is_text_selection_mode, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK0(mock_navigator_init, navigator_init, NavigatorData *());
+IMPLEMENT_FUNCTION_MOCK2(mock_navigator_set_ignore_keyboard_feedback, navigator_set_ignore_keyboard_feedback, void(NavigatorData *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK4(mock_navigator_set_read_quickpanel_cb, navigator_set_read_quickpanel_cb, void(NavigatorData *, read_quickpanel_cb_t, void *, read_quickpanel_cb_t));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_shutdown, navigator_shutdown, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_defunct_state, object_has_defunct_state, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_highlighted_state, object_has_highlighted_state, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_modal_role, object_has_modal_role, Eina_Bool(AtspiRole));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_create_service, screen_reader_create_service, int(Service_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_terminate_service, screen_reader_terminate_service, int(Service_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_ui_launch, screen_reader_ui_launch, void(const char *));
+IMPLEMENT_FUNCTION_MOCK0(mock_screen_reader_ui_terminate, screen_reader_ui_terminate, void());
+IMPLEMENT_FUNCTION_MOCK1(mock_sound_n_vibration_feedback_generate, sound_n_vibration_feedback_generate, void(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK0(mock_spi_init, spi_init, SpiData *());
+IMPLEMENT_FUNCTION_MOCK1(mock_spi_shutdown, spi_shutdown, void(SpiData *));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_init, tw_init, _Bool());
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_pause_get, tw_pause_get, Eina_Bool());
+IMPLEMENT_FUNCTION_MOCK1(mock_tw_pause_set, tw_pause_set, Eina_Bool(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK1(mock_tw_purge, tw_purge, void(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK3(mock_tw_set_utterance_cb, tw_set_utterance_cb, void(utterance_cb_t, void *, utterance_cb_t));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_shutdown, tw_shutdown, void());
+IMPLEMENT_FUNCTION_MOCK2(mock_tw_speak, tw_speak, Read_Command *(char *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK5(mock_tw_speak_customized, tw_speak_customized, Read_Command *(char *, Eina_Bool, Eina_Bool, AtspiAccessible *, unsigned int));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_stop_set, tw_stop_set, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_utils_a11y_bus_connection_get, utils_a11y_bus_connection_get, Eldbus_Connection *());
+IMPLEMENT_FUNCTION_MOCK1(mock_utils_a11y_bus_connection_set, utils_a11y_bus_connection_set, void(Eldbus_Connection *));
+IMPLEMENT_FUNCTION_MOCK1(mock_utils_enum_to_string, utils_enum_to_string, const char *(Gesture));
+
--- /dev/null
+#pragma once
+
+extern "C" {
+#include "dbus_direct_reading_adapter.h"
+#include "screen_reader_tts.h"
+#include "logger.h"
+#include "utils.h"
+#include <assert.h>
+}
+#include <cmock/cmock.h>
+
+DECLARE_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK2(mock_cycle_detection_check_if_in_cycle, cycle_detection_check_if_in_cycle, Eina_Bool(cycle_detection_data *, const void *));
+DECLARE_FUNCTION_MOCK2(mock_cycle_detection_initialize, cycle_detection_initialize, void(cycle_detection_data *, const void *));
+DECLARE_FUNCTION_MOCK3(mock_dbus_direct_reading_adapter_emit, dbus_direct_reading_adapter_emit, int(Reading_Adapter_Data *, const Signal, const void *));
+DECLARE_FUNCTION_MOCK0(mock_dbus_direct_reading_init, dbus_direct_reading_init, Reading_Adapter_Data *());
+DECLARE_FUNCTION_MOCK1(mock_dbus_direct_reading_shutdown, dbus_direct_reading_shutdown, void(Reading_Adapter_Data *));
+DECLARE_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+DECLARE_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK3(mock_generate_what_to_read_and_speak, generate_what_to_read_and_speak, void(NavigatorData *, AtspiAccessible *, Eina_Bool));
+DECLARE_FUNCTION_MOCK2(mock_get_accuracy, get_accuracy, int(double, int));
+DECLARE_FUNCTION_MOCK1(mock_get_objects_attributes, get_objects_attributes, unsigned short(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK0(mock_get_pointer_to_service_data_struct, get_pointer_to_service_data_struct, Service_Data *());
+DECLARE_FUNCTION_MOCK1(mock_get_signal_name, get_signal_name, const char *(const Signal));
+DECLARE_FUNCTION_MOCK1(mock_navigator_focus_next_visible, navigator_focus_next_visible, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_focus_prev_visible, navigator_focus_prev_visible, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_flat_navi_context, navigator_get_flat_navi_context, FlatNaviContext *(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_ignore_keyboard_feedback, navigator_get_ignore_keyboard_feedback, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_is_text_selection_mode, navigator_get_is_text_selection_mode, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK0(mock_navigator_init, navigator_init, NavigatorData *());
+DECLARE_FUNCTION_MOCK2(mock_navigator_set_ignore_keyboard_feedback, navigator_set_ignore_keyboard_feedback, void(NavigatorData *, Eina_Bool));
+DECLARE_FUNCTION_MOCK4(mock_navigator_set_read_quickpanel_cb, navigator_set_read_quickpanel_cb, void(NavigatorData *, read_quickpanel_cb_t, void *, read_quickpanel_cb_t));
+DECLARE_FUNCTION_MOCK1(mock_navigator_shutdown, navigator_shutdown, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_defunct_state, object_has_defunct_state, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_highlighted_state, object_has_highlighted_state, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_modal_role, object_has_modal_role, Eina_Bool(AtspiRole));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_create_service, screen_reader_create_service, int(Service_Data *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_terminate_service, screen_reader_terminate_service, int(Service_Data *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_ui_launch, screen_reader_ui_launch, void(const char *));
+DECLARE_FUNCTION_MOCK0(mock_screen_reader_ui_terminate, screen_reader_ui_terminate, void());
+DECLARE_FUNCTION_MOCK1(mock_sound_n_vibration_feedback_generate, sound_n_vibration_feedback_generate, void(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK0(mock_spi_init, spi_init, SpiData *());
+DECLARE_FUNCTION_MOCK1(mock_spi_shutdown, spi_shutdown, void(SpiData *));
+DECLARE_FUNCTION_MOCK0(mock_tw_init, tw_init, _Bool());
+DECLARE_FUNCTION_MOCK0(mock_tw_pause_get, tw_pause_get, Eina_Bool());
+DECLARE_FUNCTION_MOCK1(mock_tw_pause_set, tw_pause_set, Eina_Bool(Eina_Bool));
+DECLARE_FUNCTION_MOCK1(mock_tw_purge, tw_purge, void(Eina_Bool));
+DECLARE_FUNCTION_MOCK3(mock_tw_set_utterance_cb, tw_set_utterance_cb, void(utterance_cb_t, void *, utterance_cb_t));
+DECLARE_FUNCTION_MOCK0(mock_tw_shutdown, tw_shutdown, void());
+DECLARE_FUNCTION_MOCK2(mock_tw_speak, tw_speak, Read_Command *(char *, Eina_Bool));
+DECLARE_FUNCTION_MOCK5(mock_tw_speak_customized, tw_speak_customized, Read_Command *(char *, Eina_Bool, Eina_Bool, AtspiAccessible *, unsigned int));
+DECLARE_FUNCTION_MOCK0(mock_tw_stop_set, tw_stop_set, void());
+DECLARE_FUNCTION_MOCK0(mock_utils_a11y_bus_connection_get, utils_a11y_bus_connection_get, Eldbus_Connection *());
+DECLARE_FUNCTION_MOCK1(mock_utils_a11y_bus_connection_set, utils_a11y_bus_connection_set, void(Eldbus_Connection *));
+DECLARE_FUNCTION_MOCK1(mock_utils_enum_to_string, utils_enum_to_string, const char *(Gesture));
+
--- /dev/null
+#include "mocked_external.h"
+
+IMPLEMENT_FUNCTION_MOCK1(mock__eina_barrier_free, _eina_barrier_free, void(Eina_Barrier *));
+IMPLEMENT_FUNCTION_MOCK2(mock__eina_barrier_new, _eina_barrier_new, Eina_Bool(Eina_Barrier *, int));
+IMPLEMENT_FUNCTION_MOCK1(mock__eina_condition_free, _eina_condition_free, void(Eina_Condition *));
+IMPLEMENT_FUNCTION_MOCK2(mock__eina_condition_new, _eina_condition_new, Eina_Bool(Eina_Condition *, Eina_Lock *));
+IMPLEMENT_FUNCTION_MOCK4(mock__eina_crc, _eina_crc, unsigned int(const char *, int, unsigned int, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK3(mock__eina_lock_debug_abort, _eina_lock_debug_abort, void(int, const char *, const volatile void *));
+IMPLEMENT_FUNCTION_MOCK2(mock__eina_lock_debug_deadlock, _eina_lock_debug_deadlock, void(const char *, const volatile void *));
+IMPLEMENT_FUNCTION_MOCK1(mock__eina_lock_free, _eina_lock_free, void(Eina_Lock *));
+IMPLEMENT_FUNCTION_MOCK2(mock__eina_lock_new, _eina_lock_new, Eina_Bool(Eina_Lock *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK1(mock__eina_rwlock_free, _eina_rwlock_free, void(Eina_RWLock *));
+IMPLEMENT_FUNCTION_MOCK1(mock__eina_rwlock_new, _eina_rwlock_new, Eina_Bool(Eina_RWLock *));
+IMPLEMENT_FUNCTION_MOCK1(mock__eina_semaphore_free, _eina_semaphore_free, Eina_Bool(Eina_Semaphore *));
+IMPLEMENT_FUNCTION_MOCK2(mock__eina_semaphore_new, _eina_semaphore_new, Eina_Bool(Eina_Semaphore *, int));
+IMPLEMENT_FUNCTION_MOCK1(mock__eina_spinlock_free, _eina_spinlock_free, void(Eina_Spinlock *));
+IMPLEMENT_FUNCTION_MOCK1(mock__eina_spinlock_new, _eina_spinlock_new, Eina_Bool(Eina_Spinlock *));
+IMPLEMENT_FUNCTION_MOCK4(mock__eina_unicode_utf8_next_get, _eina_unicode_utf8_next_get, Eina_Unicode(int, unsigned char, const char *, int *));
+IMPLEMENT_FUNCTION_MOCK1(mock_abs, abs, int(int));
+IMPLEMENT_FUNCTION_MOCK0(mock_app_get_resource_path, app_get_resource_path, char *());
+IMPLEMENT_FUNCTION_MOCK4(mock_appcore_efl_main, appcore_efl_main, int(const char *, int *, char ***, struct appcore_ops *));
+IMPLEMENT_FUNCTION_MOCK3(mock_appcore_set_event_callback, appcore_set_event_callback, int(enum appcore_event, int (*)(void *, void *), void *));
+IMPLEMENT_FUNCTION_MOCK4(mock_appsvc_run_service, appsvc_run_service, int(bundle *, int, appsvc_res_fn, void *));
+IMPLEMENT_FUNCTION_MOCK2(mock_appsvc_set_operation, appsvc_set_operation, int(bundle *, const char *));
+IMPLEMENT_FUNCTION_MOCK1(mock_atoi, atoi, int(const char *));
+IMPLEMENT_FUNCTION_MOCK1(mock_atspi_accessible_get_action_iface, atspi_accessible_get_action_iface, AtspiAction *(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_accessible_get_attributes, atspi_accessible_get_attributes, GHashTable *(AtspiAccessible *, GError **));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_accessible_get_bus_name, atspi_accessible_get_bus_name, gchar *(AtspiAccessible *, GError **));
+IMPLEMENT_FUNCTION_MOCK3(mock_atspi_accessible_get_child_at_index, atspi_accessible_get_child_at_index, AtspiAccessible *(AtspiAccessible *, gint, GError **));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_accessible_get_child_count, atspi_accessible_get_child_count, gint(AtspiAccessible *, GError **));
+IMPLEMENT_FUNCTION_MOCK1(mock_atspi_accessible_get_component_iface, atspi_accessible_get_component_iface, AtspiComponent *(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_accessible_get_default_label_info, atspi_accessible_get_default_label_info, AtspiAccessibleDefaultLabelInfo *(AtspiAccessible *, GError **));
+IMPLEMENT_FUNCTION_MOCK1(mock_atspi_accessible_get_editable_text_iface, atspi_accessible_get_editable_text_iface, AtspiEditableText *(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_accessible_get_index_in_parent, atspi_accessible_get_index_in_parent, gint(AtspiAccessible *, GError **));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_accessible_get_localized_role_name, atspi_accessible_get_localized_role_name, gchar *(AtspiAccessible *, GError **));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_accessible_get_name, atspi_accessible_get_name, gchar *(AtspiAccessible *, GError **));
+IMPLEMENT_FUNCTION_MOCK5(mock_atspi_accessible_get_navigable_at_point, atspi_accessible_get_navigable_at_point, AtspiAccessible *(AtspiAccessible *, gint, gint, AtspiCoordType, GError **));
+IMPLEMENT_FUNCTION_MOCK4(mock_atspi_accessible_get_neighbor, atspi_accessible_get_neighbor, AtspiAccessible *(AtspiAccessible *, AtspiAccessible *, AtspiNeighborSearchDirection, GError **));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_accessible_get_parent, atspi_accessible_get_parent, AtspiAccessible *(AtspiAccessible *, GError **));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_accessible_get_reading_material, atspi_accessible_get_reading_material, AtspiAccessibleReadingMaterial *(AtspiAccessible *, GError **));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_accessible_get_relation_set, atspi_accessible_get_relation_set, GArray *(AtspiAccessible *, GError **));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_accessible_get_role, atspi_accessible_get_role, AtspiRole(AtspiAccessible *, GError **));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_accessible_get_role_name, atspi_accessible_get_role_name, gchar *(AtspiAccessible *, GError **));
+IMPLEMENT_FUNCTION_MOCK1(mock_atspi_accessible_get_selection, atspi_accessible_get_selection, AtspiSelection *(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_atspi_accessible_get_selection_iface, atspi_accessible_get_selection_iface, AtspiSelection *(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_atspi_accessible_get_state_set, atspi_accessible_get_state_set, AtspiStateSet *(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_atspi_accessible_get_text_iface, atspi_accessible_get_text_iface, AtspiText *(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_accessible_get_toolkit_name, atspi_accessible_get_toolkit_name, gchar *(AtspiAccessible *, GError **));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_accessible_get_unique_id, atspi_accessible_get_unique_id, gchar *(AtspiAccessible *, GError **));
+IMPLEMENT_FUNCTION_MOCK1(mock_atspi_accessible_get_value_iface, atspi_accessible_get_value_iface, AtspiValue *(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK3(mock_atspi_action_do_action_name, atspi_action_do_action_name, gboolean(AtspiAction *, const gchar *, GError **));
+IMPLEMENT_FUNCTION_MOCK3(mock_atspi_action_get_action_name, atspi_action_get_action_name, gchar *(AtspiAction *, gint, GError **));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_action_get_n_actions, atspi_action_get_n_actions, gint(AtspiAction *, GError **));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_component_clear_highlight, atspi_component_clear_highlight, gboolean(AtspiComponent *, GError **));
+IMPLEMENT_FUNCTION_MOCK3(mock_atspi_component_get_extents, atspi_component_get_extents, AtspiRect *(AtspiComponent *, AtspiCoordType, GError **));
+IMPLEMENT_FUNCTION_MOCK0(mock_atspi_component_get_type, atspi_component_get_type, GType());
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_component_grab_focus, atspi_component_grab_focus, gboolean(AtspiComponent *, GError **));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_component_grab_highlight, atspi_component_grab_highlight, gboolean(AtspiComponent *, GError **));
+IMPLEMENT_FUNCTION_MOCK5(mock_atspi_deregister_keystroke_listener, atspi_deregister_keystroke_listener, gboolean(AtspiDeviceListener *, GArray *, AtspiKeyMaskType, AtspiKeyEventMask, GError **));
+IMPLEMENT_FUNCTION_MOCK3(mock_atspi_device_listener_new, atspi_device_listener_new, AtspiDeviceListener *(AtspiDeviceListenerCB, void *, GDestroyNotify));
+IMPLEMENT_FUNCTION_MOCK4(mock_atspi_editable_text_copy_text, atspi_editable_text_copy_text, gboolean(AtspiEditableText *, gint, gint, GError **));
+IMPLEMENT_FUNCTION_MOCK4(mock_atspi_editable_text_cut_text, atspi_editable_text_cut_text, gboolean(AtspiEditableText *, gint, gint, GError **));
+IMPLEMENT_FUNCTION_MOCK4(mock_atspi_editable_text_delete_text, atspi_editable_text_delete_text, gboolean(AtspiEditableText *, gint, gint, GError **));
+IMPLEMENT_FUNCTION_MOCK3(mock_atspi_editable_text_paste_text, atspi_editable_text_paste_text, gboolean(AtspiEditableText *, gint, GError **));
+IMPLEMENT_FUNCTION_MOCK3(mock_atspi_event_listener_deregister, atspi_event_listener_deregister, gboolean(AtspiEventListener *, const gchar *, GError **));
+IMPLEMENT_FUNCTION_MOCK3(mock_atspi_event_listener_new, atspi_event_listener_new, AtspiEventListener *(AtspiEventListenerCB, gpointer, GDestroyNotify));
+IMPLEMENT_FUNCTION_MOCK3(mock_atspi_event_listener_register, atspi_event_listener_register, gboolean(AtspiEventListener *, const gchar *, GError **));
+IMPLEMENT_FUNCTION_MOCK0(mock_atspi_exit, atspi_exit, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_atspi_init, atspi_init, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_atspi_object_get_type, atspi_object_get_type, GType());
+IMPLEMENT_FUNCTION_MOCK6(mock_atspi_register_keystroke_listener, atspi_register_keystroke_listener, gboolean(AtspiDeviceListener *, GArray *, AtspiKeyMaskType, AtspiKeyEventMask, AtspiKeyListenerSyncType, GError **));
+IMPLEMENT_FUNCTION_MOCK1(mock_atspi_relation_get_n_targets, atspi_relation_get_n_targets, gint(AtspiRelation *));
+IMPLEMENT_FUNCTION_MOCK1(mock_atspi_relation_get_relation_type, atspi_relation_get_relation_type, AtspiRelationType(AtspiRelation *));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_relation_get_target, atspi_relation_get_target, AtspiAccessible *(AtspiRelation *, gint));
+IMPLEMENT_FUNCTION_MOCK3(mock_atspi_selection_deselect_child, atspi_selection_deselect_child, gboolean(AtspiSelection *, gint, GError **));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_selection_get_n_selected_children, atspi_selection_get_n_selected_children, gint(AtspiSelection *, GError **));
+IMPLEMENT_FUNCTION_MOCK3(mock_atspi_selection_select_child, atspi_selection_select_child, gboolean(AtspiSelection *, gint, GError **));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_state_set_contains, atspi_state_set_contains, gboolean(AtspiStateSet *, AtspiStateType));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_text_get_caret_offset, atspi_text_get_caret_offset, gint(AtspiText *, GError **));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_text_get_character_count, atspi_text_get_character_count, gint(AtspiText *, GError **));
+IMPLEMENT_FUNCTION_MOCK3(mock_atspi_text_get_selection, atspi_text_get_selection, AtspiRange *(AtspiText *, gint, GError **));
+IMPLEMENT_FUNCTION_MOCK4(mock_atspi_text_get_text, atspi_text_get_text, gchar *(AtspiText *, gint, gint, GError **));
+IMPLEMENT_FUNCTION_MOCK3(mock_atspi_text_remove_selection, atspi_text_remove_selection, gboolean(AtspiText *, gint, GError **));
+IMPLEMENT_FUNCTION_MOCK3(mock_atspi_text_set_caret_offset, atspi_text_set_caret_offset, gboolean(AtspiText *, gint, GError **));
+IMPLEMENT_FUNCTION_MOCK5(mock_atspi_text_set_selection, atspi_text_set_selection, gboolean(AtspiText *, gint, gint, gint, GError **));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_value_get_current_value, atspi_value_get_current_value, gdouble(AtspiValue *, GError **));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_value_get_maximum_value, atspi_value_get_maximum_value, gdouble(AtspiValue *, GError **));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_value_get_minimum_increment, atspi_value_get_minimum_increment, gdouble(AtspiValue *, GError **));
+IMPLEMENT_FUNCTION_MOCK2(mock_atspi_value_get_minimum_value, atspi_value_get_minimum_value, gdouble(AtspiValue *, GError **));
+IMPLEMENT_FUNCTION_MOCK3(mock_atspi_value_set_current_value, atspi_value_set_current_value, gboolean(AtspiValue *, gdouble, GError **));
+IMPLEMENT_FUNCTION_MOCK1(mock_aul_app_get_status_bypid, aul_app_get_status_bypid, int(int));
+IMPLEMENT_FUNCTION_MOCK1(mock_aul_terminate_pid, aul_terminate_pid, int(int));
+IMPLEMENT_FUNCTION_MOCK2(mock_backtrace, backtrace, int(void **, int));
+IMPLEMENT_FUNCTION_MOCK2(mock_backtrace_symbols, backtrace_symbols, char **(void *const *, int));
+IMPLEMENT_FUNCTION_MOCK2(mock_bt_adapter_foreach_bonded_device, bt_adapter_foreach_bonded_device, int(bt_adapter_bonded_device_cb, void *));
+IMPLEMENT_FUNCTION_MOCK1(mock_bt_adapter_get_state, bt_adapter_get_state, int(bt_adapter_state_e *));
+IMPLEMENT_FUNCTION_MOCK0(mock_bt_deinitialize, bt_deinitialize, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_bt_initialize, bt_initialize, int());
+IMPLEMENT_FUNCTION_MOCK3(mock_bundle_add_str, bundle_add_str, int(bundle *, const char *, const char *));
+IMPLEMENT_FUNCTION_MOCK0(mock_bundle_create, bundle_create, bundle *());
+IMPLEMENT_FUNCTION_MOCK1(mock_bundle_free, bundle_free, int(bundle *));
+IMPLEMENT_FUNCTION_MOCK3(mock_bundle_get_str, bundle_get_str, int(bundle *, const char *, char **));
+IMPLEMENT_FUNCTION_MOCK2(mock_clock_gettime, clock_gettime, int(clockid_t, struct timespec *));
+IMPLEMENT_FUNCTION_MOCK1(mock_dbus_address_entries_free, dbus_address_entries_free, void(DBusAddressEntry **));
+IMPLEMENT_FUNCTION_MOCK1(mock_dbus_connection_unref, dbus_connection_unref, void(DBusConnection *));
+IMPLEMENT_FUNCTION_MOCK1(mock_dbus_message_unref, dbus_message_unref, void(DBusMessage *));
+IMPLEMENT_FUNCTION_MOCK1(mock_dbus_pending_call_unref, dbus_pending_call_unref, void(DBusPendingCall *));
+IMPLEMENT_FUNCTION_MOCK1(mock_dbus_server_unref, dbus_server_unref, void(DBusServer *));
+IMPLEMENT_FUNCTION_MOCK3(mock_device_add_callback, device_add_callback, int(device_callback_e, device_changed_cb, void *));
+IMPLEMENT_FUNCTION_MOCK1(mock_device_battery_get_level_status, device_battery_get_level_status, int(device_battery_level_e *));
+IMPLEMENT_FUNCTION_MOCK1(mock_device_battery_get_percent, device_battery_get_percent, int(int *));
+IMPLEMENT_FUNCTION_MOCK1(mock_device_battery_is_charging, device_battery_is_charging, int(_Bool *));
+IMPLEMENT_FUNCTION_MOCK1(mock_device_display_get_state, device_display_get_state, int(display_state_e *));
+IMPLEMENT_FUNCTION_MOCK1(mock_device_haptic_close, device_haptic_close, int(haptic_device_h));
+IMPLEMENT_FUNCTION_MOCK1(mock_device_haptic_get_count, device_haptic_get_count, int(int *));
+IMPLEMENT_FUNCTION_MOCK2(mock_device_haptic_open, device_haptic_open, int(int, haptic_device_h *));
+IMPLEMENT_FUNCTION_MOCK2(mock_device_haptic_stop, device_haptic_stop, int(haptic_device_h, haptic_effect_h));
+IMPLEMENT_FUNCTION_MOCK4(mock_device_haptic_vibrate, device_haptic_vibrate, int(haptic_device_h, int, int, haptic_effect_h *));
+IMPLEMENT_FUNCTION_MOCK1(mock_device_power_release_lock, device_power_release_lock, int(power_lock_e));
+IMPLEMENT_FUNCTION_MOCK2(mock_device_power_request_lock, device_power_request_lock, int(power_lock_e, int));
+IMPLEMENT_FUNCTION_MOCK2(mock_device_remove_callback, device_remove_callback, int(device_callback_e, device_changed_cb));
+IMPLEMENT_FUNCTION_MOCK0(mock_ecore_time_get, ecore_time_get, double());
+IMPLEMENT_FUNCTION_MOCK3(mock_ecore_timer_add, ecore_timer_add, Ecore_Timer *(double, Ecore_Task_Cb, const void *));
+IMPLEMENT_FUNCTION_MOCK1(mock_ecore_timer_del, ecore_timer_del, void *(Ecore_Timer *));
+IMPLEMENT_FUNCTION_MOCK1(mock_ecore_timer_reset, ecore_timer_reset, void(Efl_Loop_Timer *));
+IMPLEMENT_FUNCTION_MOCK1(mock_efl_ref, efl_ref, Eo *(const Eo *));
+IMPLEMENT_FUNCTION_MOCK1(mock_efl_unref, efl_unref, void(const Eo *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_array_grow, eina_array_grow, Eina_Bool(Eina_Array *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_content_converter_possible_conversions, eina_content_converter_possible_conversions, Eina_Iterator *(const char *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_content_type_get, eina_content_type_get, const char *(Eina_Content *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_error_set, eina_error_set, void(Eina_Error));
+IMPLEMENT_FUNCTION_MOCK0(mock_eina_freeq_main_get, eina_freeq_main_get, Eina_FreeQ *());
+IMPLEMENT_FUNCTION_MOCK4(mock_eina_freeq_ptr_add, eina_freeq_ptr_add, void(Eina_FreeQ *, void *, void (*)(void *), size_t));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_future_new, eina_future_new, Eina_Future *(Eina_Promise *));
+IMPLEMENT_FUNCTION_MOCK3(mock_eina_hash_add, eina_hash_add, Eina_Bool(Eina_Hash *, const void *, const void *));
+IMPLEMENT_FUNCTION_MOCK2(mock_eina_hash_del_by_key, eina_hash_del_by_key, Eina_Bool(Eina_Hash *, const void *));
+IMPLEMENT_FUNCTION_MOCK2(mock_eina_hash_find, eina_hash_find, void *(const Eina_Hash *, const void *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_hash_population, eina_hash_population, int(const Eina_Hash *));
+IMPLEMENT_FUNCTION_MOCK3(mock_eina_inarray_alloc_at, eina_inarray_alloc_at, void *(Eina_Inarray *, unsigned int, unsigned int));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_inarray_count, eina_inarray_count, unsigned int(const Eina_Inarray *));
+IMPLEMENT_FUNCTION_MOCK2(mock_eina_inarray_nth, eina_inarray_nth, void *(const Eina_Inarray *, unsigned int));
+IMPLEMENT_FUNCTION_MOCK2(mock_eina_inarray_remove_at, eina_inarray_remove_at, Eina_Bool(Eina_Inarray *, unsigned int));
+IMPLEMENT_FUNCTION_MOCK2(mock_eina_list_append, eina_list_append, Eina_List *(Eina_List *, const void *));
+IMPLEMENT_FUNCTION_MOCK3(mock_eina_list_append_relative_list, eina_list_append_relative_list, Eina_List *(Eina_List *, const void *, Eina_List *));
+IMPLEMENT_FUNCTION_MOCK2(mock_eina_list_nth, eina_list_nth, void *(const Eina_List *, unsigned int));
+IMPLEMENT_FUNCTION_MOCK2(mock_eina_list_nth_list, eina_list_nth_list, Eina_List *(const Eina_List *, unsigned int));
+IMPLEMENT_FUNCTION_MOCK2(mock_eina_list_prepend, eina_list_prepend, Eina_List *(Eina_List *, const void *));
+IMPLEMENT_FUNCTION_MOCK2(mock_eina_list_remove, eina_list_remove, Eina_List *(Eina_List *, const void *));
+IMPLEMENT_FUNCTION_MOCK2(mock_eina_list_remove_list, eina_list_remove_list, Eina_List *(Eina_List *, Eina_List *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_lock_debug, eina_lock_debug, void(const Eina_Lock *));
+IMPLEMENT_FUNCTION_MOCK0(mock_eina_log_color_disable_get, eina_log_color_disable_get, Eina_Bool());
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_log_domain_registered_level_get, eina_log_domain_registered_level_get, int(int));
+IMPLEMENT_FUNCTION_MOCK0(mock_eina_log_level_get, eina_log_level_get, int());
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_matrix3_type_get, eina_matrix3_type_get, Eina_Matrix_Type(const Eina_Matrix3 *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_matrix4_type_get, eina_matrix4_type_get, Eina_Matrix_Type(const Eina_Matrix4 *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_promise_all_array, eina_promise_all_array, Eina_Promise *(Eina_Future *[]));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_promise_all_iterator, eina_promise_all_iterator, Eina_Promise *(Eina_Iterator *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_promise_race_array, eina_promise_race_array, Eina_Promise *(Eina_Future *[]));
+IMPLEMENT_FUNCTION_MOCK2(mock_eina_slstr_vasprintf_new, eina_slstr_vasprintf_new, Eina_Slstr *(const char *, va_list));
+IMPLEMENT_FUNCTION_MOCK7(mock_eina_str_join_len, eina_str_join_len, size_t(char *, size_t, char, const char *, size_t, const char *, size_t));
+IMPLEMENT_FUNCTION_MOCK4(mock_eina_str_split_full, eina_str_split_full, char **(const char *, const char *, int, unsigned int *));
+IMPLEMENT_FUNCTION_MOCK2(mock_eina_strbuf_append, eina_strbuf_append, Eina_Bool(Eina_Strbuf *, const char *));
+IMPLEMENT_FUNCTION_MOCK2(mock_eina_strbuf_append_char, eina_strbuf_append_char, Eina_Bool(Eina_Strbuf *, char));
+IMPLEMENT_FUNCTION_MOCK3(mock_eina_strbuf_append_length, eina_strbuf_append_length, Eina_Bool(Eina_Strbuf *, const char *, size_t));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_strbuf_free, eina_strbuf_free, void(Eina_Strbuf *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_strbuf_length_get, eina_strbuf_length_get, size_t(const Eina_Strbuf *));
+IMPLEMENT_FUNCTION_MOCK0(mock_eina_strbuf_new, eina_strbuf_new, Eina_Strbuf *());
+IMPLEMENT_FUNCTION_MOCK3(mock_eina_strbuf_replace_all, eina_strbuf_replace_all, int(Eina_Strbuf *, const char *, const char *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_strbuf_string_get, eina_strbuf_string_get, const char *(const Eina_Strbuf *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_strbuf_string_steal, eina_strbuf_string_steal, char *(Eina_Strbuf *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_strbuf_trim, eina_strbuf_trim, void(Eina_Strbuf *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_stringshare_add, eina_stringshare_add, Eina_Stringshare *(const char *));
+IMPLEMENT_FUNCTION_MOCK2(mock_eina_stringshare_add_length, eina_stringshare_add_length, Eina_Stringshare *(const char *, unsigned int));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_stringshare_del, eina_stringshare_del, void(Eina_Stringshare *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_stringshare_ref, eina_stringshare_ref, Eina_Stringshare *(Eina_Stringshare *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_stringshare_strlen, eina_stringshare_strlen, int(Eina_Stringshare *));
+IMPLEMENT_FUNCTION_MOCK2(mock_eina_unicode_unicode_to_utf8, eina_unicode_unicode_to_utf8, char *(const Eina_Unicode *, int *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_unicode_utf8_get_len, eina_unicode_utf8_get_len, int(const char *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_ustringshare_add, eina_ustringshare_add, const Eina_Unicode *(const Eina_Unicode *));
+IMPLEMENT_FUNCTION_MOCK2(mock_eina_ustringshare_add_length, eina_ustringshare_add_length, const Eina_Unicode *(const Eina_Unicode *, unsigned int));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_ustringshare_del, eina_ustringshare_del, void(const Eina_Unicode *));
+IMPLEMENT_FUNCTION_MOCK2(mock_eina_value_convert, eina_value_convert, Eina_Bool(const Eina_Value *, Eina_Value *));
+IMPLEMENT_FUNCTION_MOCK2(mock_eina_value_copy, eina_value_copy, Eina_Bool(const Eina_Value *, Eina_Value *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_value_inner_alloc, eina_value_inner_alloc, void *(size_t));
+IMPLEMENT_FUNCTION_MOCK2(mock_eina_value_inner_free, eina_value_inner_free, void(size_t, void *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_value_new, eina_value_new, Eina_Value *(const Eina_Value_Type *));
+IMPLEMENT_FUNCTION_MOCK2(mock_eina_value_struct_member_find, eina_value_struct_member_find, const Eina_Value_Struct_Member *(const Eina_Value_Struct *, const char *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eina_value_type_check, eina_value_type_check, Eina_Bool(const Eina_Value_Type *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eldbus_address_connection_get, eldbus_address_connection_get, Eldbus_Connection *(const char *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eldbus_connection_get, eldbus_connection_get, Eldbus_Connection *(Eldbus_Connection_Type));
+IMPLEMENT_FUNCTION_MOCK5(mock_eldbus_connection_send, eldbus_connection_send, Eldbus_Pending *(Eldbus_Connection *, Eldbus_Message *, Eldbus_Message_Cb, const void *, double));
+IMPLEMENT_FUNCTION_MOCK1(mock_eldbus_connection_unref, eldbus_connection_unref, void(Eldbus_Connection *));
+IMPLEMENT_FUNCTION_MOCK0(mock_eldbus_init, eldbus_init, int());
+IMPLEMENT_FUNCTION_MOCK3(mock_eldbus_message_error_get, eldbus_message_error_get, Eina_Bool(const Eldbus_Message *, const char **, const char **));
+IMPLEMENT_FUNCTION_MOCK3(mock_eldbus_message_error_new, eldbus_message_error_new, Eldbus_Message *(const Eldbus_Message *, const char *, const char *));
+IMPLEMENT_FUNCTION_MOCK2(mock_eldbus_message_iter_container_close, eldbus_message_iter_container_close, Eina_Bool(Eldbus_Message_Iter *, Eldbus_Message_Iter *));
+IMPLEMENT_FUNCTION_MOCK3(mock_eldbus_message_iter_container_new, eldbus_message_iter_container_new, Eldbus_Message_Iter *(Eldbus_Message_Iter *, int, const char *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eldbus_message_iter_get, eldbus_message_iter_get, Eldbus_Message_Iter *(const Eldbus_Message *));
+IMPLEMENT_FUNCTION_MOCK4(mock_eldbus_message_method_call_new, eldbus_message_method_call_new, Eldbus_Message *(const char *, const char *, const char *, const char *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eldbus_message_method_return_new, eldbus_message_method_return_new, Eldbus_Message *(const Eldbus_Message *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eldbus_message_ref, eldbus_message_ref, Eldbus_Message *(Eldbus_Message *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eldbus_message_unref, eldbus_message_unref, void(Eldbus_Message *));
+IMPLEMENT_FUNCTION_MOCK4(mock_eldbus_name_release, eldbus_name_release, Eldbus_Pending *(Eldbus_Connection *, const char *, Eldbus_Message_Cb, const void *));
+IMPLEMENT_FUNCTION_MOCK5(mock_eldbus_name_request, eldbus_name_request, Eldbus_Pending *(Eldbus_Connection *, const char *, unsigned int, Eldbus_Message_Cb, const void *));
+IMPLEMENT_FUNCTION_MOCK3(mock_eldbus_object_get, eldbus_object_get, Eldbus_Object *(Eldbus_Connection *, const char *, const char *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eldbus_object_unref, eldbus_object_unref, void(Eldbus_Object *));
+IMPLEMENT_FUNCTION_MOCK2(mock_eldbus_proxy_get, eldbus_proxy_get, Eldbus_Proxy *(Eldbus_Object *, const char *));
+IMPLEMENT_FUNCTION_MOCK2(mock_eldbus_proxy_method_call_new, eldbus_proxy_method_call_new, Eldbus_Message *(Eldbus_Proxy *, const char *));
+IMPLEMENT_FUNCTION_MOCK5(mock_eldbus_proxy_send, eldbus_proxy_send, Eldbus_Pending *(Eldbus_Proxy *, Eldbus_Message *, Eldbus_Message_Cb, const void *, double));
+IMPLEMENT_FUNCTION_MOCK3(mock_eldbus_proxy_send_and_block, eldbus_proxy_send_and_block, Eldbus_Message *(Eldbus_Proxy *, Eldbus_Message *, double));
+IMPLEMENT_FUNCTION_MOCK4(mock_eldbus_proxy_signal_handler_add, eldbus_proxy_signal_handler_add, Eldbus_Signal_Handler *(Eldbus_Proxy *, const char *, Eldbus_Signal_Cb, const void *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eldbus_proxy_unref, eldbus_proxy_unref, void(Eldbus_Proxy *));
+IMPLEMENT_FUNCTION_MOCK3(mock_eldbus_service_interface_register, eldbus_service_interface_register, Eldbus_Service_Interface *(Eldbus_Connection *, const char *, const Eldbus_Service_Interface_Desc *));
+IMPLEMENT_FUNCTION_MOCK1(mock_eldbus_service_object_unregister, eldbus_service_object_unregister, void(Eldbus_Service_Interface *));
+IMPLEMENT_FUNCTION_MOCK0(mock_eldbus_shutdown, eldbus_shutdown, int());
+IMPLEMENT_FUNCTION_MOCK1(mock_elm_box_add, elm_box_add, Evas_Object *(Evas_Object *));
+IMPLEMENT_FUNCTION_MOCK2(mock_elm_box_pack_end, elm_box_pack_end, void(Elm_Box *, Efl_Canvas_Object *));
+IMPLEMENT_FUNCTION_MOCK1(mock_elm_config_atspi_mode_set, elm_config_atspi_mode_set, void(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK0(mock_elm_exit, elm_exit, void());
+IMPLEMENT_FUNCTION_MOCK2(mock_elm_init, elm_init, int(int, char **));
+IMPLEMENT_FUNCTION_MOCK1(mock_elm_label_add, elm_label_add, Evas_Object *(Evas_Object *));
+IMPLEMENT_FUNCTION_MOCK6(mock_elm_naviframe_item_push, elm_naviframe_item_push, Elm_Object_Item *(Evas_Object *, const char *, Evas_Object *, Evas_Object *, Evas_Object *, const char *));
+IMPLEMENT_FUNCTION_MOCK3(mock_elm_naviframe_item_title_enabled_set, elm_naviframe_item_title_enabled_set, void(Elm_Object_Item *, Eina_Bool, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK3(mock_elm_object_part_text_set, elm_object_part_text_set, void(Evas_Object *, const char *, const char *));
+IMPLEMENT_FUNCTION_MOCK0(mock_elm_shutdown, elm_shutdown, int());
+IMPLEMENT_FUNCTION_MOCK3(mock_elm_win_add, elm_win_add, Evas_Object *(Evas_Object *, const char *, Elm_Win_Type));
+IMPLEMENT_FUNCTION_MOCK2(mock_elm_win_alpha_set, elm_win_alpha_set, void(Evas_Object *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK2(mock_elm_win_borderless_set, elm_win_borderless_set, void(Evas_Object *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK2(mock_elm_win_quickpanel_set, elm_win_quickpanel_set, void(Evas_Object *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK1(mock_elm_win_raise, elm_win_raise, void(Elm_Win *));
+IMPLEMENT_FUNCTION_MOCK2(mock_elm_win_resize_object_add, elm_win_resize_object_add, void(Evas_Object *, Evas_Object *));
+IMPLEMENT_FUNCTION_MOCK2(mock_elm_win_title_set, elm_win_title_set, void(Evas_Object *, const char *));
+IMPLEMENT_FUNCTION_MOCK1(mock_evas_object_del, evas_object_del, void(Evas_Object *));
+IMPLEMENT_FUNCTION_MOCK1(mock_evas_object_show, evas_object_show, void(Evas_Object *));
+IMPLEMENT_FUNCTION_MOCK3(mock_evas_object_size_hint_align_set, evas_object_size_hint_align_set, void(Evas_Object *, double, double));
+IMPLEMENT_FUNCTION_MOCK3(mock_evas_object_size_hint_weight_set, evas_object_size_hint_weight_set, void(Evas_Object *, double, double));
+IMPLEMENT_FUNCTION_MOCK1(mock_fabs, fabs, double(double));
+IMPLEMENT_FUNCTION_MOCK1(mock_fclose, fclose, int(FILE *));
+IMPLEMENT_FUNCTION_MOCK2(mock_fopen, fopen, FILE *(const char *, const char *));
+IMPLEMENT_FUNCTION_MOCK2(mock_fputs, fputs, int(const char *, FILE *));
+IMPLEMENT_FUNCTION_MOCK2(mock_g_array_free, g_array_free, gchar *(GArray *, gboolean));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_array_unref, g_array_unref, void(GArray *));
+IMPLEMENT_FUNCTION_MOCK5(mock_g_assertion_message, g_assertion_message, void(const char *, const char *, int, const char *, const char *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_async_queue_unref, g_async_queue_unref, void(GAsyncQueue *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_bookmark_file_free, g_bookmark_file_free, void(GBookmarkFile *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_byte_array_unref, g_byte_array_unref, void(GByteArray *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_bytes_unref, g_bytes_unref, void(GBytes *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_checksum_free, g_checksum_free, void(GChecksum *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_clear_error, g_clear_error, void(GError **));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_closure_unref, g_closure_unref, void(GClosure *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_cond_clear, g_cond_clear, void(GCond *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_date_time_unref, g_date_time_unref, void(GDateTime *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_dir_close, g_dir_close, void(GDir *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_error_free, g_error_free, void(GError *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_free, g_free, void(gpointer));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_hash_table_destroy, g_hash_table_destroy, void(GHashTable *));
+IMPLEMENT_FUNCTION_MOCK3(mock_g_hash_table_insert, g_hash_table_insert, gboolean(GHashTable *, gpointer, gpointer));
+IMPLEMENT_FUNCTION_MOCK2(mock_g_hash_table_lookup, g_hash_table_lookup, gpointer(GHashTable *, gconstpointer));
+IMPLEMENT_FUNCTION_MOCK2(mock_g_hash_table_new, g_hash_table_new, GHashTable *(GHashFunc, GEqualFunc));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_hash_table_unref, g_hash_table_unref, void(GHashTable *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_hmac_unref, g_hmac_unref, void(GHmac *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_io_channel_unref, g_io_channel_unref, void(GIOChannel *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_key_file_unref, g_key_file_unref, void(GKeyFile *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_list_free, g_list_free, void(GList *));
+IMPLEMENT_FUNCTION_MOCK2(mock_g_list_free_full, g_list_free_full, void(GList *, GDestroyNotify));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_main_context_unref, g_main_context_unref, void(GMainContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_main_loop_unref, g_main_loop_unref, void(GMainLoop *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_malloc0, g_malloc0, gpointer(gsize));
+IMPLEMENT_FUNCTION_MOCK2(mock_g_malloc_n, g_malloc_n, gpointer(gsize, gsize));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_mapped_file_unref, g_mapped_file_unref, void(GMappedFile *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_markup_parse_context_unref, g_markup_parse_context_unref, void(GMarkupParseContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_match_info_unref, g_match_info_unref, void(GMatchInfo *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_mutex_clear, g_mutex_clear, void(GMutex *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_mutex_lock, g_mutex_lock, void(GMutex *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_mutex_unlock, g_mutex_unlock, void(GMutex *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_node_destroy, g_node_destroy, void(GNode *));
+IMPLEMENT_FUNCTION_MOCK2(mock_g_object_add_weak_pointer, g_object_add_weak_pointer, void(GObject *, gpointer *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_object_ref, g_object_ref, gpointer(gpointer));
+IMPLEMENT_FUNCTION_MOCK2(mock_g_object_remove_weak_pointer, g_object_remove_weak_pointer, void(GObject *, gpointer *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_object_unref, g_object_unref, void(gpointer));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_option_context_free, g_option_context_free, void(GOptionContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_option_group_unref, g_option_group_unref, void(GOptionGroup *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_param_spec_unref, g_param_spec_unref, void(GParamSpec *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_pattern_spec_free, g_pattern_spec_free, void(GPatternSpec *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_ptr_array_unref, g_ptr_array_unref, void(GPtrArray *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_queue_clear, g_queue_clear, void(GQueue *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_queue_free, g_queue_free, void(GQueue *));
+IMPLEMENT_FUNCTION_MOCK2(mock_g_queue_free_full, g_queue_free_full, void(GQueue *, GDestroyNotify));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_rand_free, g_rand_free, void(GRand *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_rec_mutex_lock, g_rec_mutex_lock, void(GRecMutex *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_rec_mutex_unlock, g_rec_mutex_unlock, void(GRecMutex *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_ref_string_release, g_ref_string_release, void(char *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_regex_unref, g_regex_unref, void(GRegex *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_rw_lock_reader_lock, g_rw_lock_reader_lock, void(GRWLock *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_rw_lock_reader_unlock, g_rw_lock_reader_unlock, void(GRWLock *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_rw_lock_writer_lock, g_rw_lock_writer_lock, void(GRWLock *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_rw_lock_writer_unlock, g_rw_lock_writer_unlock, void(GRWLock *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_scanner_destroy, g_scanner_destroy, void(GScanner *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_sequence_free, g_sequence_free, void(GSequence *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_slist_free, g_slist_free, void(GSList *));
+IMPLEMENT_FUNCTION_MOCK2(mock_g_slist_free_full, g_slist_free_full, void(GSList *, GDestroyNotify));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_source_remove, g_source_remove, gboolean(guint));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_source_unref, g_source_unref, void(GSource *));
+IMPLEMENT_FUNCTION_MOCK2(mock_g_str_equal, g_str_equal, gboolean(gconstpointer, gconstpointer));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_str_hash, g_str_hash, guint(gconstpointer));
+IMPLEMENT_FUNCTION_MOCK2(mock_g_strcmp0, g_strcmp0, int(const char *, const char *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_strdup, g_strdup, gchar *(const gchar *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_strfreev, g_strfreev, void(gchar **));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_string_chunk_free, g_string_chunk_free, void(GStringChunk *));
+IMPLEMENT_FUNCTION_MOCK2(mock_g_string_free, g_string_free, gchar *(GString *, gboolean));
+IMPLEMENT_FUNCTION_MOCK3(mock_g_string_insert_c, g_string_insert_c, GString *(GString *, gssize, gchar));
+IMPLEMENT_FUNCTION_MOCK3(mock_g_strlcat, g_strlcat, gsize(gchar *, const gchar *, gsize));
+IMPLEMENT_FUNCTION_MOCK3(mock_g_strlcpy, g_strlcpy, gsize(gchar *, const gchar *, gsize));
+IMPLEMENT_FUNCTION_MOCK2(mock_g_strndup, g_strndup, gchar *(const gchar *, gsize));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_thread_unref, g_thread_unref, void(GThread *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_time_zone_unref, g_time_zone_unref, void(GTimeZone *));
+IMPLEMENT_FUNCTION_MOCK3(mock_g_timeout_add, g_timeout_add, guint(guint, GSourceFunc, gpointer));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_timer_destroy, g_timer_destroy, void(GTimer *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_tree_unref, g_tree_unref, void(GTree *));
+IMPLEMENT_FUNCTION_MOCK2(mock_g_type_check_instance_cast, g_type_check_instance_cast, GTypeInstance *(GTypeInstance *, GType));
+IMPLEMENT_FUNCTION_MOCK2(mock_g_type_check_instance_is_a, g_type_check_instance_is_a, gboolean(GTypeInstance *, GType));
+IMPLEMENT_FUNCTION_MOCK2(mock_g_type_check_instance_is_fundamentally_a, g_type_check_instance_is_fundamentally_a, gboolean(GTypeInstance *, GType));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_type_class_unref, g_type_class_unref, void(gpointer));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_value_get_boxed, g_value_get_boxed, gpointer(const GValue *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_value_get_string, g_value_get_string, const gchar *(const GValue *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_value_unset, g_value_unset, void(GValue *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_variant_builder_clear, g_variant_builder_clear, void(GVariantBuilder *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_variant_builder_unref, g_variant_builder_unref, void(GVariantBuilder *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_variant_dict_clear, g_variant_dict_clear, void(GVariantDict *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_variant_dict_unref, g_variant_dict_unref, void(GVariantDict *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_variant_iter_free, g_variant_iter_free, void(GVariantIter *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_variant_type_free, g_variant_type_free, void(GVariantType *));
+IMPLEMENT_FUNCTION_MOCK1(mock_g_variant_unref, g_variant_unref, void(GVariant *));
+IMPLEMENT_FUNCTION_MOCK0(mock_getpid, getpid, __pid_t());
+IMPLEMENT_FUNCTION_MOCK1(mock_gettext, gettext, char *(const char *));
+IMPLEMENT_FUNCTION_MOCK2(mock_gettimeofday, gettimeofday, int(struct timeval *, __timezone_ptr_t));
+IMPLEMENT_FUNCTION_MOCK2(mock_kill, kill, int(__pid_t, int));
+IMPLEMENT_FUNCTION_MOCK1(mock_localtime, localtime, struct tm *(const time_t *));
+IMPLEMENT_FUNCTION_MOCK2(mock_lstat, lstat, int(const char *, struct stat *));
+IMPLEMENT_FUNCTION_MOCK3(mock_memcmp, memcmp, int(const void *, const void *, size_t));
+IMPLEMENT_FUNCTION_MOCK2(mock_mm_sound_play_keysound, mm_sound_play_keysound, int(const char *, int));
+IMPLEMENT_FUNCTION_MOCK3(mock_ngettext, ngettext, char *(const char *, const char *, unsigned long));
+IMPLEMENT_FUNCTION_MOCK1(mock_notification_free_list, notification_free_list, int(notification_list_h));
+IMPLEMENT_FUNCTION_MOCK3(mock_notification_get_list, notification_get_list, int(notification_type_e, int, notification_list_h *));
+IMPLEMENT_FUNCTION_MOCK3(mock_notification_get_text, notification_get_text, int(notification_h, notification_text_type_e, char **));
+IMPLEMENT_FUNCTION_MOCK1(mock_notification_list_get_data, notification_list_get_data, notification_h(notification_list_h));
+IMPLEMENT_FUNCTION_MOCK1(mock_notification_list_get_head, notification_list_get_head, notification_list_h(notification_list_h));
+IMPLEMENT_FUNCTION_MOCK1(mock_notification_list_get_next, notification_list_get_next, notification_list_h(notification_list_h));
+IMPLEMENT_FUNCTION_MOCK1(mock_sem_post, sem_post, int(sem_t *));
+IMPLEMENT_FUNCTION_MOCK1(mock_sem_wait, sem_wait, int(sem_t *));
+IMPLEMENT_FUNCTION_MOCK2(mock_setlocale, setlocale, char *(int, const char *));
+IMPLEMENT_FUNCTION_MOCK3(mock_sigaction, sigaction, int(int, const struct sigaction *, struct sigaction *));
+IMPLEMENT_FUNCTION_MOCK2(mock_sigaltstack, sigaltstack, int(const stack_t *, stack_t *));
+IMPLEMENT_FUNCTION_MOCK1(mock_sigemptyset, sigemptyset, int(sigset_t *));
+IMPLEMENT_FUNCTION_MOCK1(mock_sqrt, sqrt, double(double));
+IMPLEMENT_FUNCTION_MOCK1(mock_strdup, strdup, char *(const char *));
+IMPLEMENT_FUNCTION_MOCK4(mock_strftime, strftime, size_t(char *, size_t, const char *, const struct tm *));
+IMPLEMENT_FUNCTION_MOCK3(mock_strncmp, strncmp, int(const char *, const char *, size_t));
+IMPLEMENT_FUNCTION_MOCK2(mock_strnlen, strnlen, size_t(const char *, size_t));
+IMPLEMENT_FUNCTION_MOCK0(mock_tel_get_cp_name_list, tel_get_cp_name_list, char **());
+IMPLEMENT_FUNCTION_MOCK3(mock_tel_get_property_int, tel_get_property_int, int(TapiHandle *, const char *, int *));
+IMPLEMENT_FUNCTION_MOCK1(mock_tel_init, tel_init, TapiHandle *(const char *));
+IMPLEMENT_FUNCTION_MOCK1(mock_time, time, time_t(time_t *));
+IMPLEMENT_FUNCTION_MOCK6(mock_tts_add_text, tts_add_text, int(tts_h, const char *, const char *, int, int, int *));
+IMPLEMENT_FUNCTION_MOCK1(mock_tts_create, tts_create, int(tts_h *));
+IMPLEMENT_FUNCTION_MOCK1(mock_tts_destroy, tts_destroy, int(tts_h));
+IMPLEMENT_FUNCTION_MOCK2(mock_tts_get_state, tts_get_state, int(tts_h, tts_state_e *));
+IMPLEMENT_FUNCTION_MOCK1(mock_tts_pause, tts_pause, int(tts_h));
+IMPLEMENT_FUNCTION_MOCK1(mock_tts_play, tts_play, int(tts_h));
+IMPLEMENT_FUNCTION_MOCK1(mock_tts_prepare, tts_prepare, int(tts_h));
+IMPLEMENT_FUNCTION_MOCK2(mock_tts_set_mode, tts_set_mode, int(tts_h, tts_mode_e));
+IMPLEMENT_FUNCTION_MOCK3(mock_tts_set_state_changed_cb, tts_set_state_changed_cb, int(tts_h, tts_state_changed_cb, void *));
+IMPLEMENT_FUNCTION_MOCK3(mock_tts_set_utterance_completed_cb, tts_set_utterance_completed_cb, int(tts_h, tts_utterance_completed_cb, void *));
+IMPLEMENT_FUNCTION_MOCK3(mock_tts_set_utterance_started_cb, tts_set_utterance_started_cb, int(tts_h, tts_utterance_started_cb, void *));
+IMPLEMENT_FUNCTION_MOCK1(mock_tts_stop, tts_stop, int(tts_h));
+IMPLEMENT_FUNCTION_MOCK0(mock_ui_app_exit, ui_app_exit, void());
+IMPLEMENT_FUNCTION_MOCK1(mock_unsetenv, unsetenv, int(const char *));
+IMPLEMENT_FUNCTION_MOCK1(mock_usleep, usleep, int(__useconds_t));
+IMPLEMENT_FUNCTION_MOCK2(mock_vconf_get_bool, vconf_get_bool, int(const char *, int *));
+IMPLEMENT_FUNCTION_MOCK2(mock_vconf_get_int, vconf_get_int, int(const char *, int *));
+IMPLEMENT_FUNCTION_MOCK1(mock_vconf_get_str, vconf_get_str, char *(const char *));
+IMPLEMENT_FUNCTION_MOCK2(mock_vconf_ignore_key_changed, vconf_ignore_key_changed, int(const char *, vconf_callback_fn));
+IMPLEMENT_FUNCTION_MOCK1(mock_vconf_keynode_get_int, vconf_keynode_get_int, int(keynode_t *));
+IMPLEMENT_FUNCTION_MOCK3(mock_vconf_notify_key_changed, vconf_notify_key_changed, int(const char *, vconf_callback_fn, void *));
+IMPLEMENT_FUNCTION_MOCK1(mock_wifi_manager_ap_destroy, wifi_manager_ap_destroy, int(wifi_manager_ap_h));
+IMPLEMENT_FUNCTION_MOCK2(mock_wifi_manager_ap_get_rssi, wifi_manager_ap_get_rssi, int(wifi_manager_ap_h, int *));
+IMPLEMENT_FUNCTION_MOCK1(mock_wifi_manager_deinitialize, wifi_manager_deinitialize, int(wifi_manager_h));
+IMPLEMENT_FUNCTION_MOCK2(mock_wifi_manager_get_connected_ap, wifi_manager_get_connected_ap, int(wifi_manager_h, wifi_manager_ap_h *));
+IMPLEMENT_FUNCTION_MOCK1(mock_wifi_manager_initialize, wifi_manager_initialize, int(wifi_manager_h *));
+IMPLEMENT_FUNCTION_MOCK2(mock_wifi_manager_is_activated, wifi_manager_is_activated, int(wifi_manager_h, _Bool *));
+
--- /dev/null
+#pragma once
+
+extern "C" {
+#include <string.h>
+#include <atspi/atspi.h>
+#include <ecore-1/Ecore.h>
+#include <vconf.h>
+#include <libintl.h>
+#include <dlog/dlog.h>
+#include <tts.h>
+#include <eldbus-1/Eldbus.h>
+#include <stdbool.h>
+#include <Elementary.h>
+#include <appsvc/appsvc.h>
+#include <aul/aul.h>
+#include <eina-1/Eina.h>
+#include <stdio.h>
+#include <device/haptic.h>
+#include <ctype.h>
+#include <glib-2.0/glib.h>
+#include <device/battery.h>
+#include <device/display.h>
+#include <device/power.h>
+#include <device/callback.h>
+#include <bluetooth.h>
+#include <telephony-client/tapi_common.h>
+#include <telephony-client/TelNetwork.h>
+#include <wifi-manager.h>
+#include <notification.h>
+#include <notification_list.h>
+#include <time.h>
+#include <signal.h>
+#include <err.h>
+#include <execinfo.h>
+#include <appcore-efl.h>
+#include <app.h>
+#include <glib-2.0/glib/gprintf.h>
+#include <assert.h>
+#include <locale.h>
+#include <Ecore_Evas.h>
+#include <app_common.h>
+#include <mm_sound_private.h>
+}
+#include <cmock/cmock.h>
+
+DECLARE_FUNCTION_MOCK1(mock__eina_barrier_free, _eina_barrier_free, void(Eina_Barrier *));
+DECLARE_FUNCTION_MOCK2(mock__eina_barrier_new, _eina_barrier_new, Eina_Bool(Eina_Barrier *, int));
+DECLARE_FUNCTION_MOCK1(mock__eina_condition_free, _eina_condition_free, void(Eina_Condition *));
+DECLARE_FUNCTION_MOCK2(mock__eina_condition_new, _eina_condition_new, Eina_Bool(Eina_Condition *, Eina_Lock *));
+DECLARE_FUNCTION_MOCK4(mock__eina_crc, _eina_crc, unsigned int(const char *, int, unsigned int, Eina_Bool));
+DECLARE_FUNCTION_MOCK3(mock__eina_lock_debug_abort, _eina_lock_debug_abort, void(int, const char *, const volatile void *));
+DECLARE_FUNCTION_MOCK2(mock__eina_lock_debug_deadlock, _eina_lock_debug_deadlock, void(const char *, const volatile void *));
+DECLARE_FUNCTION_MOCK1(mock__eina_lock_free, _eina_lock_free, void(Eina_Lock *));
+DECLARE_FUNCTION_MOCK2(mock__eina_lock_new, _eina_lock_new, Eina_Bool(Eina_Lock *, Eina_Bool));
+DECLARE_FUNCTION_MOCK1(mock__eina_rwlock_free, _eina_rwlock_free, void(Eina_RWLock *));
+DECLARE_FUNCTION_MOCK1(mock__eina_rwlock_new, _eina_rwlock_new, Eina_Bool(Eina_RWLock *));
+DECLARE_FUNCTION_MOCK1(mock__eina_semaphore_free, _eina_semaphore_free, Eina_Bool(Eina_Semaphore *));
+DECLARE_FUNCTION_MOCK2(mock__eina_semaphore_new, _eina_semaphore_new, Eina_Bool(Eina_Semaphore *, int));
+DECLARE_FUNCTION_MOCK1(mock__eina_spinlock_free, _eina_spinlock_free, void(Eina_Spinlock *));
+DECLARE_FUNCTION_MOCK1(mock__eina_spinlock_new, _eina_spinlock_new, Eina_Bool(Eina_Spinlock *));
+DECLARE_FUNCTION_MOCK4(mock__eina_unicode_utf8_next_get, _eina_unicode_utf8_next_get, Eina_Unicode(int, unsigned char, const char *, int *));
+DECLARE_FUNCTION_MOCK1(mock_abs, abs, int(int));
+DECLARE_FUNCTION_MOCK0(mock_app_get_resource_path, app_get_resource_path, char *());
+DECLARE_FUNCTION_MOCK4(mock_appcore_efl_main, appcore_efl_main, int(const char *, int *, char ***, struct appcore_ops *));
+DECLARE_FUNCTION_MOCK3(mock_appcore_set_event_callback, appcore_set_event_callback, int(enum appcore_event, int (*)(void *, void *), void *));
+DECLARE_FUNCTION_MOCK4(mock_appsvc_run_service, appsvc_run_service, int(bundle *, int, appsvc_res_fn, void *));
+DECLARE_FUNCTION_MOCK2(mock_appsvc_set_operation, appsvc_set_operation, int(bundle *, const char *));
+DECLARE_FUNCTION_MOCK1(mock_atoi, atoi, int(const char *));
+DECLARE_FUNCTION_MOCK1(mock_atspi_accessible_get_action_iface, atspi_accessible_get_action_iface, AtspiAction *(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK2(mock_atspi_accessible_get_attributes, atspi_accessible_get_attributes, GHashTable *(AtspiAccessible *, GError **));
+DECLARE_FUNCTION_MOCK2(mock_atspi_accessible_get_bus_name, atspi_accessible_get_bus_name, gchar *(AtspiAccessible *, GError **));
+DECLARE_FUNCTION_MOCK3(mock_atspi_accessible_get_child_at_index, atspi_accessible_get_child_at_index, AtspiAccessible *(AtspiAccessible *, gint, GError **));
+DECLARE_FUNCTION_MOCK2(mock_atspi_accessible_get_child_count, atspi_accessible_get_child_count, gint(AtspiAccessible *, GError **));
+DECLARE_FUNCTION_MOCK1(mock_atspi_accessible_get_component_iface, atspi_accessible_get_component_iface, AtspiComponent *(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK2(mock_atspi_accessible_get_default_label_info, atspi_accessible_get_default_label_info, AtspiAccessibleDefaultLabelInfo *(AtspiAccessible *, GError **));
+DECLARE_FUNCTION_MOCK1(mock_atspi_accessible_get_editable_text_iface, atspi_accessible_get_editable_text_iface, AtspiEditableText *(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK2(mock_atspi_accessible_get_index_in_parent, atspi_accessible_get_index_in_parent, gint(AtspiAccessible *, GError **));
+DECLARE_FUNCTION_MOCK2(mock_atspi_accessible_get_localized_role_name, atspi_accessible_get_localized_role_name, gchar *(AtspiAccessible *, GError **));
+DECLARE_FUNCTION_MOCK2(mock_atspi_accessible_get_name, atspi_accessible_get_name, gchar *(AtspiAccessible *, GError **));
+DECLARE_FUNCTION_MOCK5(mock_atspi_accessible_get_navigable_at_point, atspi_accessible_get_navigable_at_point, AtspiAccessible *(AtspiAccessible *, gint, gint, AtspiCoordType, GError **));
+DECLARE_FUNCTION_MOCK4(mock_atspi_accessible_get_neighbor, atspi_accessible_get_neighbor, AtspiAccessible *(AtspiAccessible *, AtspiAccessible *, AtspiNeighborSearchDirection, GError **));
+DECLARE_FUNCTION_MOCK2(mock_atspi_accessible_get_parent, atspi_accessible_get_parent, AtspiAccessible *(AtspiAccessible *, GError **));
+DECLARE_FUNCTION_MOCK2(mock_atspi_accessible_get_reading_material, atspi_accessible_get_reading_material, AtspiAccessibleReadingMaterial *(AtspiAccessible *, GError **));
+DECLARE_FUNCTION_MOCK2(mock_atspi_accessible_get_relation_set, atspi_accessible_get_relation_set, GArray *(AtspiAccessible *, GError **));
+DECLARE_FUNCTION_MOCK2(mock_atspi_accessible_get_role, atspi_accessible_get_role, AtspiRole(AtspiAccessible *, GError **));
+DECLARE_FUNCTION_MOCK2(mock_atspi_accessible_get_role_name, atspi_accessible_get_role_name, gchar *(AtspiAccessible *, GError **));
+DECLARE_FUNCTION_MOCK1(mock_atspi_accessible_get_selection, atspi_accessible_get_selection, AtspiSelection *(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_atspi_accessible_get_selection_iface, atspi_accessible_get_selection_iface, AtspiSelection *(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_atspi_accessible_get_state_set, atspi_accessible_get_state_set, AtspiStateSet *(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_atspi_accessible_get_text_iface, atspi_accessible_get_text_iface, AtspiText *(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK2(mock_atspi_accessible_get_toolkit_name, atspi_accessible_get_toolkit_name, gchar *(AtspiAccessible *, GError **));
+DECLARE_FUNCTION_MOCK2(mock_atspi_accessible_get_unique_id, atspi_accessible_get_unique_id, gchar *(AtspiAccessible *, GError **));
+DECLARE_FUNCTION_MOCK1(mock_atspi_accessible_get_value_iface, atspi_accessible_get_value_iface, AtspiValue *(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK3(mock_atspi_action_do_action_name, atspi_action_do_action_name, gboolean(AtspiAction *, const gchar *, GError **));
+DECLARE_FUNCTION_MOCK3(mock_atspi_action_get_action_name, atspi_action_get_action_name, gchar *(AtspiAction *, gint, GError **));
+DECLARE_FUNCTION_MOCK2(mock_atspi_action_get_n_actions, atspi_action_get_n_actions, gint(AtspiAction *, GError **));
+DECLARE_FUNCTION_MOCK2(mock_atspi_component_clear_highlight, atspi_component_clear_highlight, gboolean(AtspiComponent *, GError **));
+DECLARE_FUNCTION_MOCK3(mock_atspi_component_get_extents, atspi_component_get_extents, AtspiRect *(AtspiComponent *, AtspiCoordType, GError **));
+DECLARE_FUNCTION_MOCK0(mock_atspi_component_get_type, atspi_component_get_type, GType());
+DECLARE_FUNCTION_MOCK2(mock_atspi_component_grab_focus, atspi_component_grab_focus, gboolean(AtspiComponent *, GError **));
+DECLARE_FUNCTION_MOCK2(mock_atspi_component_grab_highlight, atspi_component_grab_highlight, gboolean(AtspiComponent *, GError **));
+DECLARE_FUNCTION_MOCK5(mock_atspi_deregister_keystroke_listener, atspi_deregister_keystroke_listener, gboolean(AtspiDeviceListener *, GArray *, AtspiKeyMaskType, AtspiKeyEventMask, GError **));
+DECLARE_FUNCTION_MOCK3(mock_atspi_device_listener_new, atspi_device_listener_new, AtspiDeviceListener *(AtspiDeviceListenerCB, void *, GDestroyNotify));
+DECLARE_FUNCTION_MOCK4(mock_atspi_editable_text_copy_text, atspi_editable_text_copy_text, gboolean(AtspiEditableText *, gint, gint, GError **));
+DECLARE_FUNCTION_MOCK4(mock_atspi_editable_text_cut_text, atspi_editable_text_cut_text, gboolean(AtspiEditableText *, gint, gint, GError **));
+DECLARE_FUNCTION_MOCK4(mock_atspi_editable_text_delete_text, atspi_editable_text_delete_text, gboolean(AtspiEditableText *, gint, gint, GError **));
+DECLARE_FUNCTION_MOCK3(mock_atspi_editable_text_paste_text, atspi_editable_text_paste_text, gboolean(AtspiEditableText *, gint, GError **));
+DECLARE_FUNCTION_MOCK3(mock_atspi_event_listener_deregister, atspi_event_listener_deregister, gboolean(AtspiEventListener *, const gchar *, GError **));
+DECLARE_FUNCTION_MOCK3(mock_atspi_event_listener_new, atspi_event_listener_new, AtspiEventListener *(AtspiEventListenerCB, gpointer, GDestroyNotify));
+DECLARE_FUNCTION_MOCK3(mock_atspi_event_listener_register, atspi_event_listener_register, gboolean(AtspiEventListener *, const gchar *, GError **));
+DECLARE_FUNCTION_MOCK0(mock_atspi_exit, atspi_exit, int());
+DECLARE_FUNCTION_MOCK0(mock_atspi_init, atspi_init, int());
+DECLARE_FUNCTION_MOCK0(mock_atspi_object_get_type, atspi_object_get_type, GType());
+DECLARE_FUNCTION_MOCK6(mock_atspi_register_keystroke_listener, atspi_register_keystroke_listener, gboolean(AtspiDeviceListener *, GArray *, AtspiKeyMaskType, AtspiKeyEventMask, AtspiKeyListenerSyncType, GError **));
+DECLARE_FUNCTION_MOCK1(mock_atspi_relation_get_n_targets, atspi_relation_get_n_targets, gint(AtspiRelation *));
+DECLARE_FUNCTION_MOCK1(mock_atspi_relation_get_relation_type, atspi_relation_get_relation_type, AtspiRelationType(AtspiRelation *));
+DECLARE_FUNCTION_MOCK2(mock_atspi_relation_get_target, atspi_relation_get_target, AtspiAccessible *(AtspiRelation *, gint));
+DECLARE_FUNCTION_MOCK3(mock_atspi_selection_deselect_child, atspi_selection_deselect_child, gboolean(AtspiSelection *, gint, GError **));
+DECLARE_FUNCTION_MOCK2(mock_atspi_selection_get_n_selected_children, atspi_selection_get_n_selected_children, gint(AtspiSelection *, GError **));
+DECLARE_FUNCTION_MOCK3(mock_atspi_selection_select_child, atspi_selection_select_child, gboolean(AtspiSelection *, gint, GError **));
+DECLARE_FUNCTION_MOCK2(mock_atspi_state_set_contains, atspi_state_set_contains, gboolean(AtspiStateSet *, AtspiStateType));
+DECLARE_FUNCTION_MOCK2(mock_atspi_text_get_caret_offset, atspi_text_get_caret_offset, gint(AtspiText *, GError **));
+DECLARE_FUNCTION_MOCK2(mock_atspi_text_get_character_count, atspi_text_get_character_count, gint(AtspiText *, GError **));
+DECLARE_FUNCTION_MOCK3(mock_atspi_text_get_selection, atspi_text_get_selection, AtspiRange *(AtspiText *, gint, GError **));
+DECLARE_FUNCTION_MOCK4(mock_atspi_text_get_text, atspi_text_get_text, gchar *(AtspiText *, gint, gint, GError **));
+DECLARE_FUNCTION_MOCK3(mock_atspi_text_remove_selection, atspi_text_remove_selection, gboolean(AtspiText *, gint, GError **));
+DECLARE_FUNCTION_MOCK3(mock_atspi_text_set_caret_offset, atspi_text_set_caret_offset, gboolean(AtspiText *, gint, GError **));
+DECLARE_FUNCTION_MOCK5(mock_atspi_text_set_selection, atspi_text_set_selection, gboolean(AtspiText *, gint, gint, gint, GError **));
+DECLARE_FUNCTION_MOCK2(mock_atspi_value_get_current_value, atspi_value_get_current_value, gdouble(AtspiValue *, GError **));
+DECLARE_FUNCTION_MOCK2(mock_atspi_value_get_maximum_value, atspi_value_get_maximum_value, gdouble(AtspiValue *, GError **));
+DECLARE_FUNCTION_MOCK2(mock_atspi_value_get_minimum_increment, atspi_value_get_minimum_increment, gdouble(AtspiValue *, GError **));
+DECLARE_FUNCTION_MOCK2(mock_atspi_value_get_minimum_value, atspi_value_get_minimum_value, gdouble(AtspiValue *, GError **));
+DECLARE_FUNCTION_MOCK3(mock_atspi_value_set_current_value, atspi_value_set_current_value, gboolean(AtspiValue *, gdouble, GError **));
+DECLARE_FUNCTION_MOCK1(mock_aul_app_get_status_bypid, aul_app_get_status_bypid, int(int));
+DECLARE_FUNCTION_MOCK1(mock_aul_terminate_pid, aul_terminate_pid, int(int));
+DECLARE_FUNCTION_MOCK2(mock_backtrace, backtrace, int(void **, int));
+DECLARE_FUNCTION_MOCK2(mock_backtrace_symbols, backtrace_symbols, char **(void *const *, int));
+DECLARE_FUNCTION_MOCK2(mock_bt_adapter_foreach_bonded_device, bt_adapter_foreach_bonded_device, int(bt_adapter_bonded_device_cb, void *));
+DECLARE_FUNCTION_MOCK1(mock_bt_adapter_get_state, bt_adapter_get_state, int(bt_adapter_state_e *));
+DECLARE_FUNCTION_MOCK0(mock_bt_deinitialize, bt_deinitialize, int());
+DECLARE_FUNCTION_MOCK0(mock_bt_initialize, bt_initialize, int());
+DECLARE_FUNCTION_MOCK3(mock_bundle_add_str, bundle_add_str, int(bundle *, const char *, const char *));
+DECLARE_FUNCTION_MOCK0(mock_bundle_create, bundle_create, bundle *());
+DECLARE_FUNCTION_MOCK1(mock_bundle_free, bundle_free, int(bundle *));
+DECLARE_FUNCTION_MOCK3(mock_bundle_get_str, bundle_get_str, int(bundle *, const char *, char **));
+DECLARE_FUNCTION_MOCK2(mock_clock_gettime, clock_gettime, int(clockid_t, struct timespec *));
+DECLARE_FUNCTION_MOCK1(mock_dbus_address_entries_free, dbus_address_entries_free, void(DBusAddressEntry **));
+DECLARE_FUNCTION_MOCK1(mock_dbus_connection_unref, dbus_connection_unref, void(DBusConnection *));
+DECLARE_FUNCTION_MOCK1(mock_dbus_message_unref, dbus_message_unref, void(DBusMessage *));
+DECLARE_FUNCTION_MOCK1(mock_dbus_pending_call_unref, dbus_pending_call_unref, void(DBusPendingCall *));
+DECLARE_FUNCTION_MOCK1(mock_dbus_server_unref, dbus_server_unref, void(DBusServer *));
+DECLARE_FUNCTION_MOCK3(mock_device_add_callback, device_add_callback, int(device_callback_e, device_changed_cb, void *));
+DECLARE_FUNCTION_MOCK1(mock_device_battery_get_level_status, device_battery_get_level_status, int(device_battery_level_e *));
+DECLARE_FUNCTION_MOCK1(mock_device_battery_get_percent, device_battery_get_percent, int(int *));
+DECLARE_FUNCTION_MOCK1(mock_device_battery_is_charging, device_battery_is_charging, int(_Bool *));
+DECLARE_FUNCTION_MOCK1(mock_device_display_get_state, device_display_get_state, int(display_state_e *));
+DECLARE_FUNCTION_MOCK1(mock_device_haptic_close, device_haptic_close, int(haptic_device_h));
+DECLARE_FUNCTION_MOCK1(mock_device_haptic_get_count, device_haptic_get_count, int(int *));
+DECLARE_FUNCTION_MOCK2(mock_device_haptic_open, device_haptic_open, int(int, haptic_device_h *));
+DECLARE_FUNCTION_MOCK2(mock_device_haptic_stop, device_haptic_stop, int(haptic_device_h, haptic_effect_h));
+DECLARE_FUNCTION_MOCK4(mock_device_haptic_vibrate, device_haptic_vibrate, int(haptic_device_h, int, int, haptic_effect_h *));
+DECLARE_FUNCTION_MOCK1(mock_device_power_release_lock, device_power_release_lock, int(power_lock_e));
+DECLARE_FUNCTION_MOCK2(mock_device_power_request_lock, device_power_request_lock, int(power_lock_e, int));
+DECLARE_FUNCTION_MOCK2(mock_device_remove_callback, device_remove_callback, int(device_callback_e, device_changed_cb));
+DECLARE_FUNCTION_MOCK0(mock_ecore_time_get, ecore_time_get, double());
+DECLARE_FUNCTION_MOCK3(mock_ecore_timer_add, ecore_timer_add, Ecore_Timer *(double, Ecore_Task_Cb, const void *));
+DECLARE_FUNCTION_MOCK1(mock_ecore_timer_del, ecore_timer_del, void *(Ecore_Timer *));
+DECLARE_FUNCTION_MOCK1(mock_ecore_timer_reset, ecore_timer_reset, void(Efl_Loop_Timer *));
+DECLARE_FUNCTION_MOCK1(mock_efl_ref, efl_ref, Eo *(const Eo *));
+DECLARE_FUNCTION_MOCK1(mock_efl_unref, efl_unref, void(const Eo *));
+DECLARE_FUNCTION_MOCK1(mock_eina_array_grow, eina_array_grow, Eina_Bool(Eina_Array *));
+DECLARE_FUNCTION_MOCK1(mock_eina_content_converter_possible_conversions, eina_content_converter_possible_conversions, Eina_Iterator *(const char *));
+DECLARE_FUNCTION_MOCK1(mock_eina_content_type_get, eina_content_type_get, const char *(Eina_Content *));
+DECLARE_FUNCTION_MOCK1(mock_eina_error_set, eina_error_set, void(Eina_Error));
+DECLARE_FUNCTION_MOCK0(mock_eina_freeq_main_get, eina_freeq_main_get, Eina_FreeQ *());
+DECLARE_FUNCTION_MOCK4(mock_eina_freeq_ptr_add, eina_freeq_ptr_add, void(Eina_FreeQ *, void *, void (*)(void *), size_t));
+DECLARE_FUNCTION_MOCK1(mock_eina_future_new, eina_future_new, Eina_Future *(Eina_Promise *));
+DECLARE_FUNCTION_MOCK3(mock_eina_hash_add, eina_hash_add, Eina_Bool(Eina_Hash *, const void *, const void *));
+DECLARE_FUNCTION_MOCK2(mock_eina_hash_del_by_key, eina_hash_del_by_key, Eina_Bool(Eina_Hash *, const void *));
+DECLARE_FUNCTION_MOCK2(mock_eina_hash_find, eina_hash_find, void *(const Eina_Hash *, const void *));
+DECLARE_FUNCTION_MOCK1(mock_eina_hash_population, eina_hash_population, int(const Eina_Hash *));
+DECLARE_FUNCTION_MOCK3(mock_eina_inarray_alloc_at, eina_inarray_alloc_at, void *(Eina_Inarray *, unsigned int, unsigned int));
+DECLARE_FUNCTION_MOCK1(mock_eina_inarray_count, eina_inarray_count, unsigned int(const Eina_Inarray *));
+DECLARE_FUNCTION_MOCK2(mock_eina_inarray_nth, eina_inarray_nth, void *(const Eina_Inarray *, unsigned int));
+DECLARE_FUNCTION_MOCK2(mock_eina_inarray_remove_at, eina_inarray_remove_at, Eina_Bool(Eina_Inarray *, unsigned int));
+DECLARE_FUNCTION_MOCK2(mock_eina_list_append, eina_list_append, Eina_List *(Eina_List *, const void *));
+DECLARE_FUNCTION_MOCK3(mock_eina_list_append_relative_list, eina_list_append_relative_list, Eina_List *(Eina_List *, const void *, Eina_List *));
+DECLARE_FUNCTION_MOCK2(mock_eina_list_nth, eina_list_nth, void *(const Eina_List *, unsigned int));
+DECLARE_FUNCTION_MOCK2(mock_eina_list_nth_list, eina_list_nth_list, Eina_List *(const Eina_List *, unsigned int));
+DECLARE_FUNCTION_MOCK2(mock_eina_list_prepend, eina_list_prepend, Eina_List *(Eina_List *, const void *));
+DECLARE_FUNCTION_MOCK2(mock_eina_list_remove, eina_list_remove, Eina_List *(Eina_List *, const void *));
+DECLARE_FUNCTION_MOCK2(mock_eina_list_remove_list, eina_list_remove_list, Eina_List *(Eina_List *, Eina_List *));
+DECLARE_FUNCTION_MOCK1(mock_eina_lock_debug, eina_lock_debug, void(const Eina_Lock *));
+DECLARE_FUNCTION_MOCK0(mock_eina_log_color_disable_get, eina_log_color_disable_get, Eina_Bool());
+DECLARE_FUNCTION_MOCK1(mock_eina_log_domain_registered_level_get, eina_log_domain_registered_level_get, int(int));
+DECLARE_FUNCTION_MOCK0(mock_eina_log_level_get, eina_log_level_get, int());
+DECLARE_FUNCTION_MOCK1(mock_eina_matrix3_type_get, eina_matrix3_type_get, Eina_Matrix_Type(const Eina_Matrix3 *));
+DECLARE_FUNCTION_MOCK1(mock_eina_matrix4_type_get, eina_matrix4_type_get, Eina_Matrix_Type(const Eina_Matrix4 *));
+DECLARE_FUNCTION_MOCK1(mock_eina_promise_all_array, eina_promise_all_array, Eina_Promise *(Eina_Future *[]));
+DECLARE_FUNCTION_MOCK1(mock_eina_promise_all_iterator, eina_promise_all_iterator, Eina_Promise *(Eina_Iterator *));
+DECLARE_FUNCTION_MOCK1(mock_eina_promise_race_array, eina_promise_race_array, Eina_Promise *(Eina_Future *[]));
+DECLARE_FUNCTION_MOCK2(mock_eina_slstr_vasprintf_new, eina_slstr_vasprintf_new, Eina_Slstr *(const char *, va_list));
+DECLARE_FUNCTION_MOCK7(mock_eina_str_join_len, eina_str_join_len, size_t(char *, size_t, char, const char *, size_t, const char *, size_t));
+DECLARE_FUNCTION_MOCK4(mock_eina_str_split_full, eina_str_split_full, char **(const char *, const char *, int, unsigned int *));
+DECLARE_FUNCTION_MOCK2(mock_eina_strbuf_append, eina_strbuf_append, Eina_Bool(Eina_Strbuf *, const char *));
+DECLARE_FUNCTION_MOCK2(mock_eina_strbuf_append_char, eina_strbuf_append_char, Eina_Bool(Eina_Strbuf *, char));
+DECLARE_FUNCTION_MOCK3(mock_eina_strbuf_append_length, eina_strbuf_append_length, Eina_Bool(Eina_Strbuf *, const char *, size_t));
+DECLARE_FUNCTION_MOCK1(mock_eina_strbuf_free, eina_strbuf_free, void(Eina_Strbuf *));
+DECLARE_FUNCTION_MOCK1(mock_eina_strbuf_length_get, eina_strbuf_length_get, size_t(const Eina_Strbuf *));
+DECLARE_FUNCTION_MOCK0(mock_eina_strbuf_new, eina_strbuf_new, Eina_Strbuf *());
+DECLARE_FUNCTION_MOCK3(mock_eina_strbuf_replace_all, eina_strbuf_replace_all, int(Eina_Strbuf *, const char *, const char *));
+DECLARE_FUNCTION_MOCK1(mock_eina_strbuf_string_get, eina_strbuf_string_get, const char *(const Eina_Strbuf *));
+DECLARE_FUNCTION_MOCK1(mock_eina_strbuf_string_steal, eina_strbuf_string_steal, char *(Eina_Strbuf *));
+DECLARE_FUNCTION_MOCK1(mock_eina_strbuf_trim, eina_strbuf_trim, void(Eina_Strbuf *));
+DECLARE_FUNCTION_MOCK1(mock_eina_stringshare_add, eina_stringshare_add, Eina_Stringshare *(const char *));
+DECLARE_FUNCTION_MOCK2(mock_eina_stringshare_add_length, eina_stringshare_add_length, Eina_Stringshare *(const char *, unsigned int));
+DECLARE_FUNCTION_MOCK1(mock_eina_stringshare_del, eina_stringshare_del, void(Eina_Stringshare *));
+DECLARE_FUNCTION_MOCK1(mock_eina_stringshare_ref, eina_stringshare_ref, Eina_Stringshare *(Eina_Stringshare *));
+DECLARE_FUNCTION_MOCK1(mock_eina_stringshare_strlen, eina_stringshare_strlen, int(Eina_Stringshare *));
+DECLARE_FUNCTION_MOCK2(mock_eina_unicode_unicode_to_utf8, eina_unicode_unicode_to_utf8, char *(const Eina_Unicode *, int *));
+DECLARE_FUNCTION_MOCK1(mock_eina_unicode_utf8_get_len, eina_unicode_utf8_get_len, int(const char *));
+DECLARE_FUNCTION_MOCK1(mock_eina_ustringshare_add, eina_ustringshare_add, const Eina_Unicode *(const Eina_Unicode *));
+DECLARE_FUNCTION_MOCK2(mock_eina_ustringshare_add_length, eina_ustringshare_add_length, const Eina_Unicode *(const Eina_Unicode *, unsigned int));
+DECLARE_FUNCTION_MOCK1(mock_eina_ustringshare_del, eina_ustringshare_del, void(const Eina_Unicode *));
+DECLARE_FUNCTION_MOCK2(mock_eina_value_convert, eina_value_convert, Eina_Bool(const Eina_Value *, Eina_Value *));
+DECLARE_FUNCTION_MOCK2(mock_eina_value_copy, eina_value_copy, Eina_Bool(const Eina_Value *, Eina_Value *));
+DECLARE_FUNCTION_MOCK1(mock_eina_value_inner_alloc, eina_value_inner_alloc, void *(size_t));
+DECLARE_FUNCTION_MOCK2(mock_eina_value_inner_free, eina_value_inner_free, void(size_t, void *));
+DECLARE_FUNCTION_MOCK1(mock_eina_value_new, eina_value_new, Eina_Value *(const Eina_Value_Type *));
+DECLARE_FUNCTION_MOCK2(mock_eina_value_struct_member_find, eina_value_struct_member_find, const Eina_Value_Struct_Member *(const Eina_Value_Struct *, const char *));
+DECLARE_FUNCTION_MOCK1(mock_eina_value_type_check, eina_value_type_check, Eina_Bool(const Eina_Value_Type *));
+DECLARE_FUNCTION_MOCK1(mock_eldbus_address_connection_get, eldbus_address_connection_get, Eldbus_Connection *(const char *));
+DECLARE_FUNCTION_MOCK1(mock_eldbus_connection_get, eldbus_connection_get, Eldbus_Connection *(Eldbus_Connection_Type));
+DECLARE_FUNCTION_MOCK5(mock_eldbus_connection_send, eldbus_connection_send, Eldbus_Pending *(Eldbus_Connection *, Eldbus_Message *, Eldbus_Message_Cb, const void *, double));
+DECLARE_FUNCTION_MOCK1(mock_eldbus_connection_unref, eldbus_connection_unref, void(Eldbus_Connection *));
+DECLARE_FUNCTION_MOCK0(mock_eldbus_init, eldbus_init, int());
+DECLARE_FUNCTION_MOCK3(mock_eldbus_message_error_get, eldbus_message_error_get, Eina_Bool(const Eldbus_Message *, const char **, const char **));
+DECLARE_FUNCTION_MOCK3(mock_eldbus_message_error_new, eldbus_message_error_new, Eldbus_Message *(const Eldbus_Message *, const char *, const char *));
+DECLARE_FUNCTION_MOCK2(mock_eldbus_message_iter_container_close, eldbus_message_iter_container_close, Eina_Bool(Eldbus_Message_Iter *, Eldbus_Message_Iter *));
+DECLARE_FUNCTION_MOCK3(mock_eldbus_message_iter_container_new, eldbus_message_iter_container_new, Eldbus_Message_Iter *(Eldbus_Message_Iter *, int, const char *));
+DECLARE_FUNCTION_MOCK1(mock_eldbus_message_iter_get, eldbus_message_iter_get, Eldbus_Message_Iter *(const Eldbus_Message *));
+DECLARE_FUNCTION_MOCK4(mock_eldbus_message_method_call_new, eldbus_message_method_call_new, Eldbus_Message *(const char *, const char *, const char *, const char *));
+DECLARE_FUNCTION_MOCK1(mock_eldbus_message_method_return_new, eldbus_message_method_return_new, Eldbus_Message *(const Eldbus_Message *));
+DECLARE_FUNCTION_MOCK1(mock_eldbus_message_ref, eldbus_message_ref, Eldbus_Message *(Eldbus_Message *));
+DECLARE_FUNCTION_MOCK1(mock_eldbus_message_unref, eldbus_message_unref, void(Eldbus_Message *));
+DECLARE_FUNCTION_MOCK4(mock_eldbus_name_release, eldbus_name_release, Eldbus_Pending *(Eldbus_Connection *, const char *, Eldbus_Message_Cb, const void *));
+DECLARE_FUNCTION_MOCK5(mock_eldbus_name_request, eldbus_name_request, Eldbus_Pending *(Eldbus_Connection *, const char *, unsigned int, Eldbus_Message_Cb, const void *));
+DECLARE_FUNCTION_MOCK3(mock_eldbus_object_get, eldbus_object_get, Eldbus_Object *(Eldbus_Connection *, const char *, const char *));
+DECLARE_FUNCTION_MOCK1(mock_eldbus_object_unref, eldbus_object_unref, void(Eldbus_Object *));
+DECLARE_FUNCTION_MOCK2(mock_eldbus_proxy_get, eldbus_proxy_get, Eldbus_Proxy *(Eldbus_Object *, const char *));
+DECLARE_FUNCTION_MOCK2(mock_eldbus_proxy_method_call_new, eldbus_proxy_method_call_new, Eldbus_Message *(Eldbus_Proxy *, const char *));
+DECLARE_FUNCTION_MOCK5(mock_eldbus_proxy_send, eldbus_proxy_send, Eldbus_Pending *(Eldbus_Proxy *, Eldbus_Message *, Eldbus_Message_Cb, const void *, double));
+DECLARE_FUNCTION_MOCK3(mock_eldbus_proxy_send_and_block, eldbus_proxy_send_and_block, Eldbus_Message *(Eldbus_Proxy *, Eldbus_Message *, double));
+DECLARE_FUNCTION_MOCK4(mock_eldbus_proxy_signal_handler_add, eldbus_proxy_signal_handler_add, Eldbus_Signal_Handler *(Eldbus_Proxy *, const char *, Eldbus_Signal_Cb, const void *));
+DECLARE_FUNCTION_MOCK1(mock_eldbus_proxy_unref, eldbus_proxy_unref, void(Eldbus_Proxy *));
+DECLARE_FUNCTION_MOCK3(mock_eldbus_service_interface_register, eldbus_service_interface_register, Eldbus_Service_Interface *(Eldbus_Connection *, const char *, const Eldbus_Service_Interface_Desc *));
+DECLARE_FUNCTION_MOCK1(mock_eldbus_service_object_unregister, eldbus_service_object_unregister, void(Eldbus_Service_Interface *));
+DECLARE_FUNCTION_MOCK0(mock_eldbus_shutdown, eldbus_shutdown, int());
+DECLARE_FUNCTION_MOCK1(mock_elm_box_add, elm_box_add, Evas_Object *(Evas_Object *));
+DECLARE_FUNCTION_MOCK2(mock_elm_box_pack_end, elm_box_pack_end, void(Elm_Box *, Efl_Canvas_Object *));
+DECLARE_FUNCTION_MOCK1(mock_elm_config_atspi_mode_set, elm_config_atspi_mode_set, void(Eina_Bool));
+DECLARE_FUNCTION_MOCK0(mock_elm_exit, elm_exit, void());
+DECLARE_FUNCTION_MOCK2(mock_elm_init, elm_init, int(int, char **));
+DECLARE_FUNCTION_MOCK1(mock_elm_label_add, elm_label_add, Evas_Object *(Evas_Object *));
+DECLARE_FUNCTION_MOCK6(mock_elm_naviframe_item_push, elm_naviframe_item_push, Elm_Object_Item *(Evas_Object *, const char *, Evas_Object *, Evas_Object *, Evas_Object *, const char *));
+DECLARE_FUNCTION_MOCK3(mock_elm_naviframe_item_title_enabled_set, elm_naviframe_item_title_enabled_set, void(Elm_Object_Item *, Eina_Bool, Eina_Bool));
+DECLARE_FUNCTION_MOCK3(mock_elm_object_part_text_set, elm_object_part_text_set, void(Evas_Object *, const char *, const char *));
+DECLARE_FUNCTION_MOCK0(mock_elm_shutdown, elm_shutdown, int());
+DECLARE_FUNCTION_MOCK3(mock_elm_win_add, elm_win_add, Evas_Object *(Evas_Object *, const char *, Elm_Win_Type));
+DECLARE_FUNCTION_MOCK2(mock_elm_win_alpha_set, elm_win_alpha_set, void(Evas_Object *, Eina_Bool));
+DECLARE_FUNCTION_MOCK2(mock_elm_win_borderless_set, elm_win_borderless_set, void(Evas_Object *, Eina_Bool));
+DECLARE_FUNCTION_MOCK2(mock_elm_win_quickpanel_set, elm_win_quickpanel_set, void(Evas_Object *, Eina_Bool));
+DECLARE_FUNCTION_MOCK1(mock_elm_win_raise, elm_win_raise, void(Elm_Win *));
+DECLARE_FUNCTION_MOCK2(mock_elm_win_resize_object_add, elm_win_resize_object_add, void(Evas_Object *, Evas_Object *));
+DECLARE_FUNCTION_MOCK2(mock_elm_win_title_set, elm_win_title_set, void(Evas_Object *, const char *));
+DECLARE_FUNCTION_MOCK1(mock_evas_object_del, evas_object_del, void(Evas_Object *));
+DECLARE_FUNCTION_MOCK1(mock_evas_object_show, evas_object_show, void(Evas_Object *));
+DECLARE_FUNCTION_MOCK3(mock_evas_object_size_hint_align_set, evas_object_size_hint_align_set, void(Evas_Object *, double, double));
+DECLARE_FUNCTION_MOCK3(mock_evas_object_size_hint_weight_set, evas_object_size_hint_weight_set, void(Evas_Object *, double, double));
+DECLARE_FUNCTION_MOCK1(mock_fabs, fabs, double(double));
+DECLARE_FUNCTION_MOCK1(mock_fclose, fclose, int(FILE *));
+DECLARE_FUNCTION_MOCK2(mock_fopen, fopen, FILE *(const char *, const char *));
+DECLARE_FUNCTION_MOCK2(mock_fputs, fputs, int(const char *, FILE *));
+DECLARE_FUNCTION_MOCK2(mock_g_array_free, g_array_free, gchar *(GArray *, gboolean));
+DECLARE_FUNCTION_MOCK1(mock_g_array_unref, g_array_unref, void(GArray *));
+DECLARE_FUNCTION_MOCK5(mock_g_assertion_message, g_assertion_message, void(const char *, const char *, int, const char *, const char *));
+DECLARE_FUNCTION_MOCK1(mock_g_async_queue_unref, g_async_queue_unref, void(GAsyncQueue *));
+DECLARE_FUNCTION_MOCK1(mock_g_bookmark_file_free, g_bookmark_file_free, void(GBookmarkFile *));
+DECLARE_FUNCTION_MOCK1(mock_g_byte_array_unref, g_byte_array_unref, void(GByteArray *));
+DECLARE_FUNCTION_MOCK1(mock_g_bytes_unref, g_bytes_unref, void(GBytes *));
+DECLARE_FUNCTION_MOCK1(mock_g_checksum_free, g_checksum_free, void(GChecksum *));
+DECLARE_FUNCTION_MOCK1(mock_g_clear_error, g_clear_error, void(GError **));
+DECLARE_FUNCTION_MOCK1(mock_g_closure_unref, g_closure_unref, void(GClosure *));
+DECLARE_FUNCTION_MOCK1(mock_g_cond_clear, g_cond_clear, void(GCond *));
+DECLARE_FUNCTION_MOCK1(mock_g_date_time_unref, g_date_time_unref, void(GDateTime *));
+DECLARE_FUNCTION_MOCK1(mock_g_dir_close, g_dir_close, void(GDir *));
+DECLARE_FUNCTION_MOCK1(mock_g_error_free, g_error_free, void(GError *));
+DECLARE_FUNCTION_MOCK1(mock_g_free, g_free, void(gpointer));
+DECLARE_FUNCTION_MOCK1(mock_g_hash_table_destroy, g_hash_table_destroy, void(GHashTable *));
+DECLARE_FUNCTION_MOCK3(mock_g_hash_table_insert, g_hash_table_insert, gboolean(GHashTable *, gpointer, gpointer));
+DECLARE_FUNCTION_MOCK2(mock_g_hash_table_lookup, g_hash_table_lookup, gpointer(GHashTable *, gconstpointer));
+DECLARE_FUNCTION_MOCK2(mock_g_hash_table_new, g_hash_table_new, GHashTable *(GHashFunc, GEqualFunc));
+DECLARE_FUNCTION_MOCK1(mock_g_hash_table_unref, g_hash_table_unref, void(GHashTable *));
+DECLARE_FUNCTION_MOCK1(mock_g_hmac_unref, g_hmac_unref, void(GHmac *));
+DECLARE_FUNCTION_MOCK1(mock_g_io_channel_unref, g_io_channel_unref, void(GIOChannel *));
+DECLARE_FUNCTION_MOCK1(mock_g_key_file_unref, g_key_file_unref, void(GKeyFile *));
+DECLARE_FUNCTION_MOCK1(mock_g_list_free, g_list_free, void(GList *));
+DECLARE_FUNCTION_MOCK2(mock_g_list_free_full, g_list_free_full, void(GList *, GDestroyNotify));
+DECLARE_FUNCTION_MOCK1(mock_g_main_context_unref, g_main_context_unref, void(GMainContext *));
+DECLARE_FUNCTION_MOCK1(mock_g_main_loop_unref, g_main_loop_unref, void(GMainLoop *));
+DECLARE_FUNCTION_MOCK1(mock_g_malloc0, g_malloc0, gpointer(gsize));
+DECLARE_FUNCTION_MOCK2(mock_g_malloc_n, g_malloc_n, gpointer(gsize, gsize));
+DECLARE_FUNCTION_MOCK1(mock_g_mapped_file_unref, g_mapped_file_unref, void(GMappedFile *));
+DECLARE_FUNCTION_MOCK1(mock_g_markup_parse_context_unref, g_markup_parse_context_unref, void(GMarkupParseContext *));
+DECLARE_FUNCTION_MOCK1(mock_g_match_info_unref, g_match_info_unref, void(GMatchInfo *));
+DECLARE_FUNCTION_MOCK1(mock_g_mutex_clear, g_mutex_clear, void(GMutex *));
+DECLARE_FUNCTION_MOCK1(mock_g_mutex_lock, g_mutex_lock, void(GMutex *));
+DECLARE_FUNCTION_MOCK1(mock_g_mutex_unlock, g_mutex_unlock, void(GMutex *));
+DECLARE_FUNCTION_MOCK1(mock_g_node_destroy, g_node_destroy, void(GNode *));
+DECLARE_FUNCTION_MOCK2(mock_g_object_add_weak_pointer, g_object_add_weak_pointer, void(GObject *, gpointer *));
+DECLARE_FUNCTION_MOCK1(mock_g_object_ref, g_object_ref, gpointer(gpointer));
+DECLARE_FUNCTION_MOCK2(mock_g_object_remove_weak_pointer, g_object_remove_weak_pointer, void(GObject *, gpointer *));
+DECLARE_FUNCTION_MOCK1(mock_g_object_unref, g_object_unref, void(gpointer));
+DECLARE_FUNCTION_MOCK1(mock_g_option_context_free, g_option_context_free, void(GOptionContext *));
+DECLARE_FUNCTION_MOCK1(mock_g_option_group_unref, g_option_group_unref, void(GOptionGroup *));
+DECLARE_FUNCTION_MOCK1(mock_g_param_spec_unref, g_param_spec_unref, void(GParamSpec *));
+DECLARE_FUNCTION_MOCK1(mock_g_pattern_spec_free, g_pattern_spec_free, void(GPatternSpec *));
+DECLARE_FUNCTION_MOCK1(mock_g_ptr_array_unref, g_ptr_array_unref, void(GPtrArray *));
+DECLARE_FUNCTION_MOCK1(mock_g_queue_clear, g_queue_clear, void(GQueue *));
+DECLARE_FUNCTION_MOCK1(mock_g_queue_free, g_queue_free, void(GQueue *));
+DECLARE_FUNCTION_MOCK2(mock_g_queue_free_full, g_queue_free_full, void(GQueue *, GDestroyNotify));
+DECLARE_FUNCTION_MOCK1(mock_g_rand_free, g_rand_free, void(GRand *));
+DECLARE_FUNCTION_MOCK1(mock_g_rec_mutex_lock, g_rec_mutex_lock, void(GRecMutex *));
+DECLARE_FUNCTION_MOCK1(mock_g_rec_mutex_unlock, g_rec_mutex_unlock, void(GRecMutex *));
+DECLARE_FUNCTION_MOCK1(mock_g_ref_string_release, g_ref_string_release, void(char *));
+DECLARE_FUNCTION_MOCK1(mock_g_regex_unref, g_regex_unref, void(GRegex *));
+DECLARE_FUNCTION_MOCK1(mock_g_rw_lock_reader_lock, g_rw_lock_reader_lock, void(GRWLock *));
+DECLARE_FUNCTION_MOCK1(mock_g_rw_lock_reader_unlock, g_rw_lock_reader_unlock, void(GRWLock *));
+DECLARE_FUNCTION_MOCK1(mock_g_rw_lock_writer_lock, g_rw_lock_writer_lock, void(GRWLock *));
+DECLARE_FUNCTION_MOCK1(mock_g_rw_lock_writer_unlock, g_rw_lock_writer_unlock, void(GRWLock *));
+DECLARE_FUNCTION_MOCK1(mock_g_scanner_destroy, g_scanner_destroy, void(GScanner *));
+DECLARE_FUNCTION_MOCK1(mock_g_sequence_free, g_sequence_free, void(GSequence *));
+DECLARE_FUNCTION_MOCK1(mock_g_slist_free, g_slist_free, void(GSList *));
+DECLARE_FUNCTION_MOCK2(mock_g_slist_free_full, g_slist_free_full, void(GSList *, GDestroyNotify));
+DECLARE_FUNCTION_MOCK1(mock_g_source_remove, g_source_remove, gboolean(guint));
+DECLARE_FUNCTION_MOCK1(mock_g_source_unref, g_source_unref, void(GSource *));
+DECLARE_FUNCTION_MOCK2(mock_g_str_equal, g_str_equal, gboolean(gconstpointer, gconstpointer));
+DECLARE_FUNCTION_MOCK1(mock_g_str_hash, g_str_hash, guint(gconstpointer));
+DECLARE_FUNCTION_MOCK2(mock_g_strcmp0, g_strcmp0, int(const char *, const char *));
+DECLARE_FUNCTION_MOCK1(mock_g_strdup, g_strdup, gchar *(const gchar *));
+DECLARE_FUNCTION_MOCK1(mock_g_strfreev, g_strfreev, void(gchar **));
+DECLARE_FUNCTION_MOCK1(mock_g_string_chunk_free, g_string_chunk_free, void(GStringChunk *));
+DECLARE_FUNCTION_MOCK2(mock_g_string_free, g_string_free, gchar *(GString *, gboolean));
+DECLARE_FUNCTION_MOCK3(mock_g_string_insert_c, g_string_insert_c, GString *(GString *, gssize, gchar));
+DECLARE_FUNCTION_MOCK3(mock_g_strlcat, g_strlcat, gsize(gchar *, const gchar *, gsize));
+DECLARE_FUNCTION_MOCK3(mock_g_strlcpy, g_strlcpy, gsize(gchar *, const gchar *, gsize));
+DECLARE_FUNCTION_MOCK2(mock_g_strndup, g_strndup, gchar *(const gchar *, gsize));
+DECLARE_FUNCTION_MOCK1(mock_g_thread_unref, g_thread_unref, void(GThread *));
+DECLARE_FUNCTION_MOCK1(mock_g_time_zone_unref, g_time_zone_unref, void(GTimeZone *));
+DECLARE_FUNCTION_MOCK3(mock_g_timeout_add, g_timeout_add, guint(guint, GSourceFunc, gpointer));
+DECLARE_FUNCTION_MOCK1(mock_g_timer_destroy, g_timer_destroy, void(GTimer *));
+DECLARE_FUNCTION_MOCK1(mock_g_tree_unref, g_tree_unref, void(GTree *));
+DECLARE_FUNCTION_MOCK2(mock_g_type_check_instance_cast, g_type_check_instance_cast, GTypeInstance *(GTypeInstance *, GType));
+DECLARE_FUNCTION_MOCK2(mock_g_type_check_instance_is_a, g_type_check_instance_is_a, gboolean(GTypeInstance *, GType));
+DECLARE_FUNCTION_MOCK2(mock_g_type_check_instance_is_fundamentally_a, g_type_check_instance_is_fundamentally_a, gboolean(GTypeInstance *, GType));
+DECLARE_FUNCTION_MOCK1(mock_g_type_class_unref, g_type_class_unref, void(gpointer));
+DECLARE_FUNCTION_MOCK1(mock_g_value_get_boxed, g_value_get_boxed, gpointer(const GValue *));
+DECLARE_FUNCTION_MOCK1(mock_g_value_get_string, g_value_get_string, const gchar *(const GValue *));
+DECLARE_FUNCTION_MOCK1(mock_g_value_unset, g_value_unset, void(GValue *));
+DECLARE_FUNCTION_MOCK1(mock_g_variant_builder_clear, g_variant_builder_clear, void(GVariantBuilder *));
+DECLARE_FUNCTION_MOCK1(mock_g_variant_builder_unref, g_variant_builder_unref, void(GVariantBuilder *));
+DECLARE_FUNCTION_MOCK1(mock_g_variant_dict_clear, g_variant_dict_clear, void(GVariantDict *));
+DECLARE_FUNCTION_MOCK1(mock_g_variant_dict_unref, g_variant_dict_unref, void(GVariantDict *));
+DECLARE_FUNCTION_MOCK1(mock_g_variant_iter_free, g_variant_iter_free, void(GVariantIter *));
+DECLARE_FUNCTION_MOCK1(mock_g_variant_type_free, g_variant_type_free, void(GVariantType *));
+DECLARE_FUNCTION_MOCK1(mock_g_variant_unref, g_variant_unref, void(GVariant *));
+DECLARE_FUNCTION_MOCK0(mock_getpid, getpid, __pid_t());
+DECLARE_FUNCTION_MOCK1(mock_gettext, gettext, char *(const char *));
+DECLARE_FUNCTION_MOCK2(mock_gettimeofday, gettimeofday, int(struct timeval *, __timezone_ptr_t));
+DECLARE_FUNCTION_MOCK2(mock_kill, kill, int(__pid_t, int));
+DECLARE_FUNCTION_MOCK1(mock_localtime, localtime, struct tm *(const time_t *));
+DECLARE_FUNCTION_MOCK2(mock_lstat, lstat, int(const char *, struct stat *));
+DECLARE_FUNCTION_MOCK3(mock_memcmp, memcmp, int(const void *, const void *, size_t));
+DECLARE_FUNCTION_MOCK2(mock_mm_sound_play_keysound, mm_sound_play_keysound, int(const char *, int));
+DECLARE_FUNCTION_MOCK3(mock_ngettext, ngettext, char *(const char *, const char *, unsigned long));
+DECLARE_FUNCTION_MOCK1(mock_notification_free_list, notification_free_list, int(notification_list_h));
+DECLARE_FUNCTION_MOCK3(mock_notification_get_list, notification_get_list, int(notification_type_e, int, notification_list_h *));
+DECLARE_FUNCTION_MOCK3(mock_notification_get_text, notification_get_text, int(notification_h, notification_text_type_e, char **));
+DECLARE_FUNCTION_MOCK1(mock_notification_list_get_data, notification_list_get_data, notification_h(notification_list_h));
+DECLARE_FUNCTION_MOCK1(mock_notification_list_get_head, notification_list_get_head, notification_list_h(notification_list_h));
+DECLARE_FUNCTION_MOCK1(mock_notification_list_get_next, notification_list_get_next, notification_list_h(notification_list_h));
+DECLARE_FUNCTION_MOCK1(mock_sem_post, sem_post, int(sem_t *));
+DECLARE_FUNCTION_MOCK1(mock_sem_wait, sem_wait, int(sem_t *));
+DECLARE_FUNCTION_MOCK2(mock_setlocale, setlocale, char *(int, const char *));
+DECLARE_FUNCTION_MOCK3(mock_sigaction, sigaction, int(int, const struct sigaction *, struct sigaction *));
+DECLARE_FUNCTION_MOCK2(mock_sigaltstack, sigaltstack, int(const stack_t *, stack_t *));
+DECLARE_FUNCTION_MOCK1(mock_sigemptyset, sigemptyset, int(sigset_t *));
+DECLARE_FUNCTION_MOCK1(mock_sqrt, sqrt, double(double));
+DECLARE_FUNCTION_MOCK1(mock_strdup, strdup, char *(const char *));
+DECLARE_FUNCTION_MOCK4(mock_strftime, strftime, size_t(char *, size_t, const char *, const struct tm *));
+DECLARE_FUNCTION_MOCK3(mock_strncmp, strncmp, int(const char *, const char *, size_t));
+DECLARE_FUNCTION_MOCK2(mock_strnlen, strnlen, size_t(const char *, size_t));
+DECLARE_FUNCTION_MOCK0(mock_tel_get_cp_name_list, tel_get_cp_name_list, char **());
+DECLARE_FUNCTION_MOCK3(mock_tel_get_property_int, tel_get_property_int, int(TapiHandle *, const char *, int *));
+DECLARE_FUNCTION_MOCK1(mock_tel_init, tel_init, TapiHandle *(const char *));
+DECLARE_FUNCTION_MOCK1(mock_time, time, time_t(time_t *));
+DECLARE_FUNCTION_MOCK6(mock_tts_add_text, tts_add_text, int(tts_h, const char *, const char *, int, int, int *));
+DECLARE_FUNCTION_MOCK1(mock_tts_create, tts_create, int(tts_h *));
+DECLARE_FUNCTION_MOCK1(mock_tts_destroy, tts_destroy, int(tts_h));
+DECLARE_FUNCTION_MOCK2(mock_tts_get_state, tts_get_state, int(tts_h, tts_state_e *));
+DECLARE_FUNCTION_MOCK1(mock_tts_pause, tts_pause, int(tts_h));
+DECLARE_FUNCTION_MOCK1(mock_tts_play, tts_play, int(tts_h));
+DECLARE_FUNCTION_MOCK1(mock_tts_prepare, tts_prepare, int(tts_h));
+DECLARE_FUNCTION_MOCK2(mock_tts_set_mode, tts_set_mode, int(tts_h, tts_mode_e));
+DECLARE_FUNCTION_MOCK3(mock_tts_set_state_changed_cb, tts_set_state_changed_cb, int(tts_h, tts_state_changed_cb, void *));
+DECLARE_FUNCTION_MOCK3(mock_tts_set_utterance_completed_cb, tts_set_utterance_completed_cb, int(tts_h, tts_utterance_completed_cb, void *));
+DECLARE_FUNCTION_MOCK3(mock_tts_set_utterance_started_cb, tts_set_utterance_started_cb, int(tts_h, tts_utterance_started_cb, void *));
+DECLARE_FUNCTION_MOCK1(mock_tts_stop, tts_stop, int(tts_h));
+DECLARE_FUNCTION_MOCK0(mock_ui_app_exit, ui_app_exit, void());
+DECLARE_FUNCTION_MOCK1(mock_unsetenv, unsetenv, int(const char *));
+DECLARE_FUNCTION_MOCK1(mock_usleep, usleep, int(__useconds_t));
+DECLARE_FUNCTION_MOCK2(mock_vconf_get_bool, vconf_get_bool, int(const char *, int *));
+DECLARE_FUNCTION_MOCK2(mock_vconf_get_int, vconf_get_int, int(const char *, int *));
+DECLARE_FUNCTION_MOCK1(mock_vconf_get_str, vconf_get_str, char *(const char *));
+DECLARE_FUNCTION_MOCK2(mock_vconf_ignore_key_changed, vconf_ignore_key_changed, int(const char *, vconf_callback_fn));
+DECLARE_FUNCTION_MOCK1(mock_vconf_keynode_get_int, vconf_keynode_get_int, int(keynode_t *));
+DECLARE_FUNCTION_MOCK3(mock_vconf_notify_key_changed, vconf_notify_key_changed, int(const char *, vconf_callback_fn, void *));
+DECLARE_FUNCTION_MOCK1(mock_wifi_manager_ap_destroy, wifi_manager_ap_destroy, int(wifi_manager_ap_h));
+DECLARE_FUNCTION_MOCK2(mock_wifi_manager_ap_get_rssi, wifi_manager_ap_get_rssi, int(wifi_manager_ap_h, int *));
+DECLARE_FUNCTION_MOCK1(mock_wifi_manager_deinitialize, wifi_manager_deinitialize, int(wifi_manager_h));
+DECLARE_FUNCTION_MOCK2(mock_wifi_manager_get_connected_ap, wifi_manager_get_connected_ap, int(wifi_manager_h, wifi_manager_ap_h *));
+DECLARE_FUNCTION_MOCK1(mock_wifi_manager_initialize, wifi_manager_initialize, int(wifi_manager_h *));
+DECLARE_FUNCTION_MOCK2(mock_wifi_manager_is_activated, wifi_manager_is_activated, int(wifi_manager_h, _Bool *));
+
--- /dev/null
+#include "mocked_flat_navi.h"
+
+IMPLEMENT_FUNCTION_MOCK4(mock__directional_depth_first_search, _directional_depth_first_search, AtspiAccessible *(AtspiAccessible *, AtspiAccessible *, search_direction, StopConditionCb));
+IMPLEMENT_FUNCTION_MOCK1(mock__first, _first, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock__last, _last, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_cycle_detection_check_if_in_cycle, cycle_detection_check_if_in_cycle, Eina_Bool(cycle_detection_data *, const void *));
+IMPLEMENT_FUNCTION_MOCK2(mock_cycle_detection_initialize, cycle_detection_initialize, void(cycle_detection_data *, const void *));
+IMPLEMENT_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+IMPLEMENT_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK2(mock_get_accuracy, get_accuracy, int(double, int));
+IMPLEMENT_FUNCTION_MOCK1(mock_get_objects_attributes, get_objects_attributes, unsigned short(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_defunct_state, object_has_defunct_state, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_highlighted_state, object_has_highlighted_state, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_modal_role, object_has_modal_role, Eina_Bool(AtspiRole));
+IMPLEMENT_FUNCTION_MOCK3(mock_smart_notification, smart_notification, void(Notification_Type, int, int));
+IMPLEMENT_FUNCTION_MOCK0(mock_smart_notification_init, smart_notification_init, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_smart_notification_shutdown, smart_notification_shutdown, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_utils_a11y_bus_connection_get, utils_a11y_bus_connection_get, Eldbus_Connection *());
+IMPLEMENT_FUNCTION_MOCK1(mock_utils_a11y_bus_connection_set, utils_a11y_bus_connection_set, void(Eldbus_Connection *));
+IMPLEMENT_FUNCTION_MOCK1(mock_utils_enum_to_string, utils_enum_to_string, const char *(Gesture));
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_exit, vc_exit, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_haptic, vc_get_haptic, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_keyboard_feedback, vc_get_keyboard_feedback, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_lcd_backlight_timeout, vc_get_lcd_backlight_timeout, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_read_description, vc_get_read_description, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_sound_feedback, vc_get_sound_feedback, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_init, vc_init, void());
+
--- /dev/null
+#pragma once
+
+extern "C" {
+#include "flat_navi.h"
+#include "logger.h"
+#include "smart_notification.h"
+#include "utils.h"
+#include "screen_reader_vconf.h"
+}
+#include <cmock/cmock.h>
+
+extern "C" AtspiAccessible * _directional_depth_first_search(AtspiAccessible * root, AtspiAccessible * start, search_direction direction, StopConditionCb stop_condition_cb);
+extern "C" AtspiAccessible * _first(FlatNaviContext * ctx);
+extern "C" AtspiAccessible * _last(FlatNaviContext * ctx);
+DECLARE_FUNCTION_MOCK4(mock__directional_depth_first_search, _directional_depth_first_search, AtspiAccessible *(AtspiAccessible *, AtspiAccessible *, search_direction, StopConditionCb));
+DECLARE_FUNCTION_MOCK1(mock__first, _first, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock__last, _last, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_cycle_detection_check_if_in_cycle, cycle_detection_check_if_in_cycle, Eina_Bool(cycle_detection_data *, const void *));
+DECLARE_FUNCTION_MOCK2(mock_cycle_detection_initialize, cycle_detection_initialize, void(cycle_detection_data *, const void *));
+DECLARE_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+DECLARE_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK2(mock_get_accuracy, get_accuracy, int(double, int));
+DECLARE_FUNCTION_MOCK1(mock_get_objects_attributes, get_objects_attributes, unsigned short(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_defunct_state, object_has_defunct_state, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_highlighted_state, object_has_highlighted_state, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_modal_role, object_has_modal_role, Eina_Bool(AtspiRole));
+DECLARE_FUNCTION_MOCK3(mock_smart_notification, smart_notification, void(Notification_Type, int, int));
+DECLARE_FUNCTION_MOCK0(mock_smart_notification_init, smart_notification_init, void());
+DECLARE_FUNCTION_MOCK0(mock_smart_notification_shutdown, smart_notification_shutdown, void());
+DECLARE_FUNCTION_MOCK0(mock_utils_a11y_bus_connection_get, utils_a11y_bus_connection_get, Eldbus_Connection *());
+DECLARE_FUNCTION_MOCK1(mock_utils_a11y_bus_connection_set, utils_a11y_bus_connection_set, void(Eldbus_Connection *));
+DECLARE_FUNCTION_MOCK1(mock_utils_enum_to_string, utils_enum_to_string, const char *(Gesture));
+DECLARE_FUNCTION_MOCK0(mock_vc_exit, vc_exit, void());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_haptic, vc_get_haptic, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_keyboard_feedback, vc_get_keyboard_feedback, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_lcd_backlight_timeout, vc_get_lcd_backlight_timeout, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_read_description, vc_get_read_description, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_sound_feedback, vc_get_sound_feedback, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_init, vc_init, void());
+
--- /dev/null
+#include "mocked_granularity_read.h"
+
+IMPLEMENT_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK2(mock_cycle_detection_check_if_in_cycle, cycle_detection_check_if_in_cycle, Eina_Bool(cycle_detection_data *, const void *));
+IMPLEMENT_FUNCTION_MOCK2(mock_cycle_detection_initialize, cycle_detection_initialize, void(cycle_detection_data *, const void *));
+IMPLEMENT_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+IMPLEMENT_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK3(mock_generate_what_to_read_and_speak, generate_what_to_read_and_speak, void(NavigatorData *, AtspiAccessible *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK2(mock_get_accuracy, get_accuracy, int(double, int));
+IMPLEMENT_FUNCTION_MOCK1(mock_get_objects_attributes, get_objects_attributes, unsigned short(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK0(mock_get_pointer_to_service_data_struct, get_pointer_to_service_data_struct, Service_Data *());
+IMPLEMENT_FUNCTION_MOCK0(mock_granularity_read_data_get, granularity_read_data_get, Granularity_Read_Data *());
+IMPLEMENT_FUNCTION_MOCK0(mock_granularity_read_init, granularity_read_init, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_granularity_read_terminate, granularity_read_terminate, void());
+IMPLEMENT_FUNCTION_MOCK2(mock_granularity_read_text_get, granularity_read_text_get, char *(AtspiAccessible *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK0(mock_granularity_read_text_list_init, granularity_read_text_list_init, void());
+IMPLEMENT_FUNCTION_MOCK1(mock_granularity_read_type_set, granularity_read_type_set, void(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK0(mock_granularity_read_ui_popup_show, granularity_read_ui_popup_show, void());
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_focus_next_visible, navigator_focus_next_visible, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_focus_prev_visible, navigator_focus_prev_visible, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_flat_navi_context, navigator_get_flat_navi_context, FlatNaviContext *(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_ignore_keyboard_feedback, navigator_get_ignore_keyboard_feedback, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_is_text_selection_mode, navigator_get_is_text_selection_mode, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK0(mock_navigator_init, navigator_init, NavigatorData *());
+IMPLEMENT_FUNCTION_MOCK2(mock_navigator_set_ignore_keyboard_feedback, navigator_set_ignore_keyboard_feedback, void(NavigatorData *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK4(mock_navigator_set_read_quickpanel_cb, navigator_set_read_quickpanel_cb, void(NavigatorData *, read_quickpanel_cb_t, void *, read_quickpanel_cb_t));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_shutdown, navigator_shutdown, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_defunct_state, object_has_defunct_state, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_highlighted_state, object_has_highlighted_state, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_modal_role, object_has_modal_role, Eina_Bool(AtspiRole));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_data_free, reading_composer_data_free, void(ReadingComposerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_data_get, reading_composer_data_get, ReadingComposerData *(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_description_get, reading_composer_description_get, char *(ReadingComposerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_extended_description_get, reading_composer_extended_description_get, char *(ReadingComposerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_name_get, reading_composer_name_get, char *(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_create_service, screen_reader_create_service, int(Service_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_terminate_service, screen_reader_terminate_service, int(Service_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_ui_launch, screen_reader_ui_launch, void(const char *));
+IMPLEMENT_FUNCTION_MOCK0(mock_screen_reader_ui_terminate, screen_reader_ui_terminate, void());
+IMPLEMENT_FUNCTION_MOCK3(mock_smart_notification, smart_notification, void(Notification_Type, int, int));
+IMPLEMENT_FUNCTION_MOCK0(mock_smart_notification_init, smart_notification_init, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_smart_notification_shutdown, smart_notification_shutdown, void());
+IMPLEMENT_FUNCTION_MOCK1(mock_sound_n_vibration_feedback_generate, sound_n_vibration_feedback_generate, void(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK0(mock_spi_init, spi_init, SpiData *());
+IMPLEMENT_FUNCTION_MOCK1(mock_spi_shutdown, spi_shutdown, void(SpiData *));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_init, tw_init, _Bool());
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_pause_get, tw_pause_get, Eina_Bool());
+IMPLEMENT_FUNCTION_MOCK1(mock_tw_pause_set, tw_pause_set, Eina_Bool(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK1(mock_tw_purge, tw_purge, void(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK3(mock_tw_set_utterance_cb, tw_set_utterance_cb, void(utterance_cb_t, void *, utterance_cb_t));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_shutdown, tw_shutdown, void());
+IMPLEMENT_FUNCTION_MOCK2(mock_tw_speak, tw_speak, Read_Command *(char *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK5(mock_tw_speak_customized, tw_speak_customized, Read_Command *(char *, Eina_Bool, Eina_Bool, AtspiAccessible *, unsigned int));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_stop_set, tw_stop_set, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_utils_a11y_bus_connection_get, utils_a11y_bus_connection_get, Eldbus_Connection *());
+IMPLEMENT_FUNCTION_MOCK1(mock_utils_a11y_bus_connection_set, utils_a11y_bus_connection_set, void(Eldbus_Connection *));
+IMPLEMENT_FUNCTION_MOCK1(mock_utils_enum_to_string, utils_enum_to_string, const char *(Gesture));
+
--- /dev/null
+#pragma once
+
+extern "C" {
+#include <atspi/atspi.h>
+#include <ecore-1/Ecore.h>
+#include <Elementary.h>
+#include "granularity_read.h"
+#include "logger.h"
+#include "reading_composer.h"
+#include "screen_reader_tts.h"
+#include "smart_notification.h"
+#include "utils.h"
+}
+#include <cmock/cmock.h>
+
+DECLARE_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK2(mock_cycle_detection_check_if_in_cycle, cycle_detection_check_if_in_cycle, Eina_Bool(cycle_detection_data *, const void *));
+DECLARE_FUNCTION_MOCK2(mock_cycle_detection_initialize, cycle_detection_initialize, void(cycle_detection_data *, const void *));
+DECLARE_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+DECLARE_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK3(mock_generate_what_to_read_and_speak, generate_what_to_read_and_speak, void(NavigatorData *, AtspiAccessible *, Eina_Bool));
+DECLARE_FUNCTION_MOCK2(mock_get_accuracy, get_accuracy, int(double, int));
+DECLARE_FUNCTION_MOCK1(mock_get_objects_attributes, get_objects_attributes, unsigned short(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK0(mock_get_pointer_to_service_data_struct, get_pointer_to_service_data_struct, Service_Data *());
+DECLARE_FUNCTION_MOCK0(mock_granularity_read_data_get, granularity_read_data_get, Granularity_Read_Data *());
+DECLARE_FUNCTION_MOCK0(mock_granularity_read_init, granularity_read_init, void());
+DECLARE_FUNCTION_MOCK0(mock_granularity_read_terminate, granularity_read_terminate, void());
+DECLARE_FUNCTION_MOCK2(mock_granularity_read_text_get, granularity_read_text_get, char *(AtspiAccessible *, Eina_Bool));
+DECLARE_FUNCTION_MOCK0(mock_granularity_read_text_list_init, granularity_read_text_list_init, void());
+DECLARE_FUNCTION_MOCK1(mock_granularity_read_type_set, granularity_read_type_set, void(Eina_Bool));
+DECLARE_FUNCTION_MOCK0(mock_granularity_read_ui_popup_show, granularity_read_ui_popup_show, void());
+DECLARE_FUNCTION_MOCK1(mock_navigator_focus_next_visible, navigator_focus_next_visible, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_focus_prev_visible, navigator_focus_prev_visible, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_flat_navi_context, navigator_get_flat_navi_context, FlatNaviContext *(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_ignore_keyboard_feedback, navigator_get_ignore_keyboard_feedback, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_is_text_selection_mode, navigator_get_is_text_selection_mode, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK0(mock_navigator_init, navigator_init, NavigatorData *());
+DECLARE_FUNCTION_MOCK2(mock_navigator_set_ignore_keyboard_feedback, navigator_set_ignore_keyboard_feedback, void(NavigatorData *, Eina_Bool));
+DECLARE_FUNCTION_MOCK4(mock_navigator_set_read_quickpanel_cb, navigator_set_read_quickpanel_cb, void(NavigatorData *, read_quickpanel_cb_t, void *, read_quickpanel_cb_t));
+DECLARE_FUNCTION_MOCK1(mock_navigator_shutdown, navigator_shutdown, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_defunct_state, object_has_defunct_state, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_highlighted_state, object_has_highlighted_state, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_modal_role, object_has_modal_role, Eina_Bool(AtspiRole));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_data_free, reading_composer_data_free, void(ReadingComposerData *));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_data_get, reading_composer_data_get, ReadingComposerData *(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_description_get, reading_composer_description_get, char *(ReadingComposerData *));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_extended_description_get, reading_composer_extended_description_get, char *(ReadingComposerData *));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_name_get, reading_composer_name_get, char *(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_create_service, screen_reader_create_service, int(Service_Data *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_terminate_service, screen_reader_terminate_service, int(Service_Data *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_ui_launch, screen_reader_ui_launch, void(const char *));
+DECLARE_FUNCTION_MOCK0(mock_screen_reader_ui_terminate, screen_reader_ui_terminate, void());
+DECLARE_FUNCTION_MOCK3(mock_smart_notification, smart_notification, void(Notification_Type, int, int));
+DECLARE_FUNCTION_MOCK0(mock_smart_notification_init, smart_notification_init, void());
+DECLARE_FUNCTION_MOCK0(mock_smart_notification_shutdown, smart_notification_shutdown, void());
+DECLARE_FUNCTION_MOCK1(mock_sound_n_vibration_feedback_generate, sound_n_vibration_feedback_generate, void(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK0(mock_spi_init, spi_init, SpiData *());
+DECLARE_FUNCTION_MOCK1(mock_spi_shutdown, spi_shutdown, void(SpiData *));
+DECLARE_FUNCTION_MOCK0(mock_tw_init, tw_init, _Bool());
+DECLARE_FUNCTION_MOCK0(mock_tw_pause_get, tw_pause_get, Eina_Bool());
+DECLARE_FUNCTION_MOCK1(mock_tw_pause_set, tw_pause_set, Eina_Bool(Eina_Bool));
+DECLARE_FUNCTION_MOCK1(mock_tw_purge, tw_purge, void(Eina_Bool));
+DECLARE_FUNCTION_MOCK3(mock_tw_set_utterance_cb, tw_set_utterance_cb, void(utterance_cb_t, void *, utterance_cb_t));
+DECLARE_FUNCTION_MOCK0(mock_tw_shutdown, tw_shutdown, void());
+DECLARE_FUNCTION_MOCK2(mock_tw_speak, tw_speak, Read_Command *(char *, Eina_Bool));
+DECLARE_FUNCTION_MOCK5(mock_tw_speak_customized, tw_speak_customized, Read_Command *(char *, Eina_Bool, Eina_Bool, AtspiAccessible *, unsigned int));
+DECLARE_FUNCTION_MOCK0(mock_tw_stop_set, tw_stop_set, void());
+DECLARE_FUNCTION_MOCK0(mock_utils_a11y_bus_connection_get, utils_a11y_bus_connection_get, Eldbus_Connection *());
+DECLARE_FUNCTION_MOCK1(mock_utils_a11y_bus_connection_set, utils_a11y_bus_connection_set, void(Eldbus_Connection *));
+DECLARE_FUNCTION_MOCK1(mock_utils_enum_to_string, utils_enum_to_string, const char *(Gesture));
+
--- /dev/null
+#include "mocked_keyboard_tracker.h"
+
+IMPLEMENT_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+IMPLEMENT_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK3(mock_generate_what_to_read_and_speak, generate_what_to_read_and_speak, void(NavigatorData *, AtspiAccessible *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK0(mock_get_pointer_to_service_data_struct, get_pointer_to_service_data_struct, Service_Data *());
+IMPLEMENT_FUNCTION_MOCK3(mock_keyboard_event_status, keyboard_event_status, Eina_Bool(KeyboardTrackerData *, const int, const int));
+IMPLEMENT_FUNCTION_MOCK5(mock_keyboard_geometry_get, keyboard_geometry_get, Eina_Bool(const KeyboardTrackerData *, int *, int *, int *, int *));
+IMPLEMENT_FUNCTION_MOCK5(mock_keyboard_geometry_set, keyboard_geometry_set, void(KeyboardTrackerData *, int, int, int, int));
+IMPLEMENT_FUNCTION_MOCK4(mock_keyboard_signal_emit, keyboard_signal_emit, void(KeyboardTrackerData *, int, int, int));
+IMPLEMENT_FUNCTION_MOCK0(mock_keyboard_tracker_init, keyboard_tracker_init, KeyboardTrackerData *());
+IMPLEMENT_FUNCTION_MOCK3(mock_keyboard_tracker_register_top_window_info_get, keyboard_tracker_register_top_window_info_get, void(KeyboardTrackerData *, TopWindowInfoGetCb, void *));
+IMPLEMENT_FUNCTION_MOCK1(mock_keyboard_tracker_shutdown, keyboard_tracker_shutdown, void(KeyboardTrackerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_keyboard_tracker_unregister_top_window_info_get, keyboard_tracker_unregister_top_window_info_get, void *(KeyboardTrackerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_focus_next_visible, navigator_focus_next_visible, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_focus_prev_visible, navigator_focus_prev_visible, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_flat_navi_context, navigator_get_flat_navi_context, FlatNaviContext *(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_ignore_keyboard_feedback, navigator_get_ignore_keyboard_feedback, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_is_text_selection_mode, navigator_get_is_text_selection_mode, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK0(mock_navigator_init, navigator_init, NavigatorData *());
+IMPLEMENT_FUNCTION_MOCK2(mock_navigator_set_ignore_keyboard_feedback, navigator_set_ignore_keyboard_feedback, void(NavigatorData *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK4(mock_navigator_set_read_quickpanel_cb, navigator_set_read_quickpanel_cb, void(NavigatorData *, read_quickpanel_cb_t, void *, read_quickpanel_cb_t));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_shutdown, navigator_shutdown, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_create_service, screen_reader_create_service, int(Service_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_terminate_service, screen_reader_terminate_service, int(Service_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_ui_launch, screen_reader_ui_launch, void(const char *));
+IMPLEMENT_FUNCTION_MOCK0(mock_screen_reader_ui_terminate, screen_reader_ui_terminate, void());
+IMPLEMENT_FUNCTION_MOCK1(mock_sound_n_vibration_feedback_generate, sound_n_vibration_feedback_generate, void(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK0(mock_spi_init, spi_init, SpiData *());
+IMPLEMENT_FUNCTION_MOCK1(mock_spi_shutdown, spi_shutdown, void(SpiData *));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_init, tw_init, _Bool());
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_pause_get, tw_pause_get, Eina_Bool());
+IMPLEMENT_FUNCTION_MOCK1(mock_tw_pause_set, tw_pause_set, Eina_Bool(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK1(mock_tw_purge, tw_purge, void(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK3(mock_tw_set_utterance_cb, tw_set_utterance_cb, void(utterance_cb_t, void *, utterance_cb_t));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_shutdown, tw_shutdown, void());
+IMPLEMENT_FUNCTION_MOCK2(mock_tw_speak, tw_speak, Read_Command *(char *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK5(mock_tw_speak_customized, tw_speak_customized, Read_Command *(char *, Eina_Bool, Eina_Bool, AtspiAccessible *, unsigned int));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_stop_set, tw_stop_set, void());
+
--- /dev/null
+#pragma once
+
+extern "C" {
+#include <string.h>
+#include <atspi/atspi.h>
+#include <ecore-1/Ecore.h>
+#include <vconf.h>
+#include "keyboard_tracker.h"
+#include "logger.h"
+#include "screen_reader_tts.h"
+}
+#include <cmock/cmock.h>
+
+DECLARE_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+DECLARE_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK3(mock_generate_what_to_read_and_speak, generate_what_to_read_and_speak, void(NavigatorData *, AtspiAccessible *, Eina_Bool));
+DECLARE_FUNCTION_MOCK0(mock_get_pointer_to_service_data_struct, get_pointer_to_service_data_struct, Service_Data *());
+DECLARE_FUNCTION_MOCK3(mock_keyboard_event_status, keyboard_event_status, Eina_Bool(KeyboardTrackerData *, const int, const int));
+DECLARE_FUNCTION_MOCK5(mock_keyboard_geometry_get, keyboard_geometry_get, Eina_Bool(const KeyboardTrackerData *, int *, int *, int *, int *));
+DECLARE_FUNCTION_MOCK5(mock_keyboard_geometry_set, keyboard_geometry_set, void(KeyboardTrackerData *, int, int, int, int));
+DECLARE_FUNCTION_MOCK4(mock_keyboard_signal_emit, keyboard_signal_emit, void(KeyboardTrackerData *, int, int, int));
+DECLARE_FUNCTION_MOCK0(mock_keyboard_tracker_init, keyboard_tracker_init, KeyboardTrackerData *());
+DECLARE_FUNCTION_MOCK3(mock_keyboard_tracker_register_top_window_info_get, keyboard_tracker_register_top_window_info_get, void(KeyboardTrackerData *, TopWindowInfoGetCb, void *));
+DECLARE_FUNCTION_MOCK1(mock_keyboard_tracker_shutdown, keyboard_tracker_shutdown, void(KeyboardTrackerData *));
+DECLARE_FUNCTION_MOCK1(mock_keyboard_tracker_unregister_top_window_info_get, keyboard_tracker_unregister_top_window_info_get, void *(KeyboardTrackerData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_focus_next_visible, navigator_focus_next_visible, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_focus_prev_visible, navigator_focus_prev_visible, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_flat_navi_context, navigator_get_flat_navi_context, FlatNaviContext *(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_ignore_keyboard_feedback, navigator_get_ignore_keyboard_feedback, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_is_text_selection_mode, navigator_get_is_text_selection_mode, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK0(mock_navigator_init, navigator_init, NavigatorData *());
+DECLARE_FUNCTION_MOCK2(mock_navigator_set_ignore_keyboard_feedback, navigator_set_ignore_keyboard_feedback, void(NavigatorData *, Eina_Bool));
+DECLARE_FUNCTION_MOCK4(mock_navigator_set_read_quickpanel_cb, navigator_set_read_quickpanel_cb, void(NavigatorData *, read_quickpanel_cb_t, void *, read_quickpanel_cb_t));
+DECLARE_FUNCTION_MOCK1(mock_navigator_shutdown, navigator_shutdown, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_create_service, screen_reader_create_service, int(Service_Data *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_terminate_service, screen_reader_terminate_service, int(Service_Data *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_ui_launch, screen_reader_ui_launch, void(const char *));
+DECLARE_FUNCTION_MOCK0(mock_screen_reader_ui_terminate, screen_reader_ui_terminate, void());
+DECLARE_FUNCTION_MOCK1(mock_sound_n_vibration_feedback_generate, sound_n_vibration_feedback_generate, void(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK0(mock_spi_init, spi_init, SpiData *());
+DECLARE_FUNCTION_MOCK1(mock_spi_shutdown, spi_shutdown, void(SpiData *));
+DECLARE_FUNCTION_MOCK0(mock_tw_init, tw_init, _Bool());
+DECLARE_FUNCTION_MOCK0(mock_tw_pause_get, tw_pause_get, Eina_Bool());
+DECLARE_FUNCTION_MOCK1(mock_tw_pause_set, tw_pause_set, Eina_Bool(Eina_Bool));
+DECLARE_FUNCTION_MOCK1(mock_tw_purge, tw_purge, void(Eina_Bool));
+DECLARE_FUNCTION_MOCK3(mock_tw_set_utterance_cb, tw_set_utterance_cb, void(utterance_cb_t, void *, utterance_cb_t));
+DECLARE_FUNCTION_MOCK0(mock_tw_shutdown, tw_shutdown, void());
+DECLARE_FUNCTION_MOCK2(mock_tw_speak, tw_speak, Read_Command *(char *, Eina_Bool));
+DECLARE_FUNCTION_MOCK5(mock_tw_speak_customized, tw_speak_customized, Read_Command *(char *, Eina_Bool, Eina_Bool, AtspiAccessible *, unsigned int));
+DECLARE_FUNCTION_MOCK0(mock_tw_stop_set, tw_stop_set, void());
+
--- /dev/null
+#include "mocked_main.h"
+
+IMPLEMENT_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK3(mock_dbus_direct_reading_adapter_emit, dbus_direct_reading_adapter_emit, int(Reading_Adapter_Data *, const Signal, const void *));
+IMPLEMENT_FUNCTION_MOCK0(mock_dbus_direct_reading_init, dbus_direct_reading_init, Reading_Adapter_Data *());
+IMPLEMENT_FUNCTION_MOCK1(mock_dbus_direct_reading_shutdown, dbus_direct_reading_shutdown, void(Reading_Adapter_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_device_display_lock_release, device_display_lock_release, void(System_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_device_display_lock_request, device_display_lock_request, void(System_Data *));
+IMPLEMENT_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+IMPLEMENT_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK3(mock_generate_what_to_read_and_speak, generate_what_to_read_and_speak, void(NavigatorData *, AtspiAccessible *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK0(mock_get_pointer_to_service_data_struct, get_pointer_to_service_data_struct, Service_Data *());
+IMPLEMENT_FUNCTION_MOCK1(mock_get_signal_name, get_signal_name, const char *(const Signal));
+IMPLEMENT_FUNCTION_MOCK0(mock_granularity_read_data_get, granularity_read_data_get, Granularity_Read_Data *());
+IMPLEMENT_FUNCTION_MOCK0(mock_granularity_read_init, granularity_read_init, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_granularity_read_terminate, granularity_read_terminate, void());
+IMPLEMENT_FUNCTION_MOCK2(mock_granularity_read_text_get, granularity_read_text_get, char *(AtspiAccessible *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK0(mock_granularity_read_text_list_init, granularity_read_text_list_init, void());
+IMPLEMENT_FUNCTION_MOCK1(mock_granularity_read_type_set, granularity_read_type_set, void(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK0(mock_granularity_read_ui_popup_show, granularity_read_ui_popup_show, void());
+IMPLEMENT_FUNCTION_MOCK1(mock_is_enabled_switch_set, is_enabled_switch_set, Eina_Bool(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK2(mock_main, main, int(int, char **));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_focus_next_visible, navigator_focus_next_visible, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_focus_prev_visible, navigator_focus_prev_visible, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_flat_navi_context, navigator_get_flat_navi_context, FlatNaviContext *(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_ignore_keyboard_feedback, navigator_get_ignore_keyboard_feedback, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_is_text_selection_mode, navigator_get_is_text_selection_mode, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK0(mock_navigator_init, navigator_init, NavigatorData *());
+IMPLEMENT_FUNCTION_MOCK2(mock_navigator_set_ignore_keyboard_feedback, navigator_set_ignore_keyboard_feedback, void(NavigatorData *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK4(mock_navigator_set_read_quickpanel_cb, navigator_set_read_quickpanel_cb, void(NavigatorData *, read_quickpanel_cb_t, void *, read_quickpanel_cb_t));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_shutdown, navigator_shutdown, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_posix_print_stack_trace, posix_print_stack_trace, void(FILE *));
+IMPLEMENT_FUNCTION_MOCK3(mock_posix_signal_handler, posix_signal_handler, void(int, siginfo_t *, void *));
+IMPLEMENT_FUNCTION_MOCK3(mock_print_warning, print_warning, void(int, siginfo_t *, FILE *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_create_service, screen_reader_create_service, int(Service_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_switch_enabled_get, screen_reader_switch_enabled_get, Eina_Bool(Eina_Bool *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_switch_enabled_set, screen_reader_switch_enabled_set, Eina_Bool(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_switch_wm_enabled_set, screen_reader_switch_wm_enabled_set, Eina_Bool(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_terminate_service, screen_reader_terminate_service, int(Service_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_ui_launch, screen_reader_ui_launch, void(const char *));
+IMPLEMENT_FUNCTION_MOCK0(mock_screen_reader_ui_terminate, screen_reader_ui_terminate, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_set_signal_handler, set_signal_handler, void());
+IMPLEMENT_FUNCTION_MOCK1(mock_sound_n_vibration_feedback_generate, sound_n_vibration_feedback_generate, void(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK0(mock_spi_init, spi_init, SpiData *());
+IMPLEMENT_FUNCTION_MOCK1(mock_spi_shutdown, spi_shutdown, void(SpiData *));
+IMPLEMENT_FUNCTION_MOCK0(mock_system_notifications_init, system_notifications_init, System_Data *());
+IMPLEMENT_FUNCTION_MOCK1(mock_system_notifications_shutdown, system_notifications_shutdown, void(System_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_system_status_get, system_status_get, void(void *));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_init, tw_init, _Bool());
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_pause_get, tw_pause_get, Eina_Bool());
+IMPLEMENT_FUNCTION_MOCK1(mock_tw_pause_set, tw_pause_set, Eina_Bool(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK1(mock_tw_purge, tw_purge, void(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK3(mock_tw_set_utterance_cb, tw_set_utterance_cb, void(utterance_cb_t, void *, utterance_cb_t));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_shutdown, tw_shutdown, void());
+IMPLEMENT_FUNCTION_MOCK2(mock_tw_speak, tw_speak, Read_Command *(char *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK5(mock_tw_speak_customized, tw_speak_customized, Read_Command *(char *, Eina_Bool, Eina_Bool, AtspiAccessible *, unsigned int));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_stop_set, tw_stop_set, void());
+
--- /dev/null
+#pragma once
+
+extern "C" {
+#include <time.h>
+#include <signal.h>
+#include <err.h>
+#include <execinfo.h>
+#include <appcore-efl.h>
+#include <Elementary.h>
+#include <eldbus-1/Eldbus.h>
+#include <vconf.h>
+#include <app.h>
+#include "navigator.h"
+#include "granularity_read.h"
+#include "logger.h"
+#include "screen_reader.h"
+#include "screen_reader_switch.h"
+#include "screen_reader_system.h"
+#include "dbus_direct_reading_adapter.h"
+#include "screen_reader_tts.h"
+}
+#include <cmock/cmock.h>
+
+extern "C" int main(int argc, char ** argv);
+extern "C" void posix_print_stack_trace(FILE * log_file);
+extern "C" void posix_signal_handler(int sig, siginfo_t * siginfo, void * context);
+extern "C" void print_warning(int sig, siginfo_t * siginfo, FILE * log_file);
+extern "C" void set_signal_handler();
+DECLARE_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK3(mock_dbus_direct_reading_adapter_emit, dbus_direct_reading_adapter_emit, int(Reading_Adapter_Data *, const Signal, const void *));
+DECLARE_FUNCTION_MOCK0(mock_dbus_direct_reading_init, dbus_direct_reading_init, Reading_Adapter_Data *());
+DECLARE_FUNCTION_MOCK1(mock_dbus_direct_reading_shutdown, dbus_direct_reading_shutdown, void(Reading_Adapter_Data *));
+DECLARE_FUNCTION_MOCK1(mock_device_display_lock_release, device_display_lock_release, void(System_Data *));
+DECLARE_FUNCTION_MOCK1(mock_device_display_lock_request, device_display_lock_request, void(System_Data *));
+DECLARE_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+DECLARE_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK3(mock_generate_what_to_read_and_speak, generate_what_to_read_and_speak, void(NavigatorData *, AtspiAccessible *, Eina_Bool));
+DECLARE_FUNCTION_MOCK0(mock_get_pointer_to_service_data_struct, get_pointer_to_service_data_struct, Service_Data *());
+DECLARE_FUNCTION_MOCK1(mock_get_signal_name, get_signal_name, const char *(const Signal));
+DECLARE_FUNCTION_MOCK0(mock_granularity_read_data_get, granularity_read_data_get, Granularity_Read_Data *());
+DECLARE_FUNCTION_MOCK0(mock_granularity_read_init, granularity_read_init, void());
+DECLARE_FUNCTION_MOCK0(mock_granularity_read_terminate, granularity_read_terminate, void());
+DECLARE_FUNCTION_MOCK2(mock_granularity_read_text_get, granularity_read_text_get, char *(AtspiAccessible *, Eina_Bool));
+DECLARE_FUNCTION_MOCK0(mock_granularity_read_text_list_init, granularity_read_text_list_init, void());
+DECLARE_FUNCTION_MOCK1(mock_granularity_read_type_set, granularity_read_type_set, void(Eina_Bool));
+DECLARE_FUNCTION_MOCK0(mock_granularity_read_ui_popup_show, granularity_read_ui_popup_show, void());
+DECLARE_FUNCTION_MOCK1(mock_is_enabled_switch_set, is_enabled_switch_set, Eina_Bool(Eina_Bool));
+DECLARE_FUNCTION_MOCK2(mock_main, main, int(int, char **));
+DECLARE_FUNCTION_MOCK1(mock_navigator_focus_next_visible, navigator_focus_next_visible, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_focus_prev_visible, navigator_focus_prev_visible, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_flat_navi_context, navigator_get_flat_navi_context, FlatNaviContext *(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_ignore_keyboard_feedback, navigator_get_ignore_keyboard_feedback, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_is_text_selection_mode, navigator_get_is_text_selection_mode, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK0(mock_navigator_init, navigator_init, NavigatorData *());
+DECLARE_FUNCTION_MOCK2(mock_navigator_set_ignore_keyboard_feedback, navigator_set_ignore_keyboard_feedback, void(NavigatorData *, Eina_Bool));
+DECLARE_FUNCTION_MOCK4(mock_navigator_set_read_quickpanel_cb, navigator_set_read_quickpanel_cb, void(NavigatorData *, read_quickpanel_cb_t, void *, read_quickpanel_cb_t));
+DECLARE_FUNCTION_MOCK1(mock_navigator_shutdown, navigator_shutdown, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_posix_print_stack_trace, posix_print_stack_trace, void(FILE *));
+DECLARE_FUNCTION_MOCK3(mock_posix_signal_handler, posix_signal_handler, void(int, siginfo_t *, void *));
+DECLARE_FUNCTION_MOCK3(mock_print_warning, print_warning, void(int, siginfo_t *, FILE *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_create_service, screen_reader_create_service, int(Service_Data *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_switch_enabled_get, screen_reader_switch_enabled_get, Eina_Bool(Eina_Bool *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_switch_enabled_set, screen_reader_switch_enabled_set, Eina_Bool(Eina_Bool));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_switch_wm_enabled_set, screen_reader_switch_wm_enabled_set, Eina_Bool(Eina_Bool));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_terminate_service, screen_reader_terminate_service, int(Service_Data *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_ui_launch, screen_reader_ui_launch, void(const char *));
+DECLARE_FUNCTION_MOCK0(mock_screen_reader_ui_terminate, screen_reader_ui_terminate, void());
+DECLARE_FUNCTION_MOCK0(mock_set_signal_handler, set_signal_handler, void());
+DECLARE_FUNCTION_MOCK1(mock_sound_n_vibration_feedback_generate, sound_n_vibration_feedback_generate, void(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK0(mock_spi_init, spi_init, SpiData *());
+DECLARE_FUNCTION_MOCK1(mock_spi_shutdown, spi_shutdown, void(SpiData *));
+DECLARE_FUNCTION_MOCK0(mock_system_notifications_init, system_notifications_init, System_Data *());
+DECLARE_FUNCTION_MOCK1(mock_system_notifications_shutdown, system_notifications_shutdown, void(System_Data *));
+DECLARE_FUNCTION_MOCK1(mock_system_status_get, system_status_get, void(void *));
+DECLARE_FUNCTION_MOCK0(mock_tw_init, tw_init, _Bool());
+DECLARE_FUNCTION_MOCK0(mock_tw_pause_get, tw_pause_get, Eina_Bool());
+DECLARE_FUNCTION_MOCK1(mock_tw_pause_set, tw_pause_set, Eina_Bool(Eina_Bool));
+DECLARE_FUNCTION_MOCK1(mock_tw_purge, tw_purge, void(Eina_Bool));
+DECLARE_FUNCTION_MOCK3(mock_tw_set_utterance_cb, tw_set_utterance_cb, void(utterance_cb_t, void *, utterance_cb_t));
+DECLARE_FUNCTION_MOCK0(mock_tw_shutdown, tw_shutdown, void());
+DECLARE_FUNCTION_MOCK2(mock_tw_speak, tw_speak, Read_Command *(char *, Eina_Bool));
+DECLARE_FUNCTION_MOCK5(mock_tw_speak_customized, tw_speak_customized, Read_Command *(char *, Eina_Bool, Eina_Bool, AtspiAccessible *, unsigned int));
+DECLARE_FUNCTION_MOCK0(mock_tw_stop_set, tw_stop_set, void());
+
--- /dev/null
+#include "mocked_navigator.h"
+
+IMPLEMENT_FUNCTION_MOCK1(mock__activate_widget, _activate_widget, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock__caret_move_backward, _caret_move_backward, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock__caret_move_beg, _caret_move_beg, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock__caret_move_end, _caret_move_end, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock__caret_move_forward, _caret_move_forward, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK2(mock__check_access_object_internal, _check_access_object_internal, Eina_Bool(NavigatorData *, Highlight_Type));
+IMPLEMENT_FUNCTION_MOCK2(mock__check_app_gesture_support, _check_app_gesture_support, void(NavigatorData *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK3(mock__current_highlight_object_set, _current_highlight_object_set, void(NavigatorData *, AtspiAccessible *, Highlight_Type));
+IMPLEMENT_FUNCTION_MOCK1(mock__current_highlight_on_keyboard_is, _current_highlight_on_keyboard_is, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK2(mock__cut_or_copy_selected_text, _cut_or_copy_selected_text, void(NavigatorData *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK1(mock__direct_scroll_back, _direct_scroll_back, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock__direct_scroll_forward, _direct_scroll_forward, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock__direct_scroll_to_first, _direct_scroll_to_first, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock__direct_scroll_to_last, _direct_scroll_to_last, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK2(mock__do_action, _do_action, Eina_Bool(AtspiAccessible *, char *));
+IMPLEMENT_FUNCTION_MOCK1(mock__focus_next, _focus_next, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock__focus_next_prev_is_movable, _focus_next_prev_is_movable, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock__focus_prev, _focus_prev, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK2(mock__focus_widget, _focus_widget, void(NavigatorData *, Gesture_Info *));
+IMPLEMENT_FUNCTION_MOCK2(mock__gesture_is_consumed, _gesture_is_consumed, Eina_Bool(NavigatorData *, Gesture_Info *));
+IMPLEMENT_FUNCTION_MOCK1(mock__get_currently_controlled_accessible, _get_currently_controlled_accessible, AtspiAccessible *(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock__get_main_window, _get_main_window, AtspiAction *(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK2(mock__granularity_text_read, _granularity_text_read, Eina_Bool(NavigatorData *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock__has_value, _has_value, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK2(mock__highlight_access_object, _highlight_access_object, Eina_Bool(AtspiAccessible *, Highlight_Type));
+IMPLEMENT_FUNCTION_MOCK1(mock__highlight_on_slider, _highlight_on_slider, void(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK2(mock__highlight_type_set, _highlight_type_set, void(AtspiAccessible *, Highlight_Type));
+IMPLEMENT_FUNCTION_MOCK1(mock__is_active_entry, _is_active_entry, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock__is_enabled, _is_enabled, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock__is_index_item, _is_index_item, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock__is_slider, _is_slider, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK2(mock__move_slider, _move_slider, void(NavigatorData *, Gesture_Info *));
+IMPLEMENT_FUNCTION_MOCK3(mock__new_highlighted_obj_changed, _new_highlighted_obj_changed, void(AtspiAccessible *, AtspiRole, void *));
+IMPLEMENT_FUNCTION_MOCK1(mock__on_auto_review_stop, _on_auto_review_stop, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock__on_utterance, _on_utterance, void(void *));
+IMPLEMENT_FUNCTION_MOCK1(mock__paste_text, _paste_text, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock__read_quickpanel, _read_quickpanel, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock__review_from_current, _review_from_current, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock__review_from_top, _review_from_top, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock__select_all_text, _select_all_text, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK2(mock__select_text_forward, _select_text_forward, void(NavigatorData *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK1(mock__send_app_gesture_support, _send_app_gesture_support, void(const char *));
+IMPLEMENT_FUNCTION_MOCK3(mock__send_highlighted_object_info, _send_highlighted_object_info, void(NavigatorData *, AtspiAccessible *, Gesture_Info *));
+IMPLEMENT_FUNCTION_MOCK0(mock__set_pause, _set_pause, void());
+IMPLEMENT_FUNCTION_MOCK1(mock__start_stop_signal_send, _start_stop_signal_send, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK2(mock__value_dec, _value_dec, void(NavigatorData *, int));
+IMPLEMENT_FUNCTION_MOCK2(mock__value_inc, _value_inc, void(NavigatorData *, int));
+IMPLEMENT_FUNCTION_MOCK4(mock__view_content_changed, _view_content_changed, void(AtspiAccessible *, AtspiRole, void *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK2(mock__widget_has_state, _widget_has_state, _Bool(AtspiAccessible *, AtspiStateType));
+IMPLEMENT_FUNCTION_MOCK3(mock__window_at_point_check, _window_at_point_check, void(NavigatorData *, int, int));
+IMPLEMENT_FUNCTION_MOCK2(mock__wm_text_selection_mode_set, _wm_text_selection_mode_set, void(NavigatorData *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK3(mock_app_tracker_at_point_window_get, app_tracker_at_point_window_get, AtspiAccessible *(App_Tracker_Data *, int, int));
+IMPLEMENT_FUNCTION_MOCK1(mock_app_tracker_context_valid_check, app_tracker_context_valid_check, AppTrackerContextValidility(App_Tracker_Data *));
+IMPLEMENT_FUNCTION_MOCK2(mock_app_tracker_init, app_tracker_init, App_Tracker_Data *(AppTrackerEventWithDefaultLabelInfoCB, NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK3(mock_app_tracker_new_obj_highlighted_callback_register, app_tracker_new_obj_highlighted_callback_register, void(App_Tracker_Data *, AppTrackerEventCB, void *));
+IMPLEMENT_FUNCTION_MOCK1(mock_app_tracker_new_obj_highlighted_callback_unregister, app_tracker_new_obj_highlighted_callback_unregister, void *(App_Tracker_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_app_tracker_scroll_gesture_required_object_info_send, app_tracker_scroll_gesture_required_object_info_send, void(App_Tracker_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_app_tracker_shutdown, app_tracker_shutdown, void(App_Tracker_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_app_tracker_top_window_get, app_tracker_top_window_get, AtspiAccessible *(App_Tracker_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_app_tracker_top_window_info_get, app_tracker_top_window_info_get, WindowInfo *(App_Tracker_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_app_tracker_top_window_info_get_opaque, app_tracker_top_window_info_get_opaque, WindowInfo *(void *));
+IMPLEMENT_FUNCTION_MOCK1(mock_auto_review_highlight_set, auto_review_highlight_set, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_auto_review_highlight_top, auto_review_highlight_top, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK2(mock_cycle_detection_check_if_in_cycle, cycle_detection_check_if_in_cycle, Eina_Bool(cycle_detection_data *, const void *));
+IMPLEMENT_FUNCTION_MOCK2(mock_cycle_detection_initialize, cycle_detection_initialize, void(cycle_detection_data *, const void *));
+IMPLEMENT_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+IMPLEMENT_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK3(mock_generate_what_to_read_and_speak, generate_what_to_read_and_speak, void(NavigatorData *, AtspiAccessible *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK2(mock_get_accuracy, get_accuracy, int(double, int));
+IMPLEMENT_FUNCTION_MOCK1(mock_get_objects_attributes, get_objects_attributes, unsigned short(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK0(mock_get_pointer_to_service_data_struct, get_pointer_to_service_data_struct, Service_Data *());
+IMPLEMENT_FUNCTION_MOCK0(mock_granularity_read_data_get, granularity_read_data_get, Granularity_Read_Data *());
+IMPLEMENT_FUNCTION_MOCK0(mock_granularity_read_init, granularity_read_init, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_granularity_read_terminate, granularity_read_terminate, void());
+IMPLEMENT_FUNCTION_MOCK2(mock_granularity_read_text_get, granularity_read_text_get, char *(AtspiAccessible *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK0(mock_granularity_read_text_list_init, granularity_read_text_list_init, void());
+IMPLEMENT_FUNCTION_MOCK1(mock_granularity_read_type_set, granularity_read_type_set, void(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK0(mock_granularity_read_ui_popup_show, granularity_read_ui_popup_show, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_haptic_module_disconnect, haptic_module_disconnect, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_haptic_module_init, haptic_module_init, void());
+IMPLEMENT_FUNCTION_MOCK2(mock_haptic_vibrate_start, haptic_vibrate_start, void(int, int));
+IMPLEMENT_FUNCTION_MOCK0(mock_haptic_vibrate_stop, haptic_vibrate_stop, void());
+IMPLEMENT_FUNCTION_MOCK3(mock_keyboard_event_status, keyboard_event_status, Eina_Bool(KeyboardTrackerData *, const int, const int));
+IMPLEMENT_FUNCTION_MOCK5(mock_keyboard_geometry_get, keyboard_geometry_get, Eina_Bool(const KeyboardTrackerData *, int *, int *, int *, int *));
+IMPLEMENT_FUNCTION_MOCK5(mock_keyboard_geometry_set, keyboard_geometry_set, void(KeyboardTrackerData *, int, int, int, int));
+IMPLEMENT_FUNCTION_MOCK4(mock_keyboard_signal_emit, keyboard_signal_emit, void(KeyboardTrackerData *, int, int, int));
+IMPLEMENT_FUNCTION_MOCK0(mock_keyboard_tracker_init, keyboard_tracker_init, KeyboardTrackerData *());
+IMPLEMENT_FUNCTION_MOCK3(mock_keyboard_tracker_register_top_window_info_get, keyboard_tracker_register_top_window_info_get, void(KeyboardTrackerData *, TopWindowInfoGetCb, void *));
+IMPLEMENT_FUNCTION_MOCK1(mock_keyboard_tracker_shutdown, keyboard_tracker_shutdown, void(KeyboardTrackerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_keyboard_tracker_unregister_top_window_info_get, keyboard_tracker_unregister_top_window_info_get, void *(KeyboardTrackerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_focus_next_visible, navigator_focus_next_visible, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_focus_prev_visible, navigator_focus_prev_visible, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK2(mock_navigator_gestures_tracker_register, navigator_gestures_tracker_register, void(NavigatorData *, GestureCB));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_gestures_tracker_unregister, navigator_gestures_tracker_unregister, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_flat_navi_context, navigator_get_flat_navi_context, FlatNaviContext *(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_ignore_keyboard_feedback, navigator_get_ignore_keyboard_feedback, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_is_text_selection_mode, navigator_get_is_text_selection_mode, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK0(mock_navigator_init, navigator_init, NavigatorData *());
+IMPLEMENT_FUNCTION_MOCK2(mock_navigator_set_ignore_keyboard_feedback, navigator_set_ignore_keyboard_feedback, void(NavigatorData *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK4(mock_navigator_set_read_quickpanel_cb, navigator_set_read_quickpanel_cb, void(NavigatorData *, read_quickpanel_cb_t, void *, read_quickpanel_cb_t));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_shutdown, navigator_shutdown, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_defunct_state, object_has_defunct_state, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_highlighted_state, object_has_highlighted_state, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_modal_role, object_has_modal_role, Eina_Bool(AtspiRole));
+IMPLEMENT_FUNCTION_MOCK2(mock_on_gesture_detected, on_gesture_detected, void(void *, const Eldbus_Message *));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_data_free, reading_composer_data_free, void(ReadingComposerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_data_get, reading_composer_data_get, ReadingComposerData *(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_description_get, reading_composer_description_get, char *(ReadingComposerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_extended_description_get, reading_composer_extended_description_get, char *(ReadingComposerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_name_get, reading_composer_name_get, char *(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_create_service, screen_reader_create_service, int(Service_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_terminate_service, screen_reader_terminate_service, int(Service_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_ui_launch, screen_reader_ui_launch, void(const char *));
+IMPLEMENT_FUNCTION_MOCK0(mock_screen_reader_ui_terminate, screen_reader_ui_terminate, void());
+IMPLEMENT_FUNCTION_MOCK3(mock_smart_notification, smart_notification, void(Notification_Type, int, int));
+IMPLEMENT_FUNCTION_MOCK0(mock_smart_notification_init, smart_notification_init, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_smart_notification_shutdown, smart_notification_shutdown, void());
+IMPLEMENT_FUNCTION_MOCK1(mock_sound_n_vibration_feedback_generate, sound_n_vibration_feedback_generate, void(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK0(mock_spi_init, spi_init, SpiData *());
+IMPLEMENT_FUNCTION_MOCK1(mock_spi_shutdown, spi_shutdown, void(SpiData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_state_to_char, state_to_char, char *(AtspiStateType));
+IMPLEMENT_FUNCTION_MOCK1(mock_symbol_lookup, symbol_lookup, const gchar *(const gchar *));
+IMPLEMENT_FUNCTION_MOCK1(mock_test_debug, test_debug, void(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_init, tw_init, _Bool());
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_pause_get, tw_pause_get, Eina_Bool());
+IMPLEMENT_FUNCTION_MOCK1(mock_tw_pause_set, tw_pause_set, Eina_Bool(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK1(mock_tw_purge, tw_purge, void(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK3(mock_tw_set_utterance_cb, tw_set_utterance_cb, void(utterance_cb_t, void *, utterance_cb_t));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_shutdown, tw_shutdown, void());
+IMPLEMENT_FUNCTION_MOCK2(mock_tw_speak, tw_speak, Read_Command *(char *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK5(mock_tw_speak_customized, tw_speak_customized, Read_Command *(char *, Eina_Bool, Eina_Bool, AtspiAccessible *, unsigned int));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_stop_set, tw_stop_set, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_utils_a11y_bus_connection_get, utils_a11y_bus_connection_get, Eldbus_Connection *());
+IMPLEMENT_FUNCTION_MOCK1(mock_utils_a11y_bus_connection_set, utils_a11y_bus_connection_set, void(Eldbus_Connection *));
+IMPLEMENT_FUNCTION_MOCK1(mock_utils_enum_to_string, utils_enum_to_string, const char *(Gesture));
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_exit, vc_exit, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_haptic, vc_get_haptic, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_keyboard_feedback, vc_get_keyboard_feedback, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_lcd_backlight_timeout, vc_get_lcd_backlight_timeout, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_read_description, vc_get_read_description, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_sound_feedback, vc_get_sound_feedback, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_init, vc_init, void());
+
--- /dev/null
+#pragma once
+
+extern "C" {
+#include <atspi/atspi.h>
+#include <ecore-1/Ecore.h>
+#include <eldbus-1/Eldbus.h>
+#include "app_tracker.h"
+#include "granularity_read.h"
+#include "keyboard_tracker.h"
+#include "logger.h"
+#include "reading_composer.h"
+#include "screen_reader.h"
+#include "screen_reader_haptic.h"
+#include "screen_reader_tts.h"
+#include "screen_reader_vconf.h"
+#include "smart_notification.h"
+#include "symbols.h"
+#include "utils.h"
+}
+#include <cmock/cmock.h>
+
+extern "C" void _activate_widget(NavigatorData * nd);
+extern "C" void _caret_move_backward(NavigatorData * nd);
+extern "C" void _caret_move_beg(NavigatorData * nd);
+extern "C" void _caret_move_end(NavigatorData * nd);
+extern "C" void _caret_move_forward(NavigatorData * nd);
+extern "C" Eina_Bool _check_access_object_internal(NavigatorData * nd, Highlight_Type h_type);
+extern "C" void _check_app_gesture_support(NavigatorData * nd, AtspiAccessible * obj);
+extern "C" void _current_highlight_object_set(NavigatorData * nd, AtspiAccessible * obj, Highlight_Type h_type);
+extern "C" Eina_Bool _current_highlight_on_keyboard_is(NavigatorData * nd);
+extern "C" void _cut_or_copy_selected_text(NavigatorData * nd, Eina_Bool is_cut);
+extern "C" void _direct_scroll_back(NavigatorData * nd);
+extern "C" void _direct_scroll_forward(NavigatorData * nd);
+extern "C" void _direct_scroll_to_first(NavigatorData * nd);
+extern "C" void _direct_scroll_to_last(NavigatorData * nd);
+extern "C" Eina_Bool _do_action(AtspiAccessible * obj, char * expected_action);
+extern "C" void _focus_next(NavigatorData * nd);
+extern "C" Eina_Bool _focus_next_prev_is_movable(AtspiAccessible * obj);
+extern "C" void _focus_prev(NavigatorData * nd);
+extern "C" void _focus_widget(NavigatorData * nd, Gesture_Info * info);
+extern "C" Eina_Bool _gesture_is_consumed(NavigatorData * nd, Gesture_Info * info);
+extern "C" AtspiAccessible * _get_currently_controlled_accessible(AtspiAccessible * obj);
+extern "C" AtspiAction * _get_main_window(NavigatorData * nd);
+extern "C" Eina_Bool _granularity_text_read(NavigatorData * nd, Eina_Bool next);
+extern "C" Eina_Bool _has_value(NavigatorData * nd);
+extern "C" Eina_Bool _highlight_access_object(AtspiAccessible * obj, Highlight_Type h_type);
+extern "C" void _highlight_on_slider(Eina_Bool is_slider);
+extern "C" void _highlight_type_set(AtspiAccessible * obj, Highlight_Type h_type);
+extern "C" Eina_Bool _is_active_entry(NavigatorData * nd);
+extern "C" Eina_Bool _is_enabled(NavigatorData * nd);
+extern "C" Eina_Bool _is_index_item(NavigatorData * nd);
+extern "C" Eina_Bool _is_slider(AtspiAccessible * obj);
+extern "C" void _move_slider(NavigatorData * nd, Gesture_Info * gi);
+extern "C" void _new_highlighted_obj_changed(AtspiAccessible * new_highlighted_obj, AtspiRole role, void * user_data);
+extern "C" void _on_auto_review_stop(NavigatorData * nd);
+extern "C" void _on_utterance(void * user_data);
+extern "C" void _paste_text(NavigatorData * nd);
+extern "C" void _read_quickpanel(NavigatorData * nd);
+extern "C" void _review_from_current(NavigatorData * nd);
+extern "C" void _review_from_top(NavigatorData * nd);
+extern "C" void _select_all_text(NavigatorData * nd);
+extern "C" void _select_text_forward(NavigatorData * nd, Eina_Bool forward);
+extern "C" void _send_app_gesture_support(const char * app_gesture_support);
+extern "C" void _send_highlighted_object_info(NavigatorData * nd, AtspiAccessible * obj, Gesture_Info * info);
+extern "C" void _set_pause();
+extern "C" void _start_stop_signal_send(NavigatorData * nd);
+extern "C" void _value_dec(NavigatorData * nd, int diff);
+extern "C" void _value_inc(NavigatorData * nd, int diff);
+extern "C" void _view_content_changed(AtspiAccessible * root, AtspiRole role, void * data, Eina_Bool default_label_enabled);
+extern "C" _Bool _widget_has_state(AtspiAccessible * obj, AtspiStateType type);
+extern "C" void _window_at_point_check(NavigatorData * nd, int x, int y);
+extern "C" void _wm_text_selection_mode_set(NavigatorData * nd, Eina_Bool is_selection_mode);
+extern "C" WindowInfo * app_tracker_top_window_info_get_opaque(void * user_data);
+extern "C" void auto_review_highlight_set(NavigatorData * nd);
+extern "C" void auto_review_highlight_top(NavigatorData * nd);
+extern "C" void navigator_gestures_tracker_register(NavigatorData * nd, GestureCB gesture_cb);
+extern "C" void navigator_gestures_tracker_unregister(NavigatorData * nd);
+extern "C" void on_gesture_detected(void * data, const Eldbus_Message * msg);
+extern "C" char * state_to_char(AtspiStateType state);
+extern "C" void test_debug(AtspiAccessible * current_widget);
+DECLARE_FUNCTION_MOCK1(mock__activate_widget, _activate_widget, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock__caret_move_backward, _caret_move_backward, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock__caret_move_beg, _caret_move_beg, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock__caret_move_end, _caret_move_end, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock__caret_move_forward, _caret_move_forward, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK2(mock__check_access_object_internal, _check_access_object_internal, Eina_Bool(NavigatorData *, Highlight_Type));
+DECLARE_FUNCTION_MOCK2(mock__check_app_gesture_support, _check_app_gesture_support, void(NavigatorData *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK3(mock__current_highlight_object_set, _current_highlight_object_set, void(NavigatorData *, AtspiAccessible *, Highlight_Type));
+DECLARE_FUNCTION_MOCK1(mock__current_highlight_on_keyboard_is, _current_highlight_on_keyboard_is, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK2(mock__cut_or_copy_selected_text, _cut_or_copy_selected_text, void(NavigatorData *, Eina_Bool));
+DECLARE_FUNCTION_MOCK1(mock__direct_scroll_back, _direct_scroll_back, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock__direct_scroll_forward, _direct_scroll_forward, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock__direct_scroll_to_first, _direct_scroll_to_first, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock__direct_scroll_to_last, _direct_scroll_to_last, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK2(mock__do_action, _do_action, Eina_Bool(AtspiAccessible *, char *));
+DECLARE_FUNCTION_MOCK1(mock__focus_next, _focus_next, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock__focus_next_prev_is_movable, _focus_next_prev_is_movable, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock__focus_prev, _focus_prev, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK2(mock__focus_widget, _focus_widget, void(NavigatorData *, Gesture_Info *));
+DECLARE_FUNCTION_MOCK2(mock__gesture_is_consumed, _gesture_is_consumed, Eina_Bool(NavigatorData *, Gesture_Info *));
+DECLARE_FUNCTION_MOCK1(mock__get_currently_controlled_accessible, _get_currently_controlled_accessible, AtspiAccessible *(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock__get_main_window, _get_main_window, AtspiAction *(NavigatorData *));
+DECLARE_FUNCTION_MOCK2(mock__granularity_text_read, _granularity_text_read, Eina_Bool(NavigatorData *, Eina_Bool));
+DECLARE_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock__has_value, _has_value, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK2(mock__highlight_access_object, _highlight_access_object, Eina_Bool(AtspiAccessible *, Highlight_Type));
+DECLARE_FUNCTION_MOCK1(mock__highlight_on_slider, _highlight_on_slider, void(Eina_Bool));
+DECLARE_FUNCTION_MOCK2(mock__highlight_type_set, _highlight_type_set, void(AtspiAccessible *, Highlight_Type));
+DECLARE_FUNCTION_MOCK1(mock__is_active_entry, _is_active_entry, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock__is_enabled, _is_enabled, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock__is_index_item, _is_index_item, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock__is_slider, _is_slider, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK2(mock__move_slider, _move_slider, void(NavigatorData *, Gesture_Info *));
+DECLARE_FUNCTION_MOCK3(mock__new_highlighted_obj_changed, _new_highlighted_obj_changed, void(AtspiAccessible *, AtspiRole, void *));
+DECLARE_FUNCTION_MOCK1(mock__on_auto_review_stop, _on_auto_review_stop, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock__on_utterance, _on_utterance, void(void *));
+DECLARE_FUNCTION_MOCK1(mock__paste_text, _paste_text, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock__read_quickpanel, _read_quickpanel, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock__review_from_current, _review_from_current, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock__review_from_top, _review_from_top, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock__select_all_text, _select_all_text, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK2(mock__select_text_forward, _select_text_forward, void(NavigatorData *, Eina_Bool));
+DECLARE_FUNCTION_MOCK1(mock__send_app_gesture_support, _send_app_gesture_support, void(const char *));
+DECLARE_FUNCTION_MOCK3(mock__send_highlighted_object_info, _send_highlighted_object_info, void(NavigatorData *, AtspiAccessible *, Gesture_Info *));
+DECLARE_FUNCTION_MOCK0(mock__set_pause, _set_pause, void());
+DECLARE_FUNCTION_MOCK1(mock__start_stop_signal_send, _start_stop_signal_send, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK2(mock__value_dec, _value_dec, void(NavigatorData *, int));
+DECLARE_FUNCTION_MOCK2(mock__value_inc, _value_inc, void(NavigatorData *, int));
+DECLARE_FUNCTION_MOCK4(mock__view_content_changed, _view_content_changed, void(AtspiAccessible *, AtspiRole, void *, Eina_Bool));
+DECLARE_FUNCTION_MOCK2(mock__widget_has_state, _widget_has_state, _Bool(AtspiAccessible *, AtspiStateType));
+DECLARE_FUNCTION_MOCK3(mock__window_at_point_check, _window_at_point_check, void(NavigatorData *, int, int));
+DECLARE_FUNCTION_MOCK2(mock__wm_text_selection_mode_set, _wm_text_selection_mode_set, void(NavigatorData *, Eina_Bool));
+DECLARE_FUNCTION_MOCK3(mock_app_tracker_at_point_window_get, app_tracker_at_point_window_get, AtspiAccessible *(App_Tracker_Data *, int, int));
+DECLARE_FUNCTION_MOCK1(mock_app_tracker_context_valid_check, app_tracker_context_valid_check, AppTrackerContextValidility(App_Tracker_Data *));
+DECLARE_FUNCTION_MOCK2(mock_app_tracker_init, app_tracker_init, App_Tracker_Data *(AppTrackerEventWithDefaultLabelInfoCB, NavigatorData *));
+DECLARE_FUNCTION_MOCK3(mock_app_tracker_new_obj_highlighted_callback_register, app_tracker_new_obj_highlighted_callback_register, void(App_Tracker_Data *, AppTrackerEventCB, void *));
+DECLARE_FUNCTION_MOCK1(mock_app_tracker_new_obj_highlighted_callback_unregister, app_tracker_new_obj_highlighted_callback_unregister, void *(App_Tracker_Data *));
+DECLARE_FUNCTION_MOCK1(mock_app_tracker_scroll_gesture_required_object_info_send, app_tracker_scroll_gesture_required_object_info_send, void(App_Tracker_Data *));
+DECLARE_FUNCTION_MOCK1(mock_app_tracker_shutdown, app_tracker_shutdown, void(App_Tracker_Data *));
+DECLARE_FUNCTION_MOCK1(mock_app_tracker_top_window_get, app_tracker_top_window_get, AtspiAccessible *(App_Tracker_Data *));
+DECLARE_FUNCTION_MOCK1(mock_app_tracker_top_window_info_get, app_tracker_top_window_info_get, WindowInfo *(App_Tracker_Data *));
+DECLARE_FUNCTION_MOCK1(mock_app_tracker_top_window_info_get_opaque, app_tracker_top_window_info_get_opaque, WindowInfo *(void *));
+DECLARE_FUNCTION_MOCK1(mock_auto_review_highlight_set, auto_review_highlight_set, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_auto_review_highlight_top, auto_review_highlight_top, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK2(mock_cycle_detection_check_if_in_cycle, cycle_detection_check_if_in_cycle, Eina_Bool(cycle_detection_data *, const void *));
+DECLARE_FUNCTION_MOCK2(mock_cycle_detection_initialize, cycle_detection_initialize, void(cycle_detection_data *, const void *));
+DECLARE_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+DECLARE_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK3(mock_generate_what_to_read_and_speak, generate_what_to_read_and_speak, void(NavigatorData *, AtspiAccessible *, Eina_Bool));
+DECLARE_FUNCTION_MOCK2(mock_get_accuracy, get_accuracy, int(double, int));
+DECLARE_FUNCTION_MOCK1(mock_get_objects_attributes, get_objects_attributes, unsigned short(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK0(mock_get_pointer_to_service_data_struct, get_pointer_to_service_data_struct, Service_Data *());
+DECLARE_FUNCTION_MOCK0(mock_granularity_read_data_get, granularity_read_data_get, Granularity_Read_Data *());
+DECLARE_FUNCTION_MOCK0(mock_granularity_read_init, granularity_read_init, void());
+DECLARE_FUNCTION_MOCK0(mock_granularity_read_terminate, granularity_read_terminate, void());
+DECLARE_FUNCTION_MOCK2(mock_granularity_read_text_get, granularity_read_text_get, char *(AtspiAccessible *, Eina_Bool));
+DECLARE_FUNCTION_MOCK0(mock_granularity_read_text_list_init, granularity_read_text_list_init, void());
+DECLARE_FUNCTION_MOCK1(mock_granularity_read_type_set, granularity_read_type_set, void(Eina_Bool));
+DECLARE_FUNCTION_MOCK0(mock_granularity_read_ui_popup_show, granularity_read_ui_popup_show, void());
+DECLARE_FUNCTION_MOCK0(mock_haptic_module_disconnect, haptic_module_disconnect, void());
+DECLARE_FUNCTION_MOCK0(mock_haptic_module_init, haptic_module_init, void());
+DECLARE_FUNCTION_MOCK2(mock_haptic_vibrate_start, haptic_vibrate_start, void(int, int));
+DECLARE_FUNCTION_MOCK0(mock_haptic_vibrate_stop, haptic_vibrate_stop, void());
+DECLARE_FUNCTION_MOCK3(mock_keyboard_event_status, keyboard_event_status, Eina_Bool(KeyboardTrackerData *, const int, const int));
+DECLARE_FUNCTION_MOCK5(mock_keyboard_geometry_get, keyboard_geometry_get, Eina_Bool(const KeyboardTrackerData *, int *, int *, int *, int *));
+DECLARE_FUNCTION_MOCK5(mock_keyboard_geometry_set, keyboard_geometry_set, void(KeyboardTrackerData *, int, int, int, int));
+DECLARE_FUNCTION_MOCK4(mock_keyboard_signal_emit, keyboard_signal_emit, void(KeyboardTrackerData *, int, int, int));
+DECLARE_FUNCTION_MOCK0(mock_keyboard_tracker_init, keyboard_tracker_init, KeyboardTrackerData *());
+DECLARE_FUNCTION_MOCK3(mock_keyboard_tracker_register_top_window_info_get, keyboard_tracker_register_top_window_info_get, void(KeyboardTrackerData *, TopWindowInfoGetCb, void *));
+DECLARE_FUNCTION_MOCK1(mock_keyboard_tracker_shutdown, keyboard_tracker_shutdown, void(KeyboardTrackerData *));
+DECLARE_FUNCTION_MOCK1(mock_keyboard_tracker_unregister_top_window_info_get, keyboard_tracker_unregister_top_window_info_get, void *(KeyboardTrackerData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_focus_next_visible, navigator_focus_next_visible, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_focus_prev_visible, navigator_focus_prev_visible, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK2(mock_navigator_gestures_tracker_register, navigator_gestures_tracker_register, void(NavigatorData *, GestureCB));
+DECLARE_FUNCTION_MOCK1(mock_navigator_gestures_tracker_unregister, navigator_gestures_tracker_unregister, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_flat_navi_context, navigator_get_flat_navi_context, FlatNaviContext *(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_ignore_keyboard_feedback, navigator_get_ignore_keyboard_feedback, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_is_text_selection_mode, navigator_get_is_text_selection_mode, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK0(mock_navigator_init, navigator_init, NavigatorData *());
+DECLARE_FUNCTION_MOCK2(mock_navigator_set_ignore_keyboard_feedback, navigator_set_ignore_keyboard_feedback, void(NavigatorData *, Eina_Bool));
+DECLARE_FUNCTION_MOCK4(mock_navigator_set_read_quickpanel_cb, navigator_set_read_quickpanel_cb, void(NavigatorData *, read_quickpanel_cb_t, void *, read_quickpanel_cb_t));
+DECLARE_FUNCTION_MOCK1(mock_navigator_shutdown, navigator_shutdown, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_defunct_state, object_has_defunct_state, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_highlighted_state, object_has_highlighted_state, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_modal_role, object_has_modal_role, Eina_Bool(AtspiRole));
+DECLARE_FUNCTION_MOCK2(mock_on_gesture_detected, on_gesture_detected, void(void *, const Eldbus_Message *));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_data_free, reading_composer_data_free, void(ReadingComposerData *));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_data_get, reading_composer_data_get, ReadingComposerData *(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_description_get, reading_composer_description_get, char *(ReadingComposerData *));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_extended_description_get, reading_composer_extended_description_get, char *(ReadingComposerData *));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_name_get, reading_composer_name_get, char *(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_create_service, screen_reader_create_service, int(Service_Data *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_terminate_service, screen_reader_terminate_service, int(Service_Data *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_ui_launch, screen_reader_ui_launch, void(const char *));
+DECLARE_FUNCTION_MOCK0(mock_screen_reader_ui_terminate, screen_reader_ui_terminate, void());
+DECLARE_FUNCTION_MOCK3(mock_smart_notification, smart_notification, void(Notification_Type, int, int));
+DECLARE_FUNCTION_MOCK0(mock_smart_notification_init, smart_notification_init, void());
+DECLARE_FUNCTION_MOCK0(mock_smart_notification_shutdown, smart_notification_shutdown, void());
+DECLARE_FUNCTION_MOCK1(mock_sound_n_vibration_feedback_generate, sound_n_vibration_feedback_generate, void(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK0(mock_spi_init, spi_init, SpiData *());
+DECLARE_FUNCTION_MOCK1(mock_spi_shutdown, spi_shutdown, void(SpiData *));
+DECLARE_FUNCTION_MOCK1(mock_state_to_char, state_to_char, char *(AtspiStateType));
+DECLARE_FUNCTION_MOCK1(mock_symbol_lookup, symbol_lookup, const gchar *(const gchar *));
+DECLARE_FUNCTION_MOCK1(mock_test_debug, test_debug, void(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK0(mock_tw_init, tw_init, _Bool());
+DECLARE_FUNCTION_MOCK0(mock_tw_pause_get, tw_pause_get, Eina_Bool());
+DECLARE_FUNCTION_MOCK1(mock_tw_pause_set, tw_pause_set, Eina_Bool(Eina_Bool));
+DECLARE_FUNCTION_MOCK1(mock_tw_purge, tw_purge, void(Eina_Bool));
+DECLARE_FUNCTION_MOCK3(mock_tw_set_utterance_cb, tw_set_utterance_cb, void(utterance_cb_t, void *, utterance_cb_t));
+DECLARE_FUNCTION_MOCK0(mock_tw_shutdown, tw_shutdown, void());
+DECLARE_FUNCTION_MOCK2(mock_tw_speak, tw_speak, Read_Command *(char *, Eina_Bool));
+DECLARE_FUNCTION_MOCK5(mock_tw_speak_customized, tw_speak_customized, Read_Command *(char *, Eina_Bool, Eina_Bool, AtspiAccessible *, unsigned int));
+DECLARE_FUNCTION_MOCK0(mock_tw_stop_set, tw_stop_set, void());
+DECLARE_FUNCTION_MOCK0(mock_utils_a11y_bus_connection_get, utils_a11y_bus_connection_get, Eldbus_Connection *());
+DECLARE_FUNCTION_MOCK1(mock_utils_a11y_bus_connection_set, utils_a11y_bus_connection_set, void(Eldbus_Connection *));
+DECLARE_FUNCTION_MOCK1(mock_utils_enum_to_string, utils_enum_to_string, const char *(Gesture));
+DECLARE_FUNCTION_MOCK0(mock_vc_exit, vc_exit, void());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_haptic, vc_get_haptic, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_keyboard_feedback, vc_get_keyboard_feedback, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_lcd_backlight_timeout, vc_get_lcd_backlight_timeout, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_read_description, vc_get_read_description, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_sound_feedback, vc_get_sound_feedback, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_init, vc_init, void());
+
--- /dev/null
+#include "mocked_reading_composer.h"
+
+IMPLEMENT_FUNCTION_MOCK2(mock_cycle_detection_check_if_in_cycle, cycle_detection_check_if_in_cycle, Eina_Bool(cycle_detection_data *, const void *));
+IMPLEMENT_FUNCTION_MOCK2(mock_cycle_detection_initialize, cycle_detection_initialize, void(cycle_detection_data *, const void *));
+IMPLEMENT_FUNCTION_MOCK2(mock_get_accuracy, get_accuracy, int(double, int));
+IMPLEMENT_FUNCTION_MOCK1(mock_get_objects_attributes, get_objects_attributes, unsigned short(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_defunct_state, object_has_defunct_state, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_highlighted_state, object_has_highlighted_state, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_modal_role, object_has_modal_role, Eina_Bool(AtspiRole));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_data_free, reading_composer_data_free, void(ReadingComposerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_data_get, reading_composer_data_get, ReadingComposerData *(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_description_get, reading_composer_description_get, char *(ReadingComposerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_extended_description_get, reading_composer_extended_description_get, char *(ReadingComposerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_name_get, reading_composer_name_get, char *(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK0(mock_utils_a11y_bus_connection_get, utils_a11y_bus_connection_get, Eldbus_Connection *());
+IMPLEMENT_FUNCTION_MOCK1(mock_utils_a11y_bus_connection_set, utils_a11y_bus_connection_set, void(Eldbus_Connection *));
+IMPLEMENT_FUNCTION_MOCK1(mock_utils_enum_to_string, utils_enum_to_string, const char *(Gesture));
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_exit, vc_exit, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_haptic, vc_get_haptic, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_keyboard_feedback, vc_get_keyboard_feedback, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_lcd_backlight_timeout, vc_get_lcd_backlight_timeout, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_read_description, vc_get_read_description, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_sound_feedback, vc_get_sound_feedback, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_init, vc_init, void());
+
--- /dev/null
+#pragma once
+
+extern "C" {
+#include <atspi/atspi.h>
+#include <tts.h>
+#include "reading_composer.h"
+#include "logger.h"
+#include "screen_reader_vconf.h"
+#include "utils.h"
+}
+#include <cmock/cmock.h>
+
+DECLARE_FUNCTION_MOCK2(mock_cycle_detection_check_if_in_cycle, cycle_detection_check_if_in_cycle, Eina_Bool(cycle_detection_data *, const void *));
+DECLARE_FUNCTION_MOCK2(mock_cycle_detection_initialize, cycle_detection_initialize, void(cycle_detection_data *, const void *));
+DECLARE_FUNCTION_MOCK2(mock_get_accuracy, get_accuracy, int(double, int));
+DECLARE_FUNCTION_MOCK1(mock_get_objects_attributes, get_objects_attributes, unsigned short(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_defunct_state, object_has_defunct_state, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_highlighted_state, object_has_highlighted_state, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_modal_role, object_has_modal_role, Eina_Bool(AtspiRole));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_data_free, reading_composer_data_free, void(ReadingComposerData *));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_data_get, reading_composer_data_get, ReadingComposerData *(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_description_get, reading_composer_description_get, char *(ReadingComposerData *));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_extended_description_get, reading_composer_extended_description_get, char *(ReadingComposerData *));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_name_get, reading_composer_name_get, char *(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK0(mock_utils_a11y_bus_connection_get, utils_a11y_bus_connection_get, Eldbus_Connection *());
+DECLARE_FUNCTION_MOCK1(mock_utils_a11y_bus_connection_set, utils_a11y_bus_connection_set, void(Eldbus_Connection *));
+DECLARE_FUNCTION_MOCK1(mock_utils_enum_to_string, utils_enum_to_string, const char *(Gesture));
+DECLARE_FUNCTION_MOCK0(mock_vc_exit, vc_exit, void());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_haptic, vc_get_haptic, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_keyboard_feedback, vc_get_keyboard_feedback, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_lcd_backlight_timeout, vc_get_lcd_backlight_timeout, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_read_description, vc_get_read_description, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_sound_feedback, vc_get_sound_feedback, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_init, vc_init, void());
+
--- /dev/null
+#include "mocked_screen_reader.h"
+
+IMPLEMENT_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+IMPLEMENT_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK3(mock_generate_what_to_read_and_speak, generate_what_to_read_and_speak, void(NavigatorData *, AtspiAccessible *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK0(mock_get_pointer_to_service_data_struct, get_pointer_to_service_data_struct, Service_Data *());
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_focus_next_visible, navigator_focus_next_visible, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_focus_prev_visible, navigator_focus_prev_visible, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_flat_navi_context, navigator_get_flat_navi_context, FlatNaviContext *(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_ignore_keyboard_feedback, navigator_get_ignore_keyboard_feedback, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_is_text_selection_mode, navigator_get_is_text_selection_mode, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK0(mock_navigator_init, navigator_init, NavigatorData *());
+IMPLEMENT_FUNCTION_MOCK2(mock_navigator_set_ignore_keyboard_feedback, navigator_set_ignore_keyboard_feedback, void(NavigatorData *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK4(mock_navigator_set_read_quickpanel_cb, navigator_set_read_quickpanel_cb, void(NavigatorData *, read_quickpanel_cb_t, void *, read_quickpanel_cb_t));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_shutdown, navigator_shutdown, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_create_service, screen_reader_create_service, int(Service_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_terminate_service, screen_reader_terminate_service, int(Service_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_ui_launch, screen_reader_ui_launch, void(const char *));
+IMPLEMENT_FUNCTION_MOCK0(mock_screen_reader_ui_terminate, screen_reader_ui_terminate, void());
+IMPLEMENT_FUNCTION_MOCK1(mock_sound_n_vibration_feedback_generate, sound_n_vibration_feedback_generate, void(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK0(mock_spi_init, spi_init, SpiData *());
+IMPLEMENT_FUNCTION_MOCK1(mock_spi_shutdown, spi_shutdown, void(SpiData *));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_init, tw_init, _Bool());
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_pause_get, tw_pause_get, Eina_Bool());
+IMPLEMENT_FUNCTION_MOCK1(mock_tw_pause_set, tw_pause_set, Eina_Bool(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK1(mock_tw_purge, tw_purge, void(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK3(mock_tw_set_utterance_cb, tw_set_utterance_cb, void(utterance_cb_t, void *, utterance_cb_t));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_shutdown, tw_shutdown, void());
+IMPLEMENT_FUNCTION_MOCK2(mock_tw_speak, tw_speak, Read_Command *(char *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK5(mock_tw_speak_customized, tw_speak_customized, Read_Command *(char *, Eina_Bool, Eina_Bool, AtspiAccessible *, unsigned int));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_stop_set, tw_stop_set, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_exit, vc_exit, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_haptic, vc_get_haptic, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_keyboard_feedback, vc_get_keyboard_feedback, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_lcd_backlight_timeout, vc_get_lcd_backlight_timeout, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_read_description, vc_get_read_description, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_sound_feedback, vc_get_sound_feedback, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_init, vc_init, void());
+
--- /dev/null
+#pragma once
+
+extern "C" {
+#include <appsvc/appsvc.h>
+#include <aul/aul.h>
+#include <vconf.h>
+#include "logger.h"
+#include "screen_reader.h"
+#include "screen_reader_tts.h"
+#include "screen_reader_vconf.h"
+}
+#include <cmock/cmock.h>
+
+DECLARE_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+DECLARE_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK3(mock_generate_what_to_read_and_speak, generate_what_to_read_and_speak, void(NavigatorData *, AtspiAccessible *, Eina_Bool));
+DECLARE_FUNCTION_MOCK0(mock_get_pointer_to_service_data_struct, get_pointer_to_service_data_struct, Service_Data *());
+DECLARE_FUNCTION_MOCK1(mock_navigator_focus_next_visible, navigator_focus_next_visible, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_focus_prev_visible, navigator_focus_prev_visible, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_flat_navi_context, navigator_get_flat_navi_context, FlatNaviContext *(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_ignore_keyboard_feedback, navigator_get_ignore_keyboard_feedback, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_is_text_selection_mode, navigator_get_is_text_selection_mode, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK0(mock_navigator_init, navigator_init, NavigatorData *());
+DECLARE_FUNCTION_MOCK2(mock_navigator_set_ignore_keyboard_feedback, navigator_set_ignore_keyboard_feedback, void(NavigatorData *, Eina_Bool));
+DECLARE_FUNCTION_MOCK4(mock_navigator_set_read_quickpanel_cb, navigator_set_read_quickpanel_cb, void(NavigatorData *, read_quickpanel_cb_t, void *, read_quickpanel_cb_t));
+DECLARE_FUNCTION_MOCK1(mock_navigator_shutdown, navigator_shutdown, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_create_service, screen_reader_create_service, int(Service_Data *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_terminate_service, screen_reader_terminate_service, int(Service_Data *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_ui_launch, screen_reader_ui_launch, void(const char *));
+DECLARE_FUNCTION_MOCK0(mock_screen_reader_ui_terminate, screen_reader_ui_terminate, void());
+DECLARE_FUNCTION_MOCK1(mock_sound_n_vibration_feedback_generate, sound_n_vibration_feedback_generate, void(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK0(mock_spi_init, spi_init, SpiData *());
+DECLARE_FUNCTION_MOCK1(mock_spi_shutdown, spi_shutdown, void(SpiData *));
+DECLARE_FUNCTION_MOCK0(mock_tw_init, tw_init, _Bool());
+DECLARE_FUNCTION_MOCK0(mock_tw_pause_get, tw_pause_get, Eina_Bool());
+DECLARE_FUNCTION_MOCK1(mock_tw_pause_set, tw_pause_set, Eina_Bool(Eina_Bool));
+DECLARE_FUNCTION_MOCK1(mock_tw_purge, tw_purge, void(Eina_Bool));
+DECLARE_FUNCTION_MOCK3(mock_tw_set_utterance_cb, tw_set_utterance_cb, void(utterance_cb_t, void *, utterance_cb_t));
+DECLARE_FUNCTION_MOCK0(mock_tw_shutdown, tw_shutdown, void());
+DECLARE_FUNCTION_MOCK2(mock_tw_speak, tw_speak, Read_Command *(char *, Eina_Bool));
+DECLARE_FUNCTION_MOCK5(mock_tw_speak_customized, tw_speak_customized, Read_Command *(char *, Eina_Bool, Eina_Bool, AtspiAccessible *, unsigned int));
+DECLARE_FUNCTION_MOCK0(mock_tw_stop_set, tw_stop_set, void());
+DECLARE_FUNCTION_MOCK0(mock_vc_exit, vc_exit, void());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_haptic, vc_get_haptic, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_keyboard_feedback, vc_get_keyboard_feedback, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_lcd_backlight_timeout, vc_get_lcd_backlight_timeout, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_read_description, vc_get_read_description, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_sound_feedback, vc_get_sound_feedback, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_init, vc_init, void());
+
--- /dev/null
+#include "mocked_screen_reader_haptic.h"
+
+IMPLEMENT_FUNCTION_MOCK0(mock_haptic_module_disconnect, haptic_module_disconnect, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_haptic_module_init, haptic_module_init, void());
+IMPLEMENT_FUNCTION_MOCK2(mock_haptic_vibrate_start, haptic_vibrate_start, void(int, int));
+IMPLEMENT_FUNCTION_MOCK0(mock_haptic_vibrate_stop, haptic_vibrate_stop, void());
+IMPLEMENT_FUNCTION_MOCK3(mock_smart_notification, smart_notification, void(Notification_Type, int, int));
+IMPLEMENT_FUNCTION_MOCK0(mock_smart_notification_init, smart_notification_init, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_smart_notification_shutdown, smart_notification_shutdown, void());
+
--- /dev/null
+#pragma once
+
+extern "C" {
+#include <device/haptic.h>
+#include "logger.h"
+#include "smart_notification.h"
+}
+#include <cmock/cmock.h>
+
+DECLARE_FUNCTION_MOCK0(mock_haptic_module_disconnect, haptic_module_disconnect, void());
+DECLARE_FUNCTION_MOCK0(mock_haptic_module_init, haptic_module_init, void());
+DECLARE_FUNCTION_MOCK2(mock_haptic_vibrate_start, haptic_vibrate_start, void(int, int));
+DECLARE_FUNCTION_MOCK0(mock_haptic_vibrate_stop, haptic_vibrate_stop, void());
+DECLARE_FUNCTION_MOCK3(mock_smart_notification, smart_notification, void(Notification_Type, int, int));
+DECLARE_FUNCTION_MOCK0(mock_smart_notification_init, smart_notification_init, void());
+DECLARE_FUNCTION_MOCK0(mock_smart_notification_shutdown, smart_notification_shutdown, void());
+
--- /dev/null
+#include "mocked_screen_reader_spi.h"
+
+IMPLEMENT_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_allow_recursive_name, allow_recursive_name, _Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK4(mock_create_shtd, create_shtd, SignalHandlingTimerData *(SpiData *, AtspiAccessible *, char *, char *));
+IMPLEMENT_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+IMPLEMENT_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_free_shtd, free_shtd, void(SignalHandlingTimerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_generate_description_for_subtree, generate_description_for_subtree, char *(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK3(mock_generate_what_to_read_and_speak, generate_what_to_read_and_speak, void(NavigatorData *, AtspiAccessible *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK0(mock_get_pointer_to_service_data_struct, get_pointer_to_service_data_struct, Service_Data *());
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_focus_next_visible, navigator_focus_next_visible, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_focus_prev_visible, navigator_focus_prev_visible, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_flat_navi_context, navigator_get_flat_navi_context, FlatNaviContext *(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_ignore_keyboard_feedback, navigator_get_ignore_keyboard_feedback, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_is_text_selection_mode, navigator_get_is_text_selection_mode, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK0(mock_navigator_init, navigator_init, NavigatorData *());
+IMPLEMENT_FUNCTION_MOCK2(mock_navigator_set_ignore_keyboard_feedback, navigator_set_ignore_keyboard_feedback, void(NavigatorData *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK4(mock_navigator_set_read_quickpanel_cb, navigator_set_read_quickpanel_cb, void(NavigatorData *, read_quickpanel_cb_t, void *, read_quickpanel_cb_t));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_shutdown, navigator_shutdown, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_data_free, reading_composer_data_free, void(ReadingComposerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_data_get, reading_composer_data_get, ReadingComposerData *(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_description_get, reading_composer_description_get, char *(ReadingComposerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_extended_description_get, reading_composer_extended_description_get, char *(ReadingComposerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_reading_composer_name_get, reading_composer_name_get, char *(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_create_service, screen_reader_create_service, int(Service_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_terminate_service, screen_reader_terminate_service, int(Service_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_ui_launch, screen_reader_ui_launch, void(const char *));
+IMPLEMENT_FUNCTION_MOCK0(mock_screen_reader_ui_terminate, screen_reader_ui_terminate, void());
+IMPLEMENT_FUNCTION_MOCK1(mock_sound_n_vibration_feedback_generate, sound_n_vibration_feedback_generate, void(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK5(mock_spi_event_get_text_to_read, spi_event_get_text_to_read, void(SpiData *, char **, char **, AtspiEvent *, int *));
+IMPLEMENT_FUNCTION_MOCK2(mock_spi_event_listener_cb, spi_event_listener_cb, void(AtspiEvent *, void *));
+IMPLEMENT_FUNCTION_MOCK0(mock_spi_init, spi_init, SpiData *());
+IMPLEMENT_FUNCTION_MOCK1(mock_spi_shutdown, spi_shutdown, void(SpiData *));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_init, tw_init, _Bool());
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_pause_get, tw_pause_get, Eina_Bool());
+IMPLEMENT_FUNCTION_MOCK1(mock_tw_pause_set, tw_pause_set, Eina_Bool(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK1(mock_tw_purge, tw_purge, void(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK3(mock_tw_set_utterance_cb, tw_set_utterance_cb, void(utterance_cb_t, void *, utterance_cb_t));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_shutdown, tw_shutdown, void());
+IMPLEMENT_FUNCTION_MOCK2(mock_tw_speak, tw_speak, Read_Command *(char *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK5(mock_tw_speak_customized, tw_speak_customized, Read_Command *(char *, Eina_Bool, Eina_Bool, AtspiAccessible *, unsigned int));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_stop_set, tw_stop_set, void());
+
--- /dev/null
+#pragma once
+
+extern "C" {
+#include <stdio.h>
+#include "logger.h"
+#include "navigator.h"
+#include "reading_composer.h"
+#include "screen_reader_spi.h"
+#include "screen_reader_tts.h"
+}
+#include <cmock/cmock.h>
+
+extern "C" _Bool allow_recursive_name(AtspiAccessible * obj);
+extern "C" SignalHandlingTimerData * create_shtd(SpiData * spi, AtspiAccessible * obj, char * text_to_read, char * desc_to_read);
+extern "C" void free_shtd(SignalHandlingTimerData * shtd);
+extern "C" char * generate_description_for_subtree(AtspiAccessible * obj);
+extern "C" void spi_event_get_text_to_read(SpiData * spi, char ** text_to_read, char ** descr_to_read, AtspiEvent * event, int * cancel);
+extern "C" void spi_event_listener_cb(AtspiEvent * event, void * user_data);
+DECLARE_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_allow_recursive_name, allow_recursive_name, _Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK4(mock_create_shtd, create_shtd, SignalHandlingTimerData *(SpiData *, AtspiAccessible *, char *, char *));
+DECLARE_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+DECLARE_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_free_shtd, free_shtd, void(SignalHandlingTimerData *));
+DECLARE_FUNCTION_MOCK1(mock_generate_description_for_subtree, generate_description_for_subtree, char *(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK3(mock_generate_what_to_read_and_speak, generate_what_to_read_and_speak, void(NavigatorData *, AtspiAccessible *, Eina_Bool));
+DECLARE_FUNCTION_MOCK0(mock_get_pointer_to_service_data_struct, get_pointer_to_service_data_struct, Service_Data *());
+DECLARE_FUNCTION_MOCK1(mock_navigator_focus_next_visible, navigator_focus_next_visible, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_focus_prev_visible, navigator_focus_prev_visible, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_flat_navi_context, navigator_get_flat_navi_context, FlatNaviContext *(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_ignore_keyboard_feedback, navigator_get_ignore_keyboard_feedback, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_is_text_selection_mode, navigator_get_is_text_selection_mode, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK0(mock_navigator_init, navigator_init, NavigatorData *());
+DECLARE_FUNCTION_MOCK2(mock_navigator_set_ignore_keyboard_feedback, navigator_set_ignore_keyboard_feedback, void(NavigatorData *, Eina_Bool));
+DECLARE_FUNCTION_MOCK4(mock_navigator_set_read_quickpanel_cb, navigator_set_read_quickpanel_cb, void(NavigatorData *, read_quickpanel_cb_t, void *, read_quickpanel_cb_t));
+DECLARE_FUNCTION_MOCK1(mock_navigator_shutdown, navigator_shutdown, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_data_free, reading_composer_data_free, void(ReadingComposerData *));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_data_get, reading_composer_data_get, ReadingComposerData *(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_description_get, reading_composer_description_get, char *(ReadingComposerData *));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_extended_description_get, reading_composer_extended_description_get, char *(ReadingComposerData *));
+DECLARE_FUNCTION_MOCK1(mock_reading_composer_name_get, reading_composer_name_get, char *(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_create_service, screen_reader_create_service, int(Service_Data *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_terminate_service, screen_reader_terminate_service, int(Service_Data *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_ui_launch, screen_reader_ui_launch, void(const char *));
+DECLARE_FUNCTION_MOCK0(mock_screen_reader_ui_terminate, screen_reader_ui_terminate, void());
+DECLARE_FUNCTION_MOCK1(mock_sound_n_vibration_feedback_generate, sound_n_vibration_feedback_generate, void(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK5(mock_spi_event_get_text_to_read, spi_event_get_text_to_read, void(SpiData *, char **, char **, AtspiEvent *, int *));
+DECLARE_FUNCTION_MOCK2(mock_spi_event_listener_cb, spi_event_listener_cb, void(AtspiEvent *, void *));
+DECLARE_FUNCTION_MOCK0(mock_spi_init, spi_init, SpiData *());
+DECLARE_FUNCTION_MOCK1(mock_spi_shutdown, spi_shutdown, void(SpiData *));
+DECLARE_FUNCTION_MOCK0(mock_tw_init, tw_init, _Bool());
+DECLARE_FUNCTION_MOCK0(mock_tw_pause_get, tw_pause_get, Eina_Bool());
+DECLARE_FUNCTION_MOCK1(mock_tw_pause_set, tw_pause_set, Eina_Bool(Eina_Bool));
+DECLARE_FUNCTION_MOCK1(mock_tw_purge, tw_purge, void(Eina_Bool));
+DECLARE_FUNCTION_MOCK3(mock_tw_set_utterance_cb, tw_set_utterance_cb, void(utterance_cb_t, void *, utterance_cb_t));
+DECLARE_FUNCTION_MOCK0(mock_tw_shutdown, tw_shutdown, void());
+DECLARE_FUNCTION_MOCK2(mock_tw_speak, tw_speak, Read_Command *(char *, Eina_Bool));
+DECLARE_FUNCTION_MOCK5(mock_tw_speak_customized, tw_speak_customized, Read_Command *(char *, Eina_Bool, Eina_Bool, AtspiAccessible *, unsigned int));
+DECLARE_FUNCTION_MOCK0(mock_tw_stop_set, tw_stop_set, void());
+
--- /dev/null
+#include "mocked_screen_reader_switch.h"
+
+IMPLEMENT_FUNCTION_MOCK1(mock_is_enabled_switch_set, is_enabled_switch_set, Eina_Bool(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_switch_enabled_get, screen_reader_switch_enabled_get, Eina_Bool(Eina_Bool *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_switch_enabled_set, screen_reader_switch_enabled_set, Eina_Bool(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_switch_wm_enabled_set, screen_reader_switch_wm_enabled_set, Eina_Bool(Eina_Bool));
+
--- /dev/null
+#pragma once
+
+extern "C" {
+#include "logger.h"
+#include <eldbus-1/Eldbus.h>
+}
+#include <cmock/cmock.h>
+
+DECLARE_FUNCTION_MOCK1(mock_is_enabled_switch_set, is_enabled_switch_set, Eina_Bool(Eina_Bool));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_switch_enabled_get, screen_reader_switch_enabled_get, Eina_Bool(Eina_Bool *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_switch_enabled_set, screen_reader_switch_enabled_set, Eina_Bool(Eina_Bool));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_switch_wm_enabled_set, screen_reader_switch_wm_enabled_set, Eina_Bool(Eina_Bool));
+
--- /dev/null
+#include "mocked_screen_reader_system.h"
+
+IMPLEMENT_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_device_display_lock_release, device_display_lock_release, void(System_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_device_display_lock_request, device_display_lock_request, void(System_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_device_error_to_string, device_error_to_string, char *(int));
+IMPLEMENT_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+IMPLEMENT_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK3(mock_generate_what_to_read_and_speak, generate_what_to_read_and_speak, void(NavigatorData *, AtspiAccessible *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK0(mock_get_pointer_to_service_data_struct, get_pointer_to_service_data_struct, Service_Data *());
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_focus_next_visible, navigator_focus_next_visible, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_focus_prev_visible, navigator_focus_prev_visible, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_flat_navi_context, navigator_get_flat_navi_context, FlatNaviContext *(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_ignore_keyboard_feedback, navigator_get_ignore_keyboard_feedback, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_is_text_selection_mode, navigator_get_is_text_selection_mode, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK0(mock_navigator_init, navigator_init, NavigatorData *());
+IMPLEMENT_FUNCTION_MOCK2(mock_navigator_set_ignore_keyboard_feedback, navigator_set_ignore_keyboard_feedback, void(NavigatorData *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK4(mock_navigator_set_read_quickpanel_cb, navigator_set_read_quickpanel_cb, void(NavigatorData *, read_quickpanel_cb_t, void *, read_quickpanel_cb_t));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_shutdown, navigator_shutdown, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_create_service, screen_reader_create_service, int(Service_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_terminate_service, screen_reader_terminate_service, int(Service_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_ui_launch, screen_reader_ui_launch, void(const char *));
+IMPLEMENT_FUNCTION_MOCK0(mock_screen_reader_ui_terminate, screen_reader_ui_terminate, void());
+IMPLEMENT_FUNCTION_MOCK1(mock_sound_n_vibration_feedback_generate, sound_n_vibration_feedback_generate, void(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK0(mock_spi_init, spi_init, SpiData *());
+IMPLEMENT_FUNCTION_MOCK1(mock_spi_shutdown, spi_shutdown, void(SpiData *));
+IMPLEMENT_FUNCTION_MOCK0(mock_system_notifications_init, system_notifications_init, System_Data *());
+IMPLEMENT_FUNCTION_MOCK1(mock_system_notifications_shutdown, system_notifications_shutdown, void(System_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_system_status_get, system_status_get, void(void *));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_init, tw_init, _Bool());
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_pause_get, tw_pause_get, Eina_Bool());
+IMPLEMENT_FUNCTION_MOCK1(mock_tw_pause_set, tw_pause_set, Eina_Bool(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK1(mock_tw_purge, tw_purge, void(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK3(mock_tw_set_utterance_cb, tw_set_utterance_cb, void(utterance_cb_t, void *, utterance_cb_t));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_shutdown, tw_shutdown, void());
+IMPLEMENT_FUNCTION_MOCK2(mock_tw_speak, tw_speak, Read_Command *(char *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK5(mock_tw_speak_customized, tw_speak_customized, Read_Command *(char *, Eina_Bool, Eina_Bool, AtspiAccessible *, unsigned int));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_stop_set, tw_stop_set, void());
+
--- /dev/null
+#pragma once
+
+extern "C" {
+#include <device/battery.h>
+#include <device/display.h>
+#include <device/power.h>
+#include <device/callback.h>
+#include <bluetooth.h>
+#include <telephony-client/tapi_common.h>
+#include <telephony-client/TelNetwork.h>
+#include <vconf.h>
+#include <wifi-manager.h>
+#include <notification.h>
+#include <notification_list.h>
+#include "logger.h"
+#include "screen_reader_system.h"
+#include "screen_reader_tts.h"
+}
+#include <cmock/cmock.h>
+
+extern "C" char * device_error_to_string(int e);
+DECLARE_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_device_display_lock_release, device_display_lock_release, void(System_Data *));
+DECLARE_FUNCTION_MOCK1(mock_device_display_lock_request, device_display_lock_request, void(System_Data *));
+DECLARE_FUNCTION_MOCK1(mock_device_error_to_string, device_error_to_string, char *(int));
+DECLARE_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+DECLARE_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK3(mock_generate_what_to_read_and_speak, generate_what_to_read_and_speak, void(NavigatorData *, AtspiAccessible *, Eina_Bool));
+DECLARE_FUNCTION_MOCK0(mock_get_pointer_to_service_data_struct, get_pointer_to_service_data_struct, Service_Data *());
+DECLARE_FUNCTION_MOCK1(mock_navigator_focus_next_visible, navigator_focus_next_visible, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_focus_prev_visible, navigator_focus_prev_visible, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_flat_navi_context, navigator_get_flat_navi_context, FlatNaviContext *(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_ignore_keyboard_feedback, navigator_get_ignore_keyboard_feedback, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_is_text_selection_mode, navigator_get_is_text_selection_mode, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK0(mock_navigator_init, navigator_init, NavigatorData *());
+DECLARE_FUNCTION_MOCK2(mock_navigator_set_ignore_keyboard_feedback, navigator_set_ignore_keyboard_feedback, void(NavigatorData *, Eina_Bool));
+DECLARE_FUNCTION_MOCK4(mock_navigator_set_read_quickpanel_cb, navigator_set_read_quickpanel_cb, void(NavigatorData *, read_quickpanel_cb_t, void *, read_quickpanel_cb_t));
+DECLARE_FUNCTION_MOCK1(mock_navigator_shutdown, navigator_shutdown, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_create_service, screen_reader_create_service, int(Service_Data *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_terminate_service, screen_reader_terminate_service, int(Service_Data *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_ui_launch, screen_reader_ui_launch, void(const char *));
+DECLARE_FUNCTION_MOCK0(mock_screen_reader_ui_terminate, screen_reader_ui_terminate, void());
+DECLARE_FUNCTION_MOCK1(mock_sound_n_vibration_feedback_generate, sound_n_vibration_feedback_generate, void(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK0(mock_spi_init, spi_init, SpiData *());
+DECLARE_FUNCTION_MOCK1(mock_spi_shutdown, spi_shutdown, void(SpiData *));
+DECLARE_FUNCTION_MOCK0(mock_system_notifications_init, system_notifications_init, System_Data *());
+DECLARE_FUNCTION_MOCK1(mock_system_notifications_shutdown, system_notifications_shutdown, void(System_Data *));
+DECLARE_FUNCTION_MOCK1(mock_system_status_get, system_status_get, void(void *));
+DECLARE_FUNCTION_MOCK0(mock_tw_init, tw_init, _Bool());
+DECLARE_FUNCTION_MOCK0(mock_tw_pause_get, tw_pause_get, Eina_Bool());
+DECLARE_FUNCTION_MOCK1(mock_tw_pause_set, tw_pause_set, Eina_Bool(Eina_Bool));
+DECLARE_FUNCTION_MOCK1(mock_tw_purge, tw_purge, void(Eina_Bool));
+DECLARE_FUNCTION_MOCK3(mock_tw_set_utterance_cb, tw_set_utterance_cb, void(utterance_cb_t, void *, utterance_cb_t));
+DECLARE_FUNCTION_MOCK0(mock_tw_shutdown, tw_shutdown, void());
+DECLARE_FUNCTION_MOCK2(mock_tw_speak, tw_speak, Read_Command *(char *, Eina_Bool));
+DECLARE_FUNCTION_MOCK5(mock_tw_speak_customized, tw_speak_customized, Read_Command *(char *, Eina_Bool, Eina_Bool, AtspiAccessible *, unsigned int));
+DECLARE_FUNCTION_MOCK0(mock_tw_stop_set, tw_stop_set, void());
+
--- /dev/null
+#include "mocked_screen_reader_tts.h"
+
+IMPLEMENT_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK2(mock_cycle_detection_check_if_in_cycle, cycle_detection_check_if_in_cycle, Eina_Bool(cycle_detection_data *, const void *));
+IMPLEMENT_FUNCTION_MOCK2(mock_cycle_detection_initialize, cycle_detection_initialize, void(cycle_detection_data *, const void *));
+IMPLEMENT_FUNCTION_MOCK3(mock_dbus_direct_reading_adapter_emit, dbus_direct_reading_adapter_emit, int(Reading_Adapter_Data *, const Signal, const void *));
+IMPLEMENT_FUNCTION_MOCK0(mock_dbus_direct_reading_init, dbus_direct_reading_init, Reading_Adapter_Data *());
+IMPLEMENT_FUNCTION_MOCK1(mock_dbus_direct_reading_shutdown, dbus_direct_reading_shutdown, void(Reading_Adapter_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_device_display_lock_release, device_display_lock_release, void(System_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_device_display_lock_request, device_display_lock_request, void(System_Data *));
+IMPLEMENT_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+IMPLEMENT_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK3(mock_generate_what_to_read_and_speak, generate_what_to_read_and_speak, void(NavigatorData *, AtspiAccessible *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK2(mock_get_accuracy, get_accuracy, int(double, int));
+IMPLEMENT_FUNCTION_MOCK1(mock_get_objects_attributes, get_objects_attributes, unsigned short(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK0(mock_get_pointer_to_service_data_struct, get_pointer_to_service_data_struct, Service_Data *());
+IMPLEMENT_FUNCTION_MOCK1(mock_get_signal_name, get_signal_name, const char *(const Signal));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_focus_next_visible, navigator_focus_next_visible, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_focus_prev_visible, navigator_focus_prev_visible, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_flat_navi_context, navigator_get_flat_navi_context, FlatNaviContext *(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_ignore_keyboard_feedback, navigator_get_ignore_keyboard_feedback, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_is_text_selection_mode, navigator_get_is_text_selection_mode, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK0(mock_navigator_init, navigator_init, NavigatorData *());
+IMPLEMENT_FUNCTION_MOCK2(mock_navigator_set_ignore_keyboard_feedback, navigator_set_ignore_keyboard_feedback, void(NavigatorData *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK4(mock_navigator_set_read_quickpanel_cb, navigator_set_read_quickpanel_cb, void(NavigatorData *, read_quickpanel_cb_t, void *, read_quickpanel_cb_t));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_shutdown, navigator_shutdown, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_defunct_state, object_has_defunct_state, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_highlighted_state, object_has_highlighted_state, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_modal_role, object_has_modal_role, Eina_Bool(AtspiRole));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_create_service, screen_reader_create_service, int(Service_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_terminate_service, screen_reader_terminate_service, int(Service_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_ui_launch, screen_reader_ui_launch, void(const char *));
+IMPLEMENT_FUNCTION_MOCK0(mock_screen_reader_ui_terminate, screen_reader_ui_terminate, void());
+IMPLEMENT_FUNCTION_MOCK1(mock_sound_n_vibration_feedback_generate, sound_n_vibration_feedback_generate, void(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK0(mock_spi_init, spi_init, SpiData *());
+IMPLEMENT_FUNCTION_MOCK1(mock_spi_shutdown, spi_shutdown, void(SpiData *));
+IMPLEMENT_FUNCTION_MOCK0(mock_system_notifications_init, system_notifications_init, System_Data *());
+IMPLEMENT_FUNCTION_MOCK1(mock_system_notifications_shutdown, system_notifications_shutdown, void(System_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_system_status_get, system_status_get, void(void *));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_init, tw_init, _Bool());
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_pause_get, tw_pause_get, Eina_Bool());
+IMPLEMENT_FUNCTION_MOCK1(mock_tw_pause_set, tw_pause_set, Eina_Bool(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK1(mock_tw_purge, tw_purge, void(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK3(mock_tw_set_utterance_cb, tw_set_utterance_cb, void(utterance_cb_t, void *, utterance_cb_t));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_shutdown, tw_shutdown, void());
+IMPLEMENT_FUNCTION_MOCK2(mock_tw_speak, tw_speak, Read_Command *(char *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK5(mock_tw_speak_customized, tw_speak_customized, Read_Command *(char *, Eina_Bool, Eina_Bool, AtspiAccessible *, unsigned int));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_stop_set, tw_stop_set, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_utils_a11y_bus_connection_get, utils_a11y_bus_connection_get, Eldbus_Connection *());
+IMPLEMENT_FUNCTION_MOCK1(mock_utils_a11y_bus_connection_set, utils_a11y_bus_connection_set, void(Eldbus_Connection *));
+IMPLEMENT_FUNCTION_MOCK1(mock_utils_enum_to_string, utils_enum_to_string, const char *(Gesture));
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_exit, vc_exit, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_haptic, vc_get_haptic, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_keyboard_feedback, vc_get_keyboard_feedback, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_lcd_backlight_timeout, vc_get_lcd_backlight_timeout, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_read_description, vc_get_read_description, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_sound_feedback, vc_get_sound_feedback, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_init, vc_init, void());
+
--- /dev/null
+#pragma once
+
+extern "C" {
+#include <ecore-1/Ecore.h>
+#include <atspi/atspi.h>
+#include "dbus_direct_reading_adapter.h"
+#include "logger.h"
+#include "screen_reader_system.h"
+#include "screen_reader_tts.h"
+#include "screen_reader_vconf.h"
+#include "utils.h"
+}
+#include <cmock/cmock.h>
+
+DECLARE_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK2(mock_cycle_detection_check_if_in_cycle, cycle_detection_check_if_in_cycle, Eina_Bool(cycle_detection_data *, const void *));
+DECLARE_FUNCTION_MOCK2(mock_cycle_detection_initialize, cycle_detection_initialize, void(cycle_detection_data *, const void *));
+DECLARE_FUNCTION_MOCK3(mock_dbus_direct_reading_adapter_emit, dbus_direct_reading_adapter_emit, int(Reading_Adapter_Data *, const Signal, const void *));
+DECLARE_FUNCTION_MOCK0(mock_dbus_direct_reading_init, dbus_direct_reading_init, Reading_Adapter_Data *());
+DECLARE_FUNCTION_MOCK1(mock_dbus_direct_reading_shutdown, dbus_direct_reading_shutdown, void(Reading_Adapter_Data *));
+DECLARE_FUNCTION_MOCK1(mock_device_display_lock_release, device_display_lock_release, void(System_Data *));
+DECLARE_FUNCTION_MOCK1(mock_device_display_lock_request, device_display_lock_request, void(System_Data *));
+DECLARE_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+DECLARE_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK3(mock_generate_what_to_read_and_speak, generate_what_to_read_and_speak, void(NavigatorData *, AtspiAccessible *, Eina_Bool));
+DECLARE_FUNCTION_MOCK2(mock_get_accuracy, get_accuracy, int(double, int));
+DECLARE_FUNCTION_MOCK1(mock_get_objects_attributes, get_objects_attributes, unsigned short(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK0(mock_get_pointer_to_service_data_struct, get_pointer_to_service_data_struct, Service_Data *());
+DECLARE_FUNCTION_MOCK1(mock_get_signal_name, get_signal_name, const char *(const Signal));
+DECLARE_FUNCTION_MOCK1(mock_navigator_focus_next_visible, navigator_focus_next_visible, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_focus_prev_visible, navigator_focus_prev_visible, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_flat_navi_context, navigator_get_flat_navi_context, FlatNaviContext *(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_ignore_keyboard_feedback, navigator_get_ignore_keyboard_feedback, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_is_text_selection_mode, navigator_get_is_text_selection_mode, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK0(mock_navigator_init, navigator_init, NavigatorData *());
+DECLARE_FUNCTION_MOCK2(mock_navigator_set_ignore_keyboard_feedback, navigator_set_ignore_keyboard_feedback, void(NavigatorData *, Eina_Bool));
+DECLARE_FUNCTION_MOCK4(mock_navigator_set_read_quickpanel_cb, navigator_set_read_quickpanel_cb, void(NavigatorData *, read_quickpanel_cb_t, void *, read_quickpanel_cb_t));
+DECLARE_FUNCTION_MOCK1(mock_navigator_shutdown, navigator_shutdown, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_defunct_state, object_has_defunct_state, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_highlighted_state, object_has_highlighted_state, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_modal_role, object_has_modal_role, Eina_Bool(AtspiRole));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_create_service, screen_reader_create_service, int(Service_Data *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_terminate_service, screen_reader_terminate_service, int(Service_Data *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_ui_launch, screen_reader_ui_launch, void(const char *));
+DECLARE_FUNCTION_MOCK0(mock_screen_reader_ui_terminate, screen_reader_ui_terminate, void());
+DECLARE_FUNCTION_MOCK1(mock_sound_n_vibration_feedback_generate, sound_n_vibration_feedback_generate, void(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK0(mock_spi_init, spi_init, SpiData *());
+DECLARE_FUNCTION_MOCK1(mock_spi_shutdown, spi_shutdown, void(SpiData *));
+DECLARE_FUNCTION_MOCK0(mock_system_notifications_init, system_notifications_init, System_Data *());
+DECLARE_FUNCTION_MOCK1(mock_system_notifications_shutdown, system_notifications_shutdown, void(System_Data *));
+DECLARE_FUNCTION_MOCK1(mock_system_status_get, system_status_get, void(void *));
+DECLARE_FUNCTION_MOCK0(mock_tw_init, tw_init, _Bool());
+DECLARE_FUNCTION_MOCK0(mock_tw_pause_get, tw_pause_get, Eina_Bool());
+DECLARE_FUNCTION_MOCK1(mock_tw_pause_set, tw_pause_set, Eina_Bool(Eina_Bool));
+DECLARE_FUNCTION_MOCK1(mock_tw_purge, tw_purge, void(Eina_Bool));
+DECLARE_FUNCTION_MOCK3(mock_tw_set_utterance_cb, tw_set_utterance_cb, void(utterance_cb_t, void *, utterance_cb_t));
+DECLARE_FUNCTION_MOCK0(mock_tw_shutdown, tw_shutdown, void());
+DECLARE_FUNCTION_MOCK2(mock_tw_speak, tw_speak, Read_Command *(char *, Eina_Bool));
+DECLARE_FUNCTION_MOCK5(mock_tw_speak_customized, tw_speak_customized, Read_Command *(char *, Eina_Bool, Eina_Bool, AtspiAccessible *, unsigned int));
+DECLARE_FUNCTION_MOCK0(mock_tw_stop_set, tw_stop_set, void());
+DECLARE_FUNCTION_MOCK0(mock_utils_a11y_bus_connection_get, utils_a11y_bus_connection_get, Eldbus_Connection *());
+DECLARE_FUNCTION_MOCK1(mock_utils_a11y_bus_connection_set, utils_a11y_bus_connection_set, void(Eldbus_Connection *));
+DECLARE_FUNCTION_MOCK1(mock_utils_enum_to_string, utils_enum_to_string, const char *(Gesture));
+DECLARE_FUNCTION_MOCK0(mock_vc_exit, vc_exit, void());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_haptic, vc_get_haptic, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_keyboard_feedback, vc_get_keyboard_feedback, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_lcd_backlight_timeout, vc_get_lcd_backlight_timeout, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_read_description, vc_get_read_description, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_sound_feedback, vc_get_sound_feedback, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_init, vc_init, void());
+
--- /dev/null
+#include "mocked_screen_reader_ui.h"
+
--- /dev/null
+#pragma once
+
+extern "C" {
+#include <stdio.h>
+#include <ecore-1/Ecore.h>
+#include <Elementary.h>
+#include "logger.h"
+#include <appcore-efl.h>
+#include <glib-2.0/glib/gprintf.h>
+}
+#include <cmock/cmock.h>
+
--- /dev/null
+#include "mocked_screen_reader_vconf.h"
+
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_exit, vc_exit, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_haptic, vc_get_haptic, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_keyboard_feedback, vc_get_keyboard_feedback, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_lcd_backlight_timeout, vc_get_lcd_backlight_timeout, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_read_description, vc_get_read_description, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_get_sound_feedback, vc_get_sound_feedback, int());
+IMPLEMENT_FUNCTION_MOCK0(mock_vc_init, vc_init, void());
+
--- /dev/null
+#pragma once
+
+extern "C" {
+#include <appcore-efl.h>
+#include <locale.h>
+#include <vconf.h>
+#include "logger.h"
+#include "screen_reader_vconf.h"
+}
+#include <cmock/cmock.h>
+
+DECLARE_FUNCTION_MOCK0(mock_vc_exit, vc_exit, void());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_haptic, vc_get_haptic, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_keyboard_feedback, vc_get_keyboard_feedback, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_lcd_backlight_timeout, vc_get_lcd_backlight_timeout, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_read_description, vc_get_read_description, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_get_sound_feedback, vc_get_sound_feedback, int());
+DECLARE_FUNCTION_MOCK0(mock_vc_init, vc_init, void());
+
--- /dev/null
+#include "mocked_smart_notification.h"
+
+IMPLEMENT_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+IMPLEMENT_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK3(mock_generate_what_to_read_and_speak, generate_what_to_read_and_speak, void(NavigatorData *, AtspiAccessible *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK0(mock_get_pointer_to_service_data_struct, get_pointer_to_service_data_struct, Service_Data *());
+IMPLEMENT_FUNCTION_MOCK3(mock_get_realized_items_count, get_realized_items_count, void(AtspiAccessible *, int *, int *));
+IMPLEMENT_FUNCTION_MOCK0(mock_haptic_module_disconnect, haptic_module_disconnect, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_haptic_module_init, haptic_module_init, void());
+IMPLEMENT_FUNCTION_MOCK2(mock_haptic_vibrate_start, haptic_vibrate_start, void(int, int));
+IMPLEMENT_FUNCTION_MOCK0(mock_haptic_vibrate_stop, haptic_vibrate_stop, void());
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_focus_next_visible, navigator_focus_next_visible, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_focus_prev_visible, navigator_focus_prev_visible, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_flat_navi_context, navigator_get_flat_navi_context, FlatNaviContext *(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_ignore_keyboard_feedback, navigator_get_ignore_keyboard_feedback, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_is_text_selection_mode, navigator_get_is_text_selection_mode, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK0(mock_navigator_init, navigator_init, NavigatorData *());
+IMPLEMENT_FUNCTION_MOCK2(mock_navigator_set_ignore_keyboard_feedback, navigator_set_ignore_keyboard_feedback, void(NavigatorData *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK4(mock_navigator_set_read_quickpanel_cb, navigator_set_read_quickpanel_cb, void(NavigatorData *, read_quickpanel_cb_t, void *, read_quickpanel_cb_t));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_shutdown, navigator_shutdown, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_create_service, screen_reader_create_service, int(Service_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_terminate_service, screen_reader_terminate_service, int(Service_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_ui_launch, screen_reader_ui_launch, void(const char *));
+IMPLEMENT_FUNCTION_MOCK0(mock_screen_reader_ui_terminate, screen_reader_ui_terminate, void());
+IMPLEMENT_FUNCTION_MOCK3(mock_smart_notification, smart_notification, void(Notification_Type, int, int));
+IMPLEMENT_FUNCTION_MOCK0(mock_smart_notification_init, smart_notification_init, void());
+IMPLEMENT_FUNCTION_MOCK0(mock_smart_notification_shutdown, smart_notification_shutdown, void());
+IMPLEMENT_FUNCTION_MOCK1(mock_sound_n_vibration_feedback_generate, sound_n_vibration_feedback_generate, void(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK0(mock_spi_init, spi_init, SpiData *());
+IMPLEMENT_FUNCTION_MOCK1(mock_spi_shutdown, spi_shutdown, void(SpiData *));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_init, tw_init, _Bool());
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_pause_get, tw_pause_get, Eina_Bool());
+IMPLEMENT_FUNCTION_MOCK1(mock_tw_pause_set, tw_pause_set, Eina_Bool(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK1(mock_tw_purge, tw_purge, void(Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK3(mock_tw_set_utterance_cb, tw_set_utterance_cb, void(utterance_cb_t, void *, utterance_cb_t));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_shutdown, tw_shutdown, void());
+IMPLEMENT_FUNCTION_MOCK2(mock_tw_speak, tw_speak, Read_Command *(char *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK5(mock_tw_speak_customized, tw_speak_customized, Read_Command *(char *, Eina_Bool, Eina_Bool, AtspiAccessible *, unsigned int));
+IMPLEMENT_FUNCTION_MOCK0(mock_tw_stop_set, tw_stop_set, void());
+
--- /dev/null
+#pragma once
+
+extern "C" {
+#include <ecore-1/Ecore.h>
+#include <Ecore_Evas.h>
+#include <atspi/atspi.h>
+#include <app_common.h>
+#include "logger.h"
+#include "screen_reader_tts.h"
+#include "screen_reader_haptic.h"
+#include "smart_notification.h"
+#include <mm_sound_private.h>
+}
+#include <cmock/cmock.h>
+
+extern "C" void get_realized_items_count(AtspiAccessible * scrollable_object, int * start_idx, int * end_idx);
+DECLARE_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+DECLARE_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK3(mock_generate_what_to_read_and_speak, generate_what_to_read_and_speak, void(NavigatorData *, AtspiAccessible *, Eina_Bool));
+DECLARE_FUNCTION_MOCK0(mock_get_pointer_to_service_data_struct, get_pointer_to_service_data_struct, Service_Data *());
+DECLARE_FUNCTION_MOCK3(mock_get_realized_items_count, get_realized_items_count, void(AtspiAccessible *, int *, int *));
+DECLARE_FUNCTION_MOCK0(mock_haptic_module_disconnect, haptic_module_disconnect, void());
+DECLARE_FUNCTION_MOCK0(mock_haptic_module_init, haptic_module_init, void());
+DECLARE_FUNCTION_MOCK2(mock_haptic_vibrate_start, haptic_vibrate_start, void(int, int));
+DECLARE_FUNCTION_MOCK0(mock_haptic_vibrate_stop, haptic_vibrate_stop, void());
+DECLARE_FUNCTION_MOCK1(mock_navigator_focus_next_visible, navigator_focus_next_visible, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_focus_prev_visible, navigator_focus_prev_visible, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_flat_navi_context, navigator_get_flat_navi_context, FlatNaviContext *(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_ignore_keyboard_feedback, navigator_get_ignore_keyboard_feedback, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_is_text_selection_mode, navigator_get_is_text_selection_mode, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK0(mock_navigator_init, navigator_init, NavigatorData *());
+DECLARE_FUNCTION_MOCK2(mock_navigator_set_ignore_keyboard_feedback, navigator_set_ignore_keyboard_feedback, void(NavigatorData *, Eina_Bool));
+DECLARE_FUNCTION_MOCK4(mock_navigator_set_read_quickpanel_cb, navigator_set_read_quickpanel_cb, void(NavigatorData *, read_quickpanel_cb_t, void *, read_quickpanel_cb_t));
+DECLARE_FUNCTION_MOCK1(mock_navigator_shutdown, navigator_shutdown, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_create_service, screen_reader_create_service, int(Service_Data *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_terminate_service, screen_reader_terminate_service, int(Service_Data *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_ui_launch, screen_reader_ui_launch, void(const char *));
+DECLARE_FUNCTION_MOCK0(mock_screen_reader_ui_terminate, screen_reader_ui_terminate, void());
+DECLARE_FUNCTION_MOCK3(mock_smart_notification, smart_notification, void(Notification_Type, int, int));
+DECLARE_FUNCTION_MOCK0(mock_smart_notification_init, smart_notification_init, void());
+DECLARE_FUNCTION_MOCK0(mock_smart_notification_shutdown, smart_notification_shutdown, void());
+DECLARE_FUNCTION_MOCK1(mock_sound_n_vibration_feedback_generate, sound_n_vibration_feedback_generate, void(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK0(mock_spi_init, spi_init, SpiData *());
+DECLARE_FUNCTION_MOCK1(mock_spi_shutdown, spi_shutdown, void(SpiData *));
+DECLARE_FUNCTION_MOCK0(mock_tw_init, tw_init, _Bool());
+DECLARE_FUNCTION_MOCK0(mock_tw_pause_get, tw_pause_get, Eina_Bool());
+DECLARE_FUNCTION_MOCK1(mock_tw_pause_set, tw_pause_set, Eina_Bool(Eina_Bool));
+DECLARE_FUNCTION_MOCK1(mock_tw_purge, tw_purge, void(Eina_Bool));
+DECLARE_FUNCTION_MOCK3(mock_tw_set_utterance_cb, tw_set_utterance_cb, void(utterance_cb_t, void *, utterance_cb_t));
+DECLARE_FUNCTION_MOCK0(mock_tw_shutdown, tw_shutdown, void());
+DECLARE_FUNCTION_MOCK2(mock_tw_speak, tw_speak, Read_Command *(char *, Eina_Bool));
+DECLARE_FUNCTION_MOCK5(mock_tw_speak_customized, tw_speak_customized, Read_Command *(char *, Eina_Bool, Eina_Bool, AtspiAccessible *, unsigned int));
+DECLARE_FUNCTION_MOCK0(mock_tw_stop_set, tw_stop_set, void());
+
--- /dev/null
+#include "mocked_symbols.h"
+
+IMPLEMENT_FUNCTION_MOCK1(mock_symbol_lookup, symbol_lookup, const gchar *(const gchar *));
+
--- /dev/null
+#pragma once
+
+extern "C" {
+#include <glib-2.0/glib.h>
+#include "logger.h"
+}
+#include <cmock/cmock.h>
+
+DECLARE_FUNCTION_MOCK1(mock_symbol_lookup, symbol_lookup, const gchar *(const gchar *));
+
--- /dev/null
+#include "mocked_utils.h"
+
+IMPLEMENT_FUNCTION_MOCK2(mock_cycle_detection_check_if_in_cycle, cycle_detection_check_if_in_cycle, Eina_Bool(cycle_detection_data *, const void *));
+IMPLEMENT_FUNCTION_MOCK2(mock_cycle_detection_initialize, cycle_detection_initialize, void(cycle_detection_data *, const void *));
+IMPLEMENT_FUNCTION_MOCK2(mock_get_accuracy, get_accuracy, int(double, int));
+IMPLEMENT_FUNCTION_MOCK1(mock_get_objects_attributes, get_objects_attributes, unsigned short(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_defunct_state, object_has_defunct_state, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_highlighted_state, object_has_highlighted_state, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_modal_role, object_has_modal_role, Eina_Bool(AtspiRole));
+IMPLEMENT_FUNCTION_MOCK0(mock_utils_a11y_bus_connection_get, utils_a11y_bus_connection_get, Eldbus_Connection *());
+IMPLEMENT_FUNCTION_MOCK1(mock_utils_a11y_bus_connection_set, utils_a11y_bus_connection_set, void(Eldbus_Connection *));
+IMPLEMENT_FUNCTION_MOCK1(mock_utils_enum_to_string, utils_enum_to_string, const char *(Gesture));
+
--- /dev/null
+#pragma once
+
+extern "C" {
+#include <atspi/atspi.h>
+#include "logger.h"
+#include "utils.h"
+}
+#include <cmock/cmock.h>
+
+DECLARE_FUNCTION_MOCK2(mock_cycle_detection_check_if_in_cycle, cycle_detection_check_if_in_cycle, Eina_Bool(cycle_detection_data *, const void *));
+DECLARE_FUNCTION_MOCK2(mock_cycle_detection_initialize, cycle_detection_initialize, void(cycle_detection_data *, const void *));
+DECLARE_FUNCTION_MOCK2(mock_get_accuracy, get_accuracy, int(double, int));
+DECLARE_FUNCTION_MOCK1(mock_get_objects_attributes, get_objects_attributes, unsigned short(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_defunct_state, object_has_defunct_state, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_highlighted_state, object_has_highlighted_state, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_modal_role, object_has_modal_role, Eina_Bool(AtspiRole));
+DECLARE_FUNCTION_MOCK0(mock_utils_a11y_bus_connection_get, utils_a11y_bus_connection_get, Eldbus_Connection *());
+DECLARE_FUNCTION_MOCK1(mock_utils_a11y_bus_connection_set, utils_a11y_bus_connection_set, void(Eldbus_Connection *));
+DECLARE_FUNCTION_MOCK1(mock_utils_enum_to_string, utils_enum_to_string, const char *(Gesture));
+
--- /dev/null
+#include "mocked_window_tracker.h"
+
+IMPLEMENT_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK2(mock_cycle_detection_check_if_in_cycle, cycle_detection_check_if_in_cycle, Eina_Bool(cycle_detection_data *, const void *));
+IMPLEMENT_FUNCTION_MOCK2(mock_cycle_detection_initialize, cycle_detection_initialize, void(cycle_detection_data *, const void *));
+IMPLEMENT_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+IMPLEMENT_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+IMPLEMENT_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK3(mock_generate_what_to_read_and_speak, generate_what_to_read_and_speak, void(NavigatorData *, AtspiAccessible *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK2(mock_get_accuracy, get_accuracy, int(double, int));
+IMPLEMENT_FUNCTION_MOCK1(mock_get_objects_attributes, get_objects_attributes, unsigned short(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK0(mock_get_pointer_to_service_data_struct, get_pointer_to_service_data_struct, Service_Data *());
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_focus_next_visible, navigator_focus_next_visible, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_focus_prev_visible, navigator_focus_prev_visible, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_flat_navi_context, navigator_get_flat_navi_context, FlatNaviContext *(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_ignore_keyboard_feedback, navigator_get_ignore_keyboard_feedback, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_get_is_text_selection_mode, navigator_get_is_text_selection_mode, Eina_Bool(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK0(mock_navigator_init, navigator_init, NavigatorData *());
+IMPLEMENT_FUNCTION_MOCK2(mock_navigator_set_ignore_keyboard_feedback, navigator_set_ignore_keyboard_feedback, void(NavigatorData *, Eina_Bool));
+IMPLEMENT_FUNCTION_MOCK4(mock_navigator_set_read_quickpanel_cb, navigator_set_read_quickpanel_cb, void(NavigatorData *, read_quickpanel_cb_t, void *, read_quickpanel_cb_t));
+IMPLEMENT_FUNCTION_MOCK1(mock_navigator_shutdown, navigator_shutdown, void(NavigatorData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_defunct_state, object_has_defunct_state, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_highlighted_state, object_has_highlighted_state, Eina_Bool(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK1(mock_object_has_modal_role, object_has_modal_role, Eina_Bool(AtspiRole));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_create_service, screen_reader_create_service, int(Service_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_terminate_service, screen_reader_terminate_service, int(Service_Data *));
+IMPLEMENT_FUNCTION_MOCK1(mock_screen_reader_ui_launch, screen_reader_ui_launch, void(const char *));
+IMPLEMENT_FUNCTION_MOCK0(mock_screen_reader_ui_terminate, screen_reader_ui_terminate, void());
+IMPLEMENT_FUNCTION_MOCK1(mock_sound_n_vibration_feedback_generate, sound_n_vibration_feedback_generate, void(AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK0(mock_spi_init, spi_init, SpiData *());
+IMPLEMENT_FUNCTION_MOCK1(mock_spi_shutdown, spi_shutdown, void(SpiData *));
+IMPLEMENT_FUNCTION_MOCK0(mock_utils_a11y_bus_connection_get, utils_a11y_bus_connection_get, Eldbus_Connection *());
+IMPLEMENT_FUNCTION_MOCK1(mock_utils_a11y_bus_connection_set, utils_a11y_bus_connection_set, void(Eldbus_Connection *));
+IMPLEMENT_FUNCTION_MOCK1(mock_utils_enum_to_string, utils_enum_to_string, const char *(Gesture));
+IMPLEMENT_FUNCTION_MOCK1(mock_window_tracker_active_window_request, window_tracker_active_window_request, void(WindowTrackerData *));
+IMPLEMENT_FUNCTION_MOCK3(mock_window_tracker_at_point_window_get, window_tracker_at_point_window_get, AtspiAccessible *(WindowTrackerData *, int, int));
+IMPLEMENT_FUNCTION_MOCK0(mock_window_tracker_init, window_tracker_init, WindowTrackerData *());
+IMPLEMENT_FUNCTION_MOCK1(mock_window_tracker_keyboard_window_append, window_tracker_keyboard_window_append, void(WindowTrackerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_window_tracker_keyboard_window_remove, window_tracker_keyboard_window_remove, void(WindowTrackerData *));
+IMPLEMENT_FUNCTION_MOCK3(mock_window_tracker_register, window_tracker_register, void(WindowTrackerData *, WindowTrackerCb, void *));
+IMPLEMENT_FUNCTION_MOCK1(mock_window_tracker_shutdown, window_tracker_shutdown, void(WindowTrackerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_window_tracker_subroot_get, window_tracker_subroot_get, AtspiAccessible *(WindowTrackerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_window_tracker_top_win_get, window_tracker_top_win_get, AtspiAccessible *(WindowTrackerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_window_tracker_top_window_get, window_tracker_top_window_get, AtspiAccessible *(WindowTrackerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_window_tracker_top_window_info_get, window_tracker_top_window_info_get, WindowInfo *(WindowTrackerData *));
+IMPLEMENT_FUNCTION_MOCK1(mock_window_tracker_unregister, window_tracker_unregister, void *(WindowTrackerData *));
+IMPLEMENT_FUNCTION_MOCK2(mock_window_tracker_window_activate_info_type_get, window_tracker_window_activate_info_type_get, WindowActivateInfoType(WindowTrackerData *, AtspiAccessible *));
+IMPLEMENT_FUNCTION_MOCK3(mock_window_tracker_window_append, window_tracker_window_append, void(WindowTrackerData *, AtspiAccessible *, AtspiRole));
+IMPLEMENT_FUNCTION_MOCK2(mock_window_tracker_window_remove, window_tracker_window_remove, void(WindowTrackerData *, AtspiAccessible *));
+
--- /dev/null
+#pragma once
+
+extern "C" {
+#include <string.h>
+#include "logger.h"
+#include "screen_reader.h"
+#include "utils.h"
+#include "window_tracker.h"
+}
+#include <cmock/cmock.h>
+
+DECLARE_FUNCTION_MOCK1(mock__has_activate_action, _has_activate_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock__has_escape_action, _has_escape_action, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK2(mock_cycle_detection_check_if_in_cycle, cycle_detection_check_if_in_cycle, Eina_Bool(cycle_detection_data *, const void *));
+DECLARE_FUNCTION_MOCK2(mock_cycle_detection_initialize, cycle_detection_initialize, void(cycle_detection_data *, const void *));
+DECLARE_FUNCTION_MOCK0(mock_flat_navi_context_create, flat_navi_context_create, FlatNaviContext *());
+DECLARE_FUNCTION_MOCK4(mock_flat_navi_context_current_at_x_y_set, flat_navi_context_current_at_x_y_set, Eina_Bool(FlatNaviContext *, gint, gint, AtspiAccessible **));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_current_get, flat_navi_context_current_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_current_set, flat_navi_context_current_set, Eina_Bool(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first, flat_navi_context_first, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_first_get, flat_navi_context_first_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_free, flat_navi_context_free, void(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last, flat_navi_context_last, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_last_get, flat_navi_context_last_get, const AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_next, flat_navi_context_next, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_prev, flat_navi_context_prev, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_root_change, flat_navi_context_root_change, void(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_flat_navi_context_root_get, flat_navi_context_root_get, AtspiAccessible *(FlatNaviContext *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_context_setup, flat_navi_context_setup, int(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_get_object_in_relation, flat_navi_get_object_in_relation, AtspiAccessible *(AtspiAccessible *, AtspiRelationType));
+DECLARE_FUNCTION_MOCK2(mock_flat_navi_is_valid, flat_navi_is_valid, FlatNaviContextValidity(FlatNaviContext *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK3(mock_generate_what_to_read_and_speak, generate_what_to_read_and_speak, void(NavigatorData *, AtspiAccessible *, Eina_Bool));
+DECLARE_FUNCTION_MOCK2(mock_get_accuracy, get_accuracy, int(double, int));
+DECLARE_FUNCTION_MOCK1(mock_get_objects_attributes, get_objects_attributes, unsigned short(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK0(mock_get_pointer_to_service_data_struct, get_pointer_to_service_data_struct, Service_Data *());
+DECLARE_FUNCTION_MOCK1(mock_navigator_focus_next_visible, navigator_focus_next_visible, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_focus_prev_visible, navigator_focus_prev_visible, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_flat_navi_context, navigator_get_flat_navi_context, FlatNaviContext *(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_ignore_keyboard_feedback, navigator_get_ignore_keyboard_feedback, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_navigator_get_is_text_selection_mode, navigator_get_is_text_selection_mode, Eina_Bool(NavigatorData *));
+DECLARE_FUNCTION_MOCK0(mock_navigator_init, navigator_init, NavigatorData *());
+DECLARE_FUNCTION_MOCK2(mock_navigator_set_ignore_keyboard_feedback, navigator_set_ignore_keyboard_feedback, void(NavigatorData *, Eina_Bool));
+DECLARE_FUNCTION_MOCK4(mock_navigator_set_read_quickpanel_cb, navigator_set_read_quickpanel_cb, void(NavigatorData *, read_quickpanel_cb_t, void *, read_quickpanel_cb_t));
+DECLARE_FUNCTION_MOCK1(mock_navigator_shutdown, navigator_shutdown, void(NavigatorData *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_defunct_state, object_has_defunct_state, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_highlighted_state, object_has_highlighted_state, Eina_Bool(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK1(mock_object_has_modal_role, object_has_modal_role, Eina_Bool(AtspiRole));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_create_service, screen_reader_create_service, int(Service_Data *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_terminate_service, screen_reader_terminate_service, int(Service_Data *));
+DECLARE_FUNCTION_MOCK1(mock_screen_reader_ui_launch, screen_reader_ui_launch, void(const char *));
+DECLARE_FUNCTION_MOCK0(mock_screen_reader_ui_terminate, screen_reader_ui_terminate, void());
+DECLARE_FUNCTION_MOCK1(mock_sound_n_vibration_feedback_generate, sound_n_vibration_feedback_generate, void(AtspiAccessible *));
+DECLARE_FUNCTION_MOCK0(mock_spi_init, spi_init, SpiData *());
+DECLARE_FUNCTION_MOCK1(mock_spi_shutdown, spi_shutdown, void(SpiData *));
+DECLARE_FUNCTION_MOCK0(mock_utils_a11y_bus_connection_get, utils_a11y_bus_connection_get, Eldbus_Connection *());
+DECLARE_FUNCTION_MOCK1(mock_utils_a11y_bus_connection_set, utils_a11y_bus_connection_set, void(Eldbus_Connection *));
+DECLARE_FUNCTION_MOCK1(mock_utils_enum_to_string, utils_enum_to_string, const char *(Gesture));
+DECLARE_FUNCTION_MOCK1(mock_window_tracker_active_window_request, window_tracker_active_window_request, void(WindowTrackerData *));
+DECLARE_FUNCTION_MOCK3(mock_window_tracker_at_point_window_get, window_tracker_at_point_window_get, AtspiAccessible *(WindowTrackerData *, int, int));
+DECLARE_FUNCTION_MOCK0(mock_window_tracker_init, window_tracker_init, WindowTrackerData *());
+DECLARE_FUNCTION_MOCK1(mock_window_tracker_keyboard_window_append, window_tracker_keyboard_window_append, void(WindowTrackerData *));
+DECLARE_FUNCTION_MOCK1(mock_window_tracker_keyboard_window_remove, window_tracker_keyboard_window_remove, void(WindowTrackerData *));
+DECLARE_FUNCTION_MOCK3(mock_window_tracker_register, window_tracker_register, void(WindowTrackerData *, WindowTrackerCb, void *));
+DECLARE_FUNCTION_MOCK1(mock_window_tracker_shutdown, window_tracker_shutdown, void(WindowTrackerData *));
+DECLARE_FUNCTION_MOCK1(mock_window_tracker_subroot_get, window_tracker_subroot_get, AtspiAccessible *(WindowTrackerData *));
+DECLARE_FUNCTION_MOCK1(mock_window_tracker_top_win_get, window_tracker_top_win_get, AtspiAccessible *(WindowTrackerData *));
+DECLARE_FUNCTION_MOCK1(mock_window_tracker_top_window_get, window_tracker_top_window_get, AtspiAccessible *(WindowTrackerData *));
+DECLARE_FUNCTION_MOCK1(mock_window_tracker_top_window_info_get, window_tracker_top_window_info_get, WindowInfo *(WindowTrackerData *));
+DECLARE_FUNCTION_MOCK1(mock_window_tracker_unregister, window_tracker_unregister, void *(WindowTrackerData *));
+DECLARE_FUNCTION_MOCK2(mock_window_tracker_window_activate_info_type_get, window_tracker_window_activate_info_type_get, WindowActivateInfoType(WindowTrackerData *, AtspiAccessible *));
+DECLARE_FUNCTION_MOCK3(mock_window_tracker_window_append, window_tracker_window_append, void(WindowTrackerData *, AtspiAccessible *, AtspiRole));
+DECLARE_FUNCTION_MOCK2(mock_window_tracker_window_remove, window_tracker_window_remove, void(WindowTrackerData *, AtspiAccessible *));
+