diff options
author | Junghwan Song <jump.song@samsung.com> | 2012-08-24 16:22:03 +0900 |
---|---|---|
committer | Junghwan Song <jump.song@samsung.com> | 2012-08-24 16:33:11 +0900 |
commit | b1495a395a8f8bbc0ae1938084b8a6c659e86fd1 (patch) | |
tree | cf90425309f1772b8a663e37a6725e8eb1c03644 | |
parent | 720b7c96bf526e626bb9ce3c40a46f8590342c65 (diff) | |
download | call-b1495a395a8f8bbc0ae1938084b8a6c659e86fd1.tar.gz call-b1495a395a8f8bbc0ae1938084b8a6c659e86fd1.tar.bz2 call-b1495a395a8f8bbc0ae1938084b8a6c659e86fd1.zip |
delete test app codeHEADsubmit/master/20120920.151021master2.0alpha
Signed-off-by: Junghwan Song <jump.song@samsung.com>
-rwxr-xr-x | CMakeLists.txt | 2 | ||||
-rwxr-xr-x | test/CMakeLists.txt | 20 | ||||
-rw-r--r-- | test/call_get_video_call_state_test.c | 78 | ||||
-rw-r--r-- | test/call_get_voice_call_state_test.c | 78 | ||||
-rw-r--r-- | test/call_video_call_state_changed_test.c | 86 | ||||
-rw-r--r-- | test/call_voice_call_state_changed_test.c | 85 |
6 files changed, 0 insertions, 349 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index bbebf43..5f2c6d2 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -104,8 +104,6 @@ CONFIGURE_FILE( ) INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/${fw_name}.pc DESTINATION lib/pkgconfig) -ADD_SUBDIRECTORY(test) - IF(UNIX) ADD_CUSTOM_TARGET (distclean @echo cleaning for source distribution) diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt deleted file mode 100755 index ffe7614..0000000 --- a/test/CMakeLists.txt +++ /dev/null @@ -1,20 +0,0 @@ -SET(fw_test "${fw_name}-test") - -INCLUDE(FindPkgConfig) -#pkg_check_modules(${fw_test} REQUIRED glib-2.0) -FOREACH(flag ${${fw_test}_CFLAGS}) - SET(EXTRA_CFLAGS "${EXTRA_CFLAGS} ${flag}") -ENDFOREACH(flag) - -SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${EXTRA_CFLAGS} -Wall") - -#ADD_EXECUTABLE("system-sensor" system-sensor.c) -#TARGET_LINK_LIBRARIES("system-sensor" ${fw_name} ${${fw_test}_LDFLAGS}) - -aux_source_directory(. sources) -FOREACH(src ${sources}) - GET_FILENAME_COMPONENT(src_name ${src} NAME_WE) - MESSAGE("${src_name}") - ADD_EXECUTABLE(${src_name} ${src}) - TARGET_LINK_LIBRARIES(${src_name} ${fw_name} ${${fw_test}_LDFLAGS}) -ENDFOREACH() diff --git a/test/call_get_video_call_state_test.c b/test/call_get_video_call_state_test.c deleted file mode 100644 index 46140b7..0000000 --- a/test/call_get_video_call_state_test.c +++ /dev/null @@ -1,78 +0,0 @@ -/* - * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved - * - * Licensed under the Apache License, Version 2.0 (the License); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an AS IS BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - - -#include <stdio.h> -#include <string.h> -#include <call.h> -#include <dlog.h> - -#ifdef LOG_TAG -#undef LOG_TAG -#endif -#define LOG_TAG "TIZEN_N_CALL_TEST" -#define DBG_MODE (1) - -void convert_state_into_string(call_state_e call_state, char* call_state_string) -{ - switch(call_state) - { - case CALL_STATE_IDLE: - snprintf(call_state_string, 256, "idle"); - break; - case CALL_STATE_CONNECTING: - snprintf(call_state_string, 256, "connecting"); - break; - case CALL_STATE_ACTIVE: - snprintf(call_state_string, 256, "active"); - break; - default: - snprintf(call_state_string, 256, "unknown"); - break; - } - -} - -int main() -{ - int ret = 0; - call_state_e call_state = CALL_STATE_IDLE; - char call_state_string[256] = ""; - int ret_value = call_get_video_call_state(&call_state); - - switch(ret_value) - { - case CALL_ERROR_NONE: - convert_state_into_string(call_state, call_state_string); - LOGI("[%s] CALL is %s", __FUNCTION__, call_state_string); - ret = 0; - break; - case CALL_ERROR_OPERATION_FAILED: - LOGI("[%s] CALL_ERROR_OPERATION_FAILED", __FUNCTION__); - ret = -1; - break; - case CALL_ERROR_INVALID_PARAMETER: - LOGI("[%s] CALL_ERROR_INVALID_PARAMETER", __FUNCTION__); - ret = -1; - break; - default: - LOGI("[%s] Unexpected return value", __FUNCTION__); - ret = -1; - break; - } - - return ret; -} diff --git a/test/call_get_voice_call_state_test.c b/test/call_get_voice_call_state_test.c deleted file mode 100644 index ca1ed28..0000000 --- a/test/call_get_voice_call_state_test.c +++ /dev/null @@ -1,78 +0,0 @@ -/* - * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved - * - * Licensed under the Apache License, Version 2.0 (the License); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an AS IS BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - - -#include <stdio.h> -#include <string.h> -#include <call.h> -#include <dlog.h> - -#ifdef LOG_TAG -#undef LOG_TAG -#endif -#define LOG_TAG "TIZEN_N_CALL_TEST" -#define DBG_MODE (1) - -void convert_state_into_string(call_state_e call_state, char* call_state_string) -{ - switch(call_state) - { - case CALL_STATE_IDLE: - snprintf(call_state_string, 256, "idle"); - break; - case CALL_STATE_CONNECTING: - snprintf(call_state_string, 256, "connecting"); - break; - case CALL_STATE_ACTIVE: - snprintf(call_state_string, 256, "active"); - break; - default: - snprintf(call_state_string, 256, "unknown"); - break; - } - -} - -int main() -{ - int ret = 0; - call_state_e call_state = CALL_STATE_IDLE; - char call_state_string[256] = ""; - int ret_value = call_get_voice_call_state(&call_state); - - switch(ret_value) - { - case CALL_ERROR_NONE: - convert_state_into_string(call_state, call_state_string); - LOGI("[%s] CALL is %s", __FUNCTION__, call_state_string); - ret = 0; - break; - case CALL_ERROR_OPERATION_FAILED: - LOGI("[%s] CALL_ERROR_OPERATION_FAILED", __FUNCTION__); - ret = -1; - break; - case CALL_ERROR_INVALID_PARAMETER: - LOGI("[%s] CALL_ERROR_INVALID_PARAMETER", __FUNCTION__); - ret = -1; - break; - default: - LOGI("[%s] Unexpected return value", __FUNCTION__); - ret = -1; - break; - } - - return ret; -} diff --git a/test/call_video_call_state_changed_test.c b/test/call_video_call_state_changed_test.c deleted file mode 100644 index 6bf285d..0000000 --- a/test/call_video_call_state_changed_test.c +++ /dev/null @@ -1,86 +0,0 @@ -/* - * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved - * - * Licensed under the Apache License, Version 2.0 (the License); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an AS IS BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - - -#include <stdio.h> -#include <string.h> -#include <call.h> -#include <dlog.h> -#include <glib.h> - -#ifdef LOG_TAG -#undef LOG_TAG -#endif -#define LOG_TAG "TIZEN_N_CALL_TEST" -#define DBG_MODE (1) - -static GMainLoop *event_loop; - -char* convert_state_to_string(call_state_e call_state) -{ - switch(call_state) - { - case CALL_STATE_IDLE: - return "idle"; - case CALL_STATE_CONNECTING: - return "connecting"; - case CALL_STATE_ACTIVE: - return "active"; - default: - return "unknown"; - } -} - -void video_call_state_changed(call_state_e call_state, void* user_data) -{ - LOGI("[%s] Start video_call_state_changed", __FUNCTION__); - - LOGI("[%s] Status of video call: %s", __FUNCTION__, convert_state_to_string(call_state)); - LOGI("[%s] user data: %s", __FUNCTION__, user_data); - - LOGI("[%s] End video_call_state_changed", __FUNCTION__); - g_main_loop_quit(event_loop); -} - -int main() -{ - if( call_set_video_call_state_changed_cb(video_call_state_changed, - "call_video_call_state_changed_test") == CALL_ERROR_NONE ) - { - LOGI("[%s] Succeeded to set callback function", __FUNCTION__); - } - else - { - LOGE("[%s] Failed to set callback function", __FUNCTION__); - return -1; - } - - LOGI("[%s] If you change the state of video, then callback function will be called", __FUNCTION__); - event_loop = g_main_loop_new(NULL, FALSE); - g_main_loop_run(event_loop); - - if( call_unset_video_call_state_changed_cb() == CALL_ERROR_NONE ) - { - LOGI("[%s] Succeeded to unset callback function", __FUNCTION__); - } - else - { - LOGE("[%s] Failed to unset callback function", __FUNCTION__); - return -1; - } - - return 0; -} diff --git a/test/call_voice_call_state_changed_test.c b/test/call_voice_call_state_changed_test.c deleted file mode 100644 index 2310c99..0000000 --- a/test/call_voice_call_state_changed_test.c +++ /dev/null @@ -1,85 +0,0 @@ -/* - * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved - * - * Licensed under the Apache License, Version 2.0 (the License); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an AS IS BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - - -#include <stdio.h> -#include <string.h> -#include <call.h> -#include <dlog.h> -#include <glib.h> - -#ifdef LOG_TAG -#undef LOG_TAG -#endif -#define LOG_TAG "TIZEN_N_CALL_TEST" -#define DBG_MODE (1) - -static GMainLoop *event_loop; - -char* convert_state_to_string(call_state_e call_state) -{ - switch(call_state) - { - case CALL_STATE_IDLE: - return "idle"; - case CALL_STATE_CONNECTING: - return "connecting"; - case CALL_STATE_ACTIVE: - return "active"; - default: - return "unknown"; - } -} -void voice_call_state_changed(call_state_e call_state, void* user_data) -{ - LOGI("[%s] Start voice_call_state_changed", __FUNCTION__); - - LOGI("[%s] Status of voice call: %s", __FUNCTION__, convert_state_to_string(call_state)); - LOGI("[%s] user data: %s", __FUNCTION__, user_data); - - LOGI("[%s] End voice_call_state_changed", __FUNCTION__); - g_main_loop_quit(event_loop); -} - -int main() -{ - if( call_set_voice_call_state_changed_cb(voice_call_state_changed, - "call_voice_call_state_changed_test") == CALL_ERROR_NONE ) - { - LOGI("[%s] Succeeded to set callback function", __FUNCTION__); - } - else - { - LOGE("[%s] Failed to set callback function", __FUNCTION__); - return -1; - } - - LOGI("[%s] If you change the state of voice, then callback function will be called", __FUNCTION__); - event_loop = g_main_loop_new(NULL, FALSE); - g_main_loop_run(event_loop); - - if( call_unset_voice_call_state_changed_cb() == CALL_ERROR_NONE ) - { - LOGI("[%s] Succeeded to unset callback function", __FUNCTION__); - } - else - { - LOGE("[%s] Failed to unset callback function", __FUNCTION__); - return -1; - } - - return 0; -} |