[ITC][efl-extension][ACR-1522, ACR-1540][Added New TCs for rotary and popup APIs] 18/233918/1
authorABHISHEK JAIN <j.abhishek@samsung.com>
Fri, 24 Apr 2020 13:09:09 +0000 (18:39 +0530)
committerABHISHEK JAIN <j.abhishek@samsung.com>
Wed, 20 May 2020 08:19:13 +0000 (08:19 +0000)
Change-Id: Ic43b5cf39c7498c1b77a0b700c2e6d14957559d3
Signed-off-by: ABHISHEK JAIN <j.abhishek@samsung.com>
(cherry picked from commit c65d967825fc4325d7042283760d9772973b202b)

src/itc/efl-extension/ITs-efl-extension.c
src/itc/efl-extension/tct-efl-extension-native_wearable.h

index 76f5cb718de144e168bd5fee35b9ca36b3f3ec8f..23e56367ef02f11c0a6ab4c87eabb9733f0a42df 100755 (executable)
@@ -3072,6 +3072,83 @@ int ITc_eext_rotary_selector_item_delete_enabled_set_get_p(void)
        DeleteCircleSelector();
        return 0;
 }
+
+/**
+* @testcase            ITc_eext_rotary_event_activated_object_get_p
+* @since_tizen         5.5
+* @author              SRID(j.abhishek)
+* @reviewer            SRID(shobhit.v)
+* @type                auto
+* @description         Get the activated object which can receive the current rotary event
+* @scenario            get return object, should be non NULL
+* @apicovered          eext_rotary_event_activated_object_get
+* @passcase            When eext_rotary_event_activated_object_get is successful.
+* @failcase            If target API fails or any precondition API fails
+* @precondition        None
+* @postcondition       None
+*/
+//& purpose: Get the activated object which can receive the current rotary event
+//& type: auto
+int ITc_eext_rotary_event_activated_object_get_p(void)
+{
+        START_TEST;
+
+        Evas_Object *h_win = NULL;
+        Eext_Circle_Surface *surface = NULL;
+        Evas_Object *pCircle = NULL;
+        Evas_Object *pszActiveObj = NULL;
+        char *pszName = "window";
+
+        h_win = CreateWin(pszName);
+        CHECK_HANDLE(h_win,"CreateWin");
+
+        pCircle = eext_circle_object_slider_add(h_win, surface);
+        CHECK_HANDLE_CLEANUP(pCircle, "eext_circle_object_slider_add", evas_object_del(h_win));
+
+        eext_rotary_object_event_activated_set(pCircle, EINA_TRUE);
+        pszActiveObj = eext_rotary_event_activated_object_get();
+
+        PRINT_RESULT_CLEANUP(pszActiveObj, pCircle, "eext_rotary_event_activated_object_get", "values are not correct", evas_object_del(pCircle); evas_object_del(h_win));
+        evas_object_del(pCircle);
+        evas_object_del(h_win);
+
+        return 0;
+}
+
+/**
+* @testcase            ITc_eext_popup_add_p
+* @since_tizen         5.5
+* @author              SRID(j.abhishek)
+* @reviewer            SRID(shobhit.v)
+* @type                auto
+* @description         Eext Popup has a circle scroller and the content of Eext Popup
+*                      is controlled by rotary event.
+* @scenario            Creating window and add popup.
+* @apicovered          eext_popup_add
+* @passcase            eext_popup_add API created popup is not NULL
+* @failcase            eext_popup_add API returned NULL or any precondition API fails
+* @precondition        None
+* @postcondition       None
+*/
+//& purpose: Eext Popup has a circle scroller and the content of Eext Popup is controlled by rotary event
+//& type: auto
+int ITc_eext_popup_add_p(void)
+{
+       START_TEST;
+       Evas_Object *hWindow = NULL;
+       Evas_Object *hPopup = NULL;
+
+       hWindow = CreateWin("window");
+       CHECK_HANDLE(hWindow, "CreateWin");
+
+       // Target API
+       hPopup =  eext_popup_add(hWindow);
+       CHECK_HANDLE_CLEANUP(hPopup, "eext_popup_add", evas_object_del(hWindow));
+
+       evas_object_del(hWindow);
+
+       return 0;
+}
 #endif  //WEARABLE     //End WEARABLE
 
 /** @} */
index c07840809c219a7d2c9446b139216b9c37572848..c316a3cf38b14b5121aa9b5d44378ce9511ad288 100755 (executable)
@@ -90,7 +90,8 @@ extern int ITc_eext_rotary_selector_add_item_enabled_set_get_p(void);
 extern int ITc_eext_rotary_selector_item_delete_enabled_set_get_p(void);
 extern int ITc_eext_panel_part_content_get_set(void);
 extern int ITc_eext_panel_add(void);
-
+extern int ITc_eext_rotary_event_activated_object_get_p(void);
+extern int ITc_eext_popup_add_p(void);
 
 testcase tc_array[] = {
        {"ITc_eext_circle_object_scroller_add_p",ITc_eext_circle_object_scroller_add_p,ITs_efl_ext_startup,ITs_efl_ext_cleanup},
@@ -161,6 +162,8 @@ testcase tc_array[] = {
        {"ITc_eext_rotary_selector_item_delete_enabled_set_get_p",ITc_eext_rotary_selector_item_delete_enabled_set_get_p,ITs_efl_ext_startup,ITs_efl_ext_cleanup},
        {"ITc_eext_panel_add",ITc_eext_panel_add,ITs_efl_ext_startup,ITs_efl_ext_cleanup},
        {"ITc_eext_panel_part_content_get_set",ITc_eext_panel_part_content_get_set,ITs_efl_ext_startup,ITs_efl_ext_cleanup},
+       {"ITc_eext_rotary_event_activated_object_get_p", ITc_eext_rotary_event_activated_object_get_p, ITs_efl_ext_startup, ITs_efl_ext_cleanup},
+       {"ITc_eext_popup_add_p", ITc_eext_popup_add_p, ITs_efl_ext_startup, ITs_efl_ext_cleanup},
        {NULL, NULL}
 };