--- /dev/null
+#include <tet_api.h>\r
+#include <Elementary.h>\r
+\r
+// Definitions\r
+// For checking the result of the positive test case.\r
+#define TET_CHECK_PASS(x1, y...) \\r
+{ \\r
+ Evas_Object *err = y; \\r
+ if (err == (x1)) \\r
+ { \\r
+ tet_printf("[TET_CHECK_PASS]:: %s[%d] : Test has failed..", __FILE__,__LINE__); \\r
+ tet_result(TET_FAIL); \\r
+ return; \\r
+ } \\r
+}\r
+\r
+// For checking the result of the negative test case.\r
+#define TET_CHECK_FAIL(x1, y...) \\r
+{ \\r
+ Evas_Object *err = y; \\r
+ if (err != (x1)) \\r
+ { \\r
+ tet_printf("[TET_CHECK_FAIL]:: %s[%d] : Test has failed..", __FILE__,__LINE__); \\r
+ tet_result(TET_FAIL); \\r
+ return; \\r
+ } \\r
+}\r
+\r
+\r
+Evas_Object *main_win;\r
+\r
+static void startup(void);\r
+static void cleanup(void);\r
+\r
+void (*tet_startup)(void) = startup;\r
+void (*tet_cleanup)(void) = cleanup;\r
+\r
+static void utc_UIFW_elm_smart_scroller_bounce_allow_get_func_01(void);\r
+static void utc_UIFW_elm_smart_scroller_bounce_allow_get_func_02(void);\r
+\r
+enum {\r
+ POSITIVE_TC_IDX = 0x01,\r
+ NEGATIVE_TC_IDX,\r
+};\r
+\r
+struct tet_testlist tet_testlist[] = {\r
+ { utc_UIFW_elm_smart_scroller_bounce_allow_get_func_01, POSITIVE_TC_IDX },\r
+ { utc_UIFW_elm_smart_scroller_bounce_allow_get_func_02, NEGATIVE_TC_IDX },\r
+ { NULL, 0 }\r
+};\r
+\r
+static void startup(void)\r
+{\r
+ tet_infoline("[[ TET_MSG ]]:: ============ Startup ============ ");\r
+ elm_init(0, NULL);\r
+ main_win = elm_win_add(NULL, "main", ELM_WIN_BASIC);\r
+ evas_object_show(main_win); \r
+}\r
+\r
+static void cleanup(void)\r
+{\r
+ if ( NULL != main_win ) {\r
+ evas_object_del(main_win);\r
+ main_win = NULL;\r
+ }\r
+ elm_shutdown();\r
+ tet_infoline("[[ TET_MSG ]]:: ============ Cleanup ============ ");\r
+}\r
+\r
+/**\r
+ * @brief Positive test case of elm_smart_scroller_bounce_allow_get()\r
+ */\r
+static void utc_UIFW_elm_smart_scroller_bounce_allow_get_func_01(void)\r
+{\r
+ Evas_Object *scroll = NULL;\r
+ Evas_Object *entry = NULL; \r
+ Eina_Bool x ,y;\r
+ Evas *e;\r
+ e = evas_object_evas_get(main_win);\r
+ scroll= elm_smart_scroller_add(e);\r
+ entry = elm_entry_add(main_win);\r
+ evas_object_show(scroll); \r
+ evas_object_show(entry);\r
+ evas_object_resize(scroll,240,400);\r
+ evas_object_resize(entry,240,400);\r
+ elm_smart_scroller_child_set( scroll,entry);\r
+ elm_entry_entry_set(entry, "This is a multi-line entry "); \r
+ elm_smart_scroller_bounce_allow_get(scroll ,&x,&y);\r
+ if ((x==1) &&(y==1)){ \r
+ tet_result(TET_PASS);\r
+ return;\r
+ }\r
+ tet_infoline("elm_smart_scroller_bounce_allow_get() failed in positive test case");\r
+ tet_result(TET_FAIL);\r
+}\r
+\r
+/**\r
+ * @brief Negative test case of ug_init elm_smart_scroller_bounce_allow_get()\r
+ */\r
+static void utc_UIFW_elm_smart_scroller_bounce_allow_get_func_02(void)\r
+{\r
+ Evas_Object *scroll = NULL;\r
+ Evas_Object *entry = NULL; \r
+ Eina_Bool x ,y;\r
+ Evas *e;\r
+ e = evas_object_evas_get(main_win);\r
+ scroll= elm_smart_scroller_add(e);\r
+ entry = elm_entry_add(main_win);\r
+ evas_object_show(scroll); \r
+ evas_object_show(entry);\r
+ evas_object_resize(scroll,240,400);\r
+ evas_object_resize(entry,240,400);\r
+ elm_smart_scroller_child_set( scroll,entry);\r
+ elm_entry_entry_set(entry, "This is a multi-line entry "); \r
+ elm_smart_scroller_bounce_allow_get(NULL, &x,&y);\r
+ if ((x==1) &&(y==1)){\r
+ tet_infoline("elm_smart_scroller_bounce_allow_get() failed in negative test case with the argument as NULL");\r
+ tet_result(TET_FAIL); \r
+ return;\r
+ }\r
+ tet_result(TET_PASS);\r
+}\r