From: mansankar Date: Fri, 24 May 2019 12:17:37 +0000 (+0530) Subject: [ITC][capi-network-stc][ACR-1392][Deprecated CAPI to get total statistics info] X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=96fd9f3b274db93414468dd795d6224ff2c85e1c;p=test%2Ftct%2Fnative%2Fapi.git [ITC][capi-network-stc][ACR-1392][Deprecated CAPI to get total statistics info] Change-Id: Id5d94503c88243af2cfa01c996991b11aa9b1647 Signed-off-by: mansankar --- diff --git a/src/itc/stc/ITs-stc.c b/src/itc/stc/ITs-stc.c index 22bac6b51..ee8457861 100755 --- a/src/itc/stc/ITs-stc.c +++ b/src/itc/stc/ITs-stc.c @@ -38,22 +38,6 @@ stc_callback_ret_e StcForeachStatsCallback(stc_error_e result, stc_stats_info_h return STC_CALLBACK_CANCEL; } -/** -* @function StcGetTotalStatsCallback -* @description callback for stc_get_total_stats -* @parameter stc_error_e -* @parameter stc_stats_info_h -* @parameter void* -* @return stc_callback_ret_e -*/ -stc_callback_ret_e StcGetTotalStatsCallback(stc_error_e result, stc_stats_info_h info, void *user_data) -{ - g_bCallbackCalled = true; - FPRINTF("[Line : %d][%s] Callback invoked\\n", __LINE__, API_NAMESPACE); - QUIT_GMAIN_LOOP; - return STC_CALLBACK_CANCEL; -} - /** * @function StcGetStatsCallback * @description callback for stc_get_stats @@ -911,50 +895,6 @@ int ITs_stc_foreach_stats_p(void) return 0; } -//& purpose Gets the total statistics information by interface type asynchronously -//& type: auto -/** -* @testcase ITs_stc_foreach_stats_p -* @since_tizen 4.0 -* @author SRID(manmohan.k) -* @reviewer SRID(shobhit.v) -* @type auto -* @description Gets the total statistics information by interface type asynchronously -* @scenario Sets callback for statistics info API \n -* @scenario Check for callback invocation \n -* @apicovered stc_get_total_stats -* @passcase If callback gets called successfully -* @failcase If fails to called callback -* @precondition NA -* @postcondition NA -*/ -int ITs_stc_get_total_stats_p(void) -{ - START_TEST; - - time_t from, to; - from = StcMakeTime(2000, 1, 1, 1, 1); - time(&to); - - int nRet = stc_stats_rule_set_time_interval(g_hRule, from, to); - PRINT_RESULT(STC_ERROR_NONE, nRet, "stc_stats_rule_set_time_interval", StcGetError(nRet)); - - g_bCallbackCalled = false; - - nRet = stc_get_total_stats(g_hSTC, g_hRule, StcGetTotalStatsCallback, NULL); - PRINT_RESULT(STC_ERROR_NONE, nRet, "stc_get_total_stats", StcGetError(nRet)); - - RUN_GMAIN_LOOP; - - if(g_bCallbackCalled == false) - { - FPRINTF("[Line : %d][%s] Callback not invoked for %s\\n", __LINE__, API_NAMESPACE, "stc_get_total_stats"); - return 1; - } - - return 0; -} - //& purpose Gets the statistics information an application matched rule asynchronously //& type: auto /** diff --git a/src/itc/stc/tct-stc-native_mobile.h b/src/itc/stc/tct-stc-native_mobile.h index c954d7896..0fd7543a4 100755 --- a/src/itc/stc/tct-stc-native_mobile.h +++ b/src/itc/stc/tct-stc-native_mobile.h @@ -29,7 +29,6 @@ extern int ITs_stc_stats_rule_set_get_time_interval_p(void); extern int ITs_stc_stats_rule_set_get_iface_type_p(void); extern int ITs_stc_stats_rule_set_get_time_period_p(void); extern int ITs_stc_foreach_stats_p(void); -extern int ITs_stc_get_total_stats_p(void); extern int ITs_stc_get_stats_p(void); extern int ITs_stc_stats_info_get_app_id_p(void); extern int ITs_stc_stats_info_get_iface_name_p(void); @@ -49,7 +48,6 @@ testcase tc_array[] = { {"ITs_stc_stats_rule_set_get_iface_type_p",ITs_stc_stats_rule_set_get_iface_type_p,ITs_stc_startup,ITs_stc_cleanup}, {"ITs_stc_stats_rule_set_get_time_period_p",ITs_stc_stats_rule_set_get_time_period_p,ITs_stc_startup,ITs_stc_cleanup}, {"ITs_stc_foreach_stats_p",ITs_stc_foreach_stats_p,ITs_stc_startup,ITs_stc_cleanup}, - {"ITs_stc_get_total_stats_p",ITs_stc_get_total_stats_p,ITs_stc_startup,ITs_stc_cleanup}, {"ITs_stc_get_stats_p",ITs_stc_get_stats_p,ITs_stc_startup,ITs_stc_cleanup}, {"ITs_stc_stats_info_get_app_id_p",ITs_stc_stats_info_get_app_id_p,ITs_stc_startup,ITs_stc_cleanup}, {"ITs_stc_stats_info_get_iface_name_p",ITs_stc_stats_info_get_iface_name_p,ITs_stc_startup,ITs_stc_cleanup}, diff --git a/src/itc/stc/tct-stc-native_tizeniot.h b/src/itc/stc/tct-stc-native_tizeniot.h index c954d7896..0fd7543a4 100755 --- a/src/itc/stc/tct-stc-native_tizeniot.h +++ b/src/itc/stc/tct-stc-native_tizeniot.h @@ -29,7 +29,6 @@ extern int ITs_stc_stats_rule_set_get_time_interval_p(void); extern int ITs_stc_stats_rule_set_get_iface_type_p(void); extern int ITs_stc_stats_rule_set_get_time_period_p(void); extern int ITs_stc_foreach_stats_p(void); -extern int ITs_stc_get_total_stats_p(void); extern int ITs_stc_get_stats_p(void); extern int ITs_stc_stats_info_get_app_id_p(void); extern int ITs_stc_stats_info_get_iface_name_p(void); @@ -49,7 +48,6 @@ testcase tc_array[] = { {"ITs_stc_stats_rule_set_get_iface_type_p",ITs_stc_stats_rule_set_get_iface_type_p,ITs_stc_startup,ITs_stc_cleanup}, {"ITs_stc_stats_rule_set_get_time_period_p",ITs_stc_stats_rule_set_get_time_period_p,ITs_stc_startup,ITs_stc_cleanup}, {"ITs_stc_foreach_stats_p",ITs_stc_foreach_stats_p,ITs_stc_startup,ITs_stc_cleanup}, - {"ITs_stc_get_total_stats_p",ITs_stc_get_total_stats_p,ITs_stc_startup,ITs_stc_cleanup}, {"ITs_stc_get_stats_p",ITs_stc_get_stats_p,ITs_stc_startup,ITs_stc_cleanup}, {"ITs_stc_stats_info_get_app_id_p",ITs_stc_stats_info_get_app_id_p,ITs_stc_startup,ITs_stc_cleanup}, {"ITs_stc_stats_info_get_iface_name_p",ITs_stc_stats_info_get_iface_name_p,ITs_stc_startup,ITs_stc_cleanup}, diff --git a/src/itc/stc/tct-stc-native_wearable.h b/src/itc/stc/tct-stc-native_wearable.h index c954d7896..0fd7543a4 100755 --- a/src/itc/stc/tct-stc-native_wearable.h +++ b/src/itc/stc/tct-stc-native_wearable.h @@ -29,7 +29,6 @@ extern int ITs_stc_stats_rule_set_get_time_interval_p(void); extern int ITs_stc_stats_rule_set_get_iface_type_p(void); extern int ITs_stc_stats_rule_set_get_time_period_p(void); extern int ITs_stc_foreach_stats_p(void); -extern int ITs_stc_get_total_stats_p(void); extern int ITs_stc_get_stats_p(void); extern int ITs_stc_stats_info_get_app_id_p(void); extern int ITs_stc_stats_info_get_iface_name_p(void); @@ -49,7 +48,6 @@ testcase tc_array[] = { {"ITs_stc_stats_rule_set_get_iface_type_p",ITs_stc_stats_rule_set_get_iface_type_p,ITs_stc_startup,ITs_stc_cleanup}, {"ITs_stc_stats_rule_set_get_time_period_p",ITs_stc_stats_rule_set_get_time_period_p,ITs_stc_startup,ITs_stc_cleanup}, {"ITs_stc_foreach_stats_p",ITs_stc_foreach_stats_p,ITs_stc_startup,ITs_stc_cleanup}, - {"ITs_stc_get_total_stats_p",ITs_stc_get_total_stats_p,ITs_stc_startup,ITs_stc_cleanup}, {"ITs_stc_get_stats_p",ITs_stc_get_stats_p,ITs_stc_startup,ITs_stc_cleanup}, {"ITs_stc_stats_info_get_app_id_p",ITs_stc_stats_info_get_app_id_p,ITs_stc_startup,ITs_stc_cleanup}, {"ITs_stc_stats_info_get_iface_name_p",ITs_stc_stats_info_get_iface_name_p,ITs_stc_startup,ITs_stc_cleanup},