Add unit test cases for enhancing line coverage 84/286184/1
authorSuyeon Hwang <stom.hwang@samsung.com>
Fri, 18 Nov 2022 08:34:19 +0000 (17:34 +0900)
committerSuyeon Hwang <stom.hwang@samsung.com>
Fri, 30 Dec 2022 01:45:08 +0000 (10:45 +0900)
- Issue:
Line coverage of unit test is too low.

- Solution:
This patch adds new test cases to cover uncovered logics in voice
control client library. Through this patch, the line coverage of unit
test will be bigger.

Change-Id: Ida10976a7bd7bb06c6378d367dfec8df06ecf953
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
packaging/voice-control.spec
tests/res/test_command.json
tests/src/test_util.cpp [new file with mode: 0644]
tests/src/test_util.h [new file with mode: 0644]
tests/src/vc_unittests.cpp

index 799eef6..e318157 100644 (file)
@@ -160,20 +160,21 @@ rm -rf %{buildroot}
 builddir=$(basename $PWD)
 gcno_obj_dir=%{buildroot}%{_datadir}/gcov/obj/%{name}/"$builddir"
 mkdir -p "$gcno_obj_dir"
+find ./client/CMakeFiles/vc_* -name '*.gcno' -exec rm {} \;
 find ./server/ -name '*.gcno' -exec rm {} \;
 find ./audio-manager/ -name '*.gcno' -exec rm {} \;
 find ./tests/ -name '*.gcno' -exec rm {} \;
 find ./engine-parser/ -name '*.gcno' -exec rm {} \;
-find . -name '*_client.c.gcno' -exec rm {} \;
 find . -name '*_dbus.c.gcno' -exec rm {} \;
 find . -name '*_cmd_db.c.gcno' -exec rm {} \;
-find . -name '*_command*.gcno' -exec rm {} \;
 find . -name '*_config_*.gcno' -exec rm {} \;
 find . -name '*_parser.c.gcno' -exec rm {} \;
-find . -name '*_data*.gcno' -exec rm {} \;
 find . -name 'vc_mgr*.gcno' -exec rm {} \;
 find . -name 'vc_setting*.gcno' -exec rm {} \;
 find . -name 'vc_widget*.gcno' -exec rm {} \;
+find . -name 'vc_proxy*.gcno' -exec rm {} \;
+find . -name 'vc_command_util*.gcno' -exec rm {} \;
+find . -name '*_data*.gcno' -exec rm {} \;
 find . -name '*.gcno' -exec cp --parents '{}' "$gcno_obj_dir" ';'
 %endif
 
index 6ad1064..f0d971c 100644 (file)
                        "domain": "0",
                        "cmd": "zoom"
                }
+       ],
+       "background" : [
+               {
+                       "format": "0",
+                       "domain": "0",
+                       "cmd": "capture"
+               },
+               {
+                       "format": "0",
+                       "domain": "0",
+                       "cmd": "zoom"
+               }
        ]
 }
\ No newline at end of file
diff --git a/tests/src/test_util.cpp b/tests/src/test_util.cpp
new file mode 100644 (file)
index 0000000..0a0f1c6
--- /dev/null
@@ -0,0 +1,57 @@
+/*
+ * Copyright (c) 2022 Samsung Electronics Co., Ltd.
+ *
+ * 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 <app_manager_extension.h>
+#include <vconf.h>
+#include <gtest/gtest.h>
+#include <Ecore.h>
+
+#include "test_util.h"
+
+void terminate_current_engine()
+{
+       char* engine_id = vconf_get_str(VCONFKEY_VC_ENGINE_DEFAULT);
+
+       app_context_h context = nullptr;
+       EXPECT_EQ(app_manager_get_app_context(engine_id, &context), APP_MANAGER_ERROR_NONE);
+       EXPECT_NE(context, nullptr);
+       free(engine_id);
+
+       EXPECT_EQ(app_manager_terminate_app(context), APP_MANAGER_ERROR_NONE);
+       EXPECT_EQ(app_context_destroy(context), APP_MANAGER_ERROR_NONE);
+}
+
+void wait_engine_terminated(int wait_delay)
+{
+       int max_count = wait_delay * 10;
+       int count = 0;
+
+       char* engine_id = vconf_get_str(VCONFKEY_VC_ENGINE_DEFAULT);
+
+       while (max_count > count) {
+               bool is_running = false;
+               app_manager_is_running(engine_id, &is_running);
+
+               if (false == is_running) {
+                       return;
+               }
+
+               ecore_main_loop_iterate();
+               usleep(100000);
+               count++;
+       }
+}
diff --git a/tests/src/test_util.h b/tests/src/test_util.h
new file mode 100644 (file)
index 0000000..702831b
--- /dev/null
@@ -0,0 +1,33 @@
+/*
+ * Copyright (c) 2022 Samsung Electronics Co., Ltd.
+ *
+ * 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.
+ */
+
+
+#ifndef __VC_TEST_UTIL_H__
+#define __VC_TEST_UTIL_H__
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+void terminate_current_engine();
+void wait_engine_terminated(int wait_delay);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif  /* __VC_TEST_UTIL_H__ */
\ No newline at end of file
index 6963fbc..5f71301 100644 (file)
 #include <gtest/gtest.h>
 #include <Ecore.h>
 #include <system_info.h>
+#include <app_manager.h>
+#include <vconf.h>
+#include <tzplatform_config.h>
 
 #include <voice_control.h>
+#include <voice_control_internal.h>
 #include <voice_control_manager.h>
+#include <voice_control_command_expand.h>
 #include "system_info_mock.h"
 #include "cynara_mock.h"
 
+#include "test_util.h"
+
+
+static const char *TEST_COMMAND_JSON_PATH = tzplatform_mkpath(tzplatform_getid("TZ_SYS_RO_APP"), "/org.tizen.vc-unittests/res/test_command.json");
+static const char *TEST_APP_ID = "org.tizen.vc-unittests";
+static const char *TEST_INVOCATION_NAME = "invocation";
+static const char *TEST_CREDENTIAL = "credential";
+
 static int g_vc_init = false;
 static vc_state_e g_vc_state = VC_STATE_NONE;
+static vc_service_state_e g_vc_service_state = VC_SERVICE_STATE_NONE;
+
 static vc_state_e g_vc_mgr_state = VC_STATE_NONE;
 static vc_service_state_e g_vc_mgr_service_state = VC_SERVICE_STATE_NONE;
 static bool g_vc_supported = false;
 
+static bool g_error_cb_invoked = false;
+
+vc_cmd_list_h g_test_commands = nullptr;
+
 static bool __is_mgr_state_changed(vc_state_e state, int wait_delay)
 {
        int max_count = wait_delay * 10;
@@ -63,6 +82,60 @@ static bool __is_mgr_service_state_changed(vc_service_state_e state, int wait_de
        return true;
 }
 
+static bool __is_state_changed(vc_state_e state, int wait_delay)
+{
+       int max_count = wait_delay * 10;
+       int count = 0;
+       while (max_count > count && state != g_vc_state) {
+               ecore_main_loop_iterate();
+               usleep(100000);
+               count++;
+       }
+
+       return (state == g_vc_state);
+}
+
+static bool __is_service_state_changed(vc_service_state_e state, int wait_delay)
+{
+       int max_count = wait_delay * 10;
+       int count = 0;
+       while (max_count > count && state != g_vc_service_state) {
+               ecore_main_loop_iterate();
+               usleep(100000);
+               count++;
+       }
+
+       return (state == g_vc_service_state);
+}
+
+static bool __is_error_cb_invoked(int wait_delay)
+{
+       int max_count = wait_delay * 10;
+       int count = 0;
+       while (max_count > count && false == g_error_cb_invoked) {
+               ecore_main_loop_iterate();
+               usleep(100000);
+               count++;
+       }
+
+       return g_error_cb_invoked;
+}
+
+static void __vc_mgr_state_changed_cb(vc_state_e previous, vc_state_e current, void* user_data)
+{
+       g_vc_mgr_state = current;
+}
+
+static void __vc_mgr_service_state_changed_cb(vc_service_state_e previous, vc_service_state_e current, void* user_data)
+{
+       g_vc_mgr_service_state = current;
+}
+
+static bool __vc_mgr_all_result_cb(vc_result_event_e event, vc_cmd_list_h vc_cmd_list, const char *result, const char *msg, void *user_data)
+{
+       return true;
+}
+
 static void __vc_result_cb(vc_result_event_e event, vc_cmd_list_h vc_cmd_list, const char* result, void* user_data)
 {
 }
@@ -81,21 +154,21 @@ static void __vc_state_changed_cb(vc_state_e previous, vc_state_e current, void*
        g_vc_state = current;
 }
 
-static void __vc_mgr_state_changed_cb(vc_state_e previous, vc_state_e current, void* user_data)
+static void __vc_service_state_changed_cb(vc_service_state_e previous, vc_service_state_e current, void* user_data)
 {
-       g_vc_mgr_state = current;
+       g_vc_service_state = current;
 }
 
-static void __vc_mgr_service_state_changed_cb(vc_service_state_e previous, vc_service_state_e current, void* user_data)
+static void __vc_error_cb(vc_error_e reason, void* user_data)
 {
-       g_vc_mgr_service_state = current;
+       g_error_cb_invoked = true;
 }
 
-static void __vc_service_state_changed_cb(vc_service_state_e previous, vc_service_state_e current, void* user_data)
+static void __vc_tts_streaming_cb(vc_tts_event_e event, char* buffer, int len, int utt_id, void *user_data)
 {
 }
 
-static void __vc_error_cb(vc_error_e reason, void* user_data)
+static void __vc_tts_utterance_status_cb(int utt_id, vc_tts_utterance_status_e status, void *user_data)
 {
 }
 
@@ -109,13 +182,14 @@ static void __vc_mgr_ready()
        EXPECT_EQ(vc_mgr_initialize(), VC_ERROR_NONE);
        EXPECT_EQ(vc_mgr_set_state_changed_cb(__vc_mgr_state_changed_cb, nullptr), VC_ERROR_NONE);
        EXPECT_EQ(vc_mgr_set_service_state_changed_cb(__vc_mgr_service_state_changed_cb, nullptr), VC_ERROR_NONE);
+       EXPECT_EQ(vc_mgr_set_all_result_cb(__vc_mgr_all_result_cb, nullptr), VC_ERROR_NONE);
        EXPECT_EQ(vc_mgr_prepare(), VC_ERROR_NONE);
        ASSERT_EQ(true, __is_mgr_state_changed(VC_STATE_READY, 5));
        ASSERT_EQ(true, __is_mgr_service_state_changed(VC_SERVICE_STATE_READY, 5));
 
        vc_cmd_h system_command = nullptr;
        EXPECT_EQ(vc_cmd_create(&system_command), VC_ERROR_NONE);
-       EXPECT_EQ(vc_cmd_set_command(system_command, "test"), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_set_command(system_command, "manager"), VC_ERROR_NONE);
        EXPECT_EQ(vc_cmd_set_type(system_command, VC_COMMAND_TYPE_SYSTEM), VC_ERROR_NONE);
 
        vc_cmd_list_h commands = nullptr;
@@ -152,15 +226,67 @@ static bool __is_vc_supported()
        return (is_vc_supported && is_mic_supported);
 }
 
+static vc_cmd_list_h __create_test_command_list()
+{
+       vc_cmd_h system_command = nullptr;
+       EXPECT_EQ(vc_cmd_create(&system_command), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_set_command(system_command, "test"), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_set_type(system_command, VC_COMMAND_TYPE_FOREGROUND), VC_ERROR_NONE);
+
+       vc_cmd_list_h commands = nullptr;
+       EXPECT_EQ(vc_cmd_list_create(&commands), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_list_add(commands, system_command), VC_ERROR_NONE);
+
+       return commands;
+}
+
+static void __initialize_test_environment()
+{
+       ecore_init();
+       ecore_main_loop_glib_integrate();
+
+       g_vc_supported = __is_vc_supported();
+
+       g_vc_mgr_state = VC_STATE_NONE;
+       g_vc_mgr_service_state = VC_SERVICE_STATE_NONE;
+
+       g_vc_state = VC_STATE_NONE;
+       g_vc_service_state = VC_SERVICE_STATE_NONE;
+
+       g_error_cb_invoked = false;
+
+       g_test_commands = __create_test_command_list();
+}
+
+static void __shutdown_test_environment()
+{
+       vc_cmd_list_destroy(g_test_commands, true);
+       g_test_commands = nullptr;
+
+       wait_engine_terminated(1);
+
+       ecore_shutdown();
+}
+
 namespace {
 
+class VCTestInNoneState : public testing::Test {
+       public:
+               virtual void SetUp() {
+                       __initialize_test_environment();
+               }
+
+               virtual void TearDown()
+               {
+                       vc_deinitialize();
+                       __shutdown_test_environment();
+               }
+};
+
 class VCTest : public testing::Test {
     public:
         virtual void SetUp() {
-                       ecore_init();
-                       ecore_main_loop_glib_integrate();
-
-                       g_vc_supported = __is_vc_supported();
+                       __initialize_test_environment();
 
                        if (false == g_vc_supported) {
                                g_vc_init = false;
@@ -170,17 +296,49 @@ class VCTest : public testing::Test {
                        g_vc_init = true;
                        vc_initialize();
                        vc_set_state_changed_cb(__vc_state_changed_cb, NULL);
+                       vc_set_service_state_changed_cb(__vc_service_state_changed_cb, nullptr);
+               }
+
+               virtual void TearDown()
+               {
+                       if (true == g_vc_supported)
+                       {
+                               vc_unset_state_changed_cb();
+                               vc_deinitialize();
+                       }
+
+                       __shutdown_test_environment();
+               }
+};
+
+class VCTestInReadyState : public testing::Test {
+       public:
+               virtual void SetUp() {
+                       __initialize_test_environment();
+
+                       if (false == g_vc_supported) {
+                               return;
+                       }
+
+                       vc_initialize();
+                       vc_set_state_changed_cb(__vc_state_changed_cb, nullptr);
+                       vc_set_service_state_changed_cb(__vc_service_state_changed_cb, nullptr);
+
+                       vc_prepare_sync();
+                       EXPECT_EQ(__is_state_changed(VC_STATE_READY, 5), true);
+                       EXPECT_EQ(__is_service_state_changed(VC_SERVICE_STATE_READY, 5), true);
                }
 
                virtual void TearDown()
                {
                        if (true == g_vc_supported)
                        {
+                               vc_unprepare();
                                vc_unset_state_changed_cb();
                                vc_deinitialize();
                        }
 
-                       ecore_shutdown();
+                       __shutdown_test_environment();
                }
 };
 
@@ -216,6 +374,37 @@ TEST_F(VCTest, vc_deinitialize_p)
 }
 
 /**
+ * @testcase           utc_vc_deinitialize_p2
+ * @since_tizen                2.4
+ * @description                Positive UTC for deinitialize voice control handle
+ */
+TEST_F(VCTest, utc_vc_deinitialize_p2)
+{
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_deinitialize(), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_prepare(), VC_ERROR_NONE);
+       EXPECT_EQ(vc_deinitialize(), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_deinitialize_p3
+ * @since_tizen                2.4
+ * @description                Positive UTC for deinitialize voice control handle
+ */
+TEST_F(VCTestInReadyState, utc_vc_deinitialize_p3)
+{
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_deinitialize(), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_deinitialize(), VC_ERROR_NONE);
+}
+
+/**
  * @testcase           utc_vc_deinitialize_n
  * @since_tizen                2.4
  * @description                Negative UTC for deinitialize voice control handle (Already deinitialized)
@@ -274,23 +463,67 @@ TEST_F(VCTest, vc_prepare_p)
  * @since_tizen                2.4
  * @description                Negative UTC for connect service daemon (Invalid state)
  */
-TEST_F(VCTestvc_prepare_n)
+TEST_F(VCTestInNoneState, utc_vc_prepare_n)
 {
        if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
+               EXPECT_EQ(vc_prepare(), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_prepare();
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
+       EXPECT_EQ(vc_prepare(), VC_ERROR_INVALID_STATE);
 
-               vc_deinitialize();
+       EXPECT_EQ(vc_initialize(), VC_ERROR_NONE);
+       EXPECT_EQ(vc_set_state_changed_cb(__vc_state_changed_cb, nullptr), VC_ERROR_NONE);
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_prepare();
-               EXPECT_EQ(ret, VC_ERROR_INVALID_STATE);
+       EXPECT_EQ(vc_prepare(), VC_ERROR_NONE);
+       EXPECT_EQ(__is_state_changed(VC_STATE_READY, 5), true);
+       EXPECT_EQ(vc_prepare(), VC_ERROR_INVALID_STATE);
+
+       EXPECT_EQ(vc_unprepare(), VC_ERROR_NONE);
+       EXPECT_EQ(vc_deinitialize(), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_prepare_sync_p
+ * @since_tizen                4.0
+ * @description                Positive UTC for connect service engine synchronously
+ */
+TEST_F(VCTest, utc_vc_prepare_sync_p)
+{
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_prepare_sync(), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_prepare_sync(), VC_ERROR_NONE);
+       EXPECT_EQ(__is_state_changed(VC_STATE_READY, 5), true);
+
+       EXPECT_EQ(vc_unprepare(), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_prepare_sync_n
+ * @since_tizen                4.0
+ * @description                Negative UTC for connect service engine synchronously (Invalid state)
+ */
+TEST_F(VCTestInNoneState, utc_vc_prepare_sync_n)
+{
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_prepare_sync(), VC_ERROR_NOT_SUPPORTED);
+               return;
        }
+
+       EXPECT_EQ(vc_prepare_sync(), VC_ERROR_INVALID_STATE);
+
+       EXPECT_EQ(vc_initialize(), VC_ERROR_NONE);
+       EXPECT_EQ(vc_set_state_changed_cb(__vc_state_changed_cb, nullptr), VC_ERROR_NONE);
+
+       EXPECT_EQ(vc_prepare_sync(), VC_ERROR_NONE);
+       EXPECT_EQ(__is_state_changed(VC_STATE_READY, 5), true);
+       EXPECT_EQ(vc_prepare_sync(), VC_ERROR_INVALID_STATE);
+
+       EXPECT_EQ(vc_unprepare(), VC_ERROR_NONE);
+       EXPECT_EQ(vc_deinitialize(), VC_ERROR_NONE);
 }
 
 /**
@@ -327,46 +560,19 @@ TEST_F(VCTest, vc_unprepare_p)
  * @since_tizen                2.4
  * @description                Negative UTC for disconnect service daemon (Invalid state)
  */
-TEST_F(VCTestvc_unprepare_n)
+TEST_F(VCTestInNoneState, utc_vc_unprepare_n)
 {
        if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
-
-               int ret = VC_ERROR_NONE;
-               ret = vc_unprepare();
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
-
-               int ret = VC_ERROR_NONE;
-               ret = vc_unprepare();
-               EXPECT_EQ(ret, VC_ERROR_INVALID_STATE);
+               EXPECT_EQ(vc_unprepare(), VC_ERROR_NOT_SUPPORTED);
+               return;
        }
-}
-
-/**
- * @testcase           utc_vc_unprepare_n2
- * @since_tizen                2.4
- * @description                Negative UTC for disconnect service daemon (Invalid state)
- */
-TEST_F(VCTest, vc_unprepare_n2)
-{
-       if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_unprepare();
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
+       EXPECT_EQ(vc_unprepare(), VC_ERROR_INVALID_STATE);
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_deinitialize();
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+       EXPECT_EQ(vc_initialize(), VC_ERROR_NONE);
+       EXPECT_EQ(vc_unprepare(), VC_ERROR_INVALID_STATE);
 
-               ret = vc_unprepare();
-               EXPECT_EQ(ret, VC_ERROR_INVALID_STATE);
-       }
+       EXPECT_EQ(vc_deinitialize(), VC_ERROR_NONE);
 }
 
 /**
@@ -532,57 +738,29 @@ TEST_F(VCTest, vc_get_current_language_n2)
  * @since_tizen                2.4
  * @description                Positive UTC for get current state
  */
-TEST_F(VCTest, vc_get_state_p)
+TEST_F(VCTestInNoneState, vc_get_state_p)
 {
+       vc_state_e state = VC_STATE_NONE;
        if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
-
-               int ret = VC_ERROR_NONE;
-               vc_state_e state = VC_STATE_NONE;
-               ret = vc_get_state(&state);
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
-
-               int ret = VC_ERROR_NONE;
-               vc_state_e state = VC_STATE_NONE;
-               ret = vc_get_state(&state);
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+               EXPECT_EQ(vc_get_state(&state), VC_ERROR_NOT_SUPPORTED);
+               return;
        }
-}
-
-/**
- * @testcase           utc_vc_get_state_p2
- * @since_tizen                2.4
- * @description                Positive UTC for get current state after connection
- */
-TEST_F(VCTest, vc_get_state_p2)
-{
-       if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
-
-               int ret = VC_ERROR_NONE;
-               vc_state_e state = VC_STATE_NONE;
-               ret = vc_get_state(&state);
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_prepare();
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+       EXPECT_EQ(vc_get_state(&state), VC_ERROR_NONE);
+       EXPECT_EQ(state, VC_STATE_NONE);
 
-               while (VC_STATE_READY != g_vc_state) {
-                       ecore_main_loop_iterate();
-               }
+       EXPECT_EQ(vc_initialize(), VC_ERROR_NONE);
+       EXPECT_EQ(vc_get_state(&state), VC_ERROR_NONE);
+       EXPECT_EQ(state, VC_STATE_INITIALIZED);
 
-               vc_state_e state = VC_STATE_NONE;
-               ret = vc_get_state(&state);
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+       EXPECT_EQ(vc_set_state_changed_cb(__vc_state_changed_cb, nullptr), VC_ERROR_NONE);
+       EXPECT_EQ(vc_prepare(), VC_ERROR_NONE);
+       EXPECT_EQ(__is_state_changed(VC_STATE_READY, 5), true);
+       EXPECT_EQ(vc_get_state(&state), VC_ERROR_NONE);
+       EXPECT_EQ(state, VC_STATE_READY);
 
-               ret = vc_unprepare();
-               EXPECT_EQ(ret, VC_ERROR_NONE);
-       }
+       EXPECT_EQ(vc_unprepare(), VC_ERROR_NONE);
+       EXPECT_EQ(vc_deinitialize(), VC_ERROR_NONE);
 }
 
 /**
@@ -608,113 +786,79 @@ TEST_F(VCTest, vc_get_state_n)
 }
 
 /**
- * @testcase           utc_vc_get_state_n2
+ * @testcase           utc_vc_get_service_state_p
  * @since_tizen                2.4
- * @description                Negative UTC for get current state (Invalid state)
+ * @description                Positive UTC for get current state of service daemon
  */
-TEST_F(VCTest, vc_get_state_n2)
+TEST_F(VCTestInReadyState, utc_vc_get_service_state_p)
 {
+       vc_service_state_e state = VC_SERVICE_STATE_NONE;
        if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
+               EXPECT_EQ(vc_get_service_state(&state), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
 
-               int ret = VC_ERROR_NONE;
-               vc_state_e state = VC_STATE_NONE;
-               ret = vc_get_state(&state);
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
+       EXPECT_EQ(vc_get_service_state(&state), VC_ERROR_NONE);
+       EXPECT_EQ(state, VC_SERVICE_STATE_READY);
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_deinitialize();
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+       __vc_mgr_ready();
 
-               vc_state_e state = VC_STATE_NONE;
-               ret = vc_get_state(&state);
-               EXPECT_EQ(ret, VC_ERROR_INVALID_STATE);
-       }
+       EXPECT_EQ(vc_mgr_start(false), VC_ERROR_NONE);
+       EXPECT_EQ(__is_service_state_changed(VC_SERVICE_STATE_RECORDING, 5), true);
+
+       EXPECT_EQ(vc_get_service_state(&state), VC_ERROR_NONE);
+       EXPECT_EQ(state, VC_SERVICE_STATE_RECORDING);
+
+       EXPECT_EQ(vc_mgr_stop(), VC_ERROR_NONE);
+       EXPECT_EQ(__is_service_state_changed(VC_SERVICE_STATE_PROCESSING, 5), true);
+
+       EXPECT_EQ(vc_get_service_state(&state), VC_ERROR_NONE);
+       EXPECT_EQ(state, VC_SERVICE_STATE_PROCESSING);
+
+       __vc_mgr_finish();
 }
 
 /**
- * @testcase           utc_vc_get_service_state_p
+ * @testcase           utc_vc_get_service_state_n
  * @since_tizen                2.4
- * @description                Positive UTC for get current state of service daemon
+ * @description                Negative UTC for get current state of service daemon (Invalid parameter)
  */
-TEST_F(VCTest, vc_get_service_state_p)
+TEST_F(VCTest, vc_get_service_state_n)
 {
        if (false == g_vc_supported) {
                EXPECT_EQ(g_vc_init, false);
 
                int ret = VC_ERROR_NONE;
-               vc_service_state_e state = VC_SERVICE_STATE_NONE;
-               ret = vc_get_service_state(&state);
+               ret = vc_get_service_state(NULL);
                EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
        } else {
                EXPECT_EQ(g_vc_init, true);
 
                int ret = VC_ERROR_NONE;
-               ret = vc_prepare();
-               EXPECT_EQ(ret, VC_ERROR_NONE);
-
-               while (VC_STATE_READY != g_vc_state) {
-                       ecore_main_loop_iterate();
-               }
-
-               vc_service_state_e state = VC_SERVICE_STATE_NONE;
-               ret = vc_get_service_state(&state);
-               EXPECT_EQ(ret, VC_ERROR_NONE);
-
-               ret = vc_unprepare();
-               EXPECT_EQ(ret, VC_ERROR_NONE);
-       }
-}
-
-/**
- * @testcase           utc_vc_get_service_state_n
- * @since_tizen                2.4
- * @description                Negative UTC for get current state of service daemon (Invalid parameter)
- */
-TEST_F(VCTest, vc_get_service_state_n)
-{
-       if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
-
-               int ret = VC_ERROR_NONE;
-               ret = vc_get_service_state(NULL);
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
-
-               int ret = VC_ERROR_NONE;
-               ret = vc_get_service_state(NULL);
-               EXPECT_EQ(ret, VC_ERROR_INVALID_PARAMETER);
-       }
-}
+               ret = vc_get_service_state(NULL);
+               EXPECT_EQ(ret, VC_ERROR_INVALID_PARAMETER);
+       }
+}
 
 /**
  * @testcase           utc_vc_get_service_state_n2
  * @since_tizen                2.4
  * @description                Negative UTC for get current state of service daemon (Invalid state)
  */
-TEST_F(VCTest, vc_get_service_state_n2)
+TEST_F(VCTestInNoneState, vc_get_service_state_n2)
 {
+       vc_service_state_e state = VC_SERVICE_STATE_NONE;
        if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
+               EXPECT_EQ(vc_get_service_state(&state), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
 
-               int ret = VC_ERROR_NONE;
-               vc_service_state_e state = VC_SERVICE_STATE_NONE;
-               ret = vc_get_service_state(&state);
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
+       EXPECT_EQ(vc_get_service_state(&state), VC_ERROR_INVALID_STATE);
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_deinitialize();
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+       EXPECT_EQ(vc_initialize(), VC_ERROR_NONE);
+       EXPECT_EQ(vc_get_service_state(&state), VC_ERROR_INVALID_STATE);
 
-               vc_service_state_e state = VC_SERVICE_STATE_NONE;
-               ret = vc_get_service_state(&state);
-               EXPECT_EQ(ret, VC_ERROR_INVALID_STATE);
-       }
+       EXPECT_EQ(vc_deinitialize(), VC_ERROR_NONE);
 }
 
 /**
@@ -826,26 +970,18 @@ TEST_F(VCTest, vc_get_system_command_list_n)
  * @since_tizen                3.0
  * @description                Negative UTC for get the system command list (Invalid state)
  */
-TEST_F(VCTest, vc_get_system_command_list_n2)
+TEST_F(VCTestInNoneState, vc_get_system_command_list_n2)
 {
+       vc_cmd_list_h list = nullptr;
        if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
-
-               int ret = VC_ERROR_NONE;
-               vc_cmd_list_h list = NULL;
-               ret = vc_get_system_command_list(&list);
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
+               EXPECT_EQ(vc_get_system_command_list(&list), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_deinitialize();
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+       EXPECT_EQ(vc_get_system_command_list(&list), VC_ERROR_INVALID_STATE);
 
-               vc_cmd_list_h list = NULL;
-               ret = vc_get_system_command_list(&list);
-               EXPECT_EQ(ret, VC_ERROR_INVALID_STATE);
-       }
+       EXPECT_EQ(vc_initialize(), VC_ERROR_NONE);
+       EXPECT_EQ(vc_get_system_command_list(&list), VC_ERROR_INVALID_STATE);
 }
 
 /**
@@ -906,21 +1042,23 @@ TEST_F(VCTest, vc_set_command_list_p)
  * @since_tizen                2.4
  * @description                Negative UTC for set command list used as candidate set (Invalid parameter)
  */
-TEST_F(VCTestvc_set_command_list_n)
+TEST_F(VCTestInReadyState, utc_vc_set_command_list_n)
 {
-       if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
-
-               int ret = VC_ERROR_NONE;
-               ret = vc_set_command_list(NULL, VC_COMMAND_TYPE_BACKGROUND);
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
+       vc_cmd_list_h empty_cmd_list = nullptr;
+       EXPECT_EQ(vc_cmd_list_create(&empty_cmd_list), VC_ERROR_NONE);
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_set_command_list(NULL, VC_COMMAND_TYPE_BACKGROUND);
-               EXPECT_EQ(ret, VC_ERROR_INVALID_PARAMETER);
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_set_command_list(nullptr, VC_COMMAND_TYPE_BACKGROUND), VC_ERROR_NOT_SUPPORTED);
+               EXPECT_EQ(vc_set_command_list(empty_cmd_list, VC_COMMAND_TYPE_BACKGROUND), VC_ERROR_NOT_SUPPORTED);
+               EXPECT_EQ(vc_set_command_list(g_test_commands, -1), VC_ERROR_NOT_SUPPORTED);
+               vc_cmd_list_destroy(empty_cmd_list, true);
+               return;
        }
+
+       EXPECT_EQ(vc_set_command_list(nullptr, VC_COMMAND_TYPE_BACKGROUND), VC_ERROR_INVALID_PARAMETER);
+       EXPECT_EQ(vc_set_command_list(empty_cmd_list, VC_COMMAND_TYPE_BACKGROUND), VC_ERROR_INVALID_PARAMETER);
+       EXPECT_EQ(vc_set_command_list(g_test_commands, -1), VC_ERROR_INVALID_PARAMETER);
+       vc_cmd_list_destroy(empty_cmd_list, true);
 }
 
 /**
@@ -928,62 +1066,19 @@ TEST_F(VCTest, vc_set_command_list_n)
  * @since_tizen                2.4
  * @description                Negative UTC for set command list used as candidate set (Invalid state)
  */
-TEST_F(VCTestvc_set_command_list_n2)
+TEST_F(VCTestInNoneState, utc_vc_set_command_list_n2)
 {
        if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
-
-               int ret = VC_ERROR_NONE;
-               vc_cmd_list_h list = NULL;
-               ret = vc_set_command_list(list, VC_COMMAND_TYPE_BACKGROUND);
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
-
-               int ret = VC_ERROR_NONE;
-               ret = vc_deinitialize();
-               EXPECT_EQ(ret, VC_ERROR_NONE);
-
-               vc_cmd_list_h list = NULL;
-               ret = vc_cmd_list_create(&list);
-               EXPECT_EQ(ret, VC_ERROR_NONE);
-
-               ret = vc_set_command_list(list, VC_COMMAND_TYPE_BACKGROUND);
-               EXPECT_EQ(ret, VC_ERROR_INVALID_STATE);
-
-               ret = vc_cmd_list_destroy(list, true);
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+               EXPECT_EQ(vc_set_command_list(g_test_commands, VC_COMMAND_TYPE_BACKGROUND), VC_ERROR_NOT_SUPPORTED);
+               return;
        }
-}
-
-/**
- * @testcase           utc_vc_set_command_list_n3
- * @since_tizen                2.4
- * @description                Negative UTC for set command list used as candidate set (Invalid state)
- */
-TEST_F(VCTest, vc_set_command_list_n3)
-{
-       if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
-
-               int ret = VC_ERROR_NONE;
-               vc_cmd_list_h list = NULL;
-               ret = vc_set_command_list(list, VC_COMMAND_TYPE_BACKGROUND);
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
 
-               int ret = VC_ERROR_NONE;
-               vc_cmd_list_h list = NULL;
-               ret = vc_cmd_list_create(&list);
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+       EXPECT_EQ(vc_set_command_list(g_test_commands, VC_COMMAND_TYPE_BACKGROUND), VC_ERROR_INVALID_STATE);
 
-               ret = vc_set_command_list(list, VC_COMMAND_TYPE_BACKGROUND);
-               EXPECT_EQ(ret, VC_ERROR_INVALID_STATE);
+       EXPECT_EQ(vc_initialize(), VC_ERROR_NONE);
+       EXPECT_EQ(vc_set_command_list(g_test_commands, VC_COMMAND_TYPE_BACKGROUND), VC_ERROR_INVALID_STATE);
 
-               ret = vc_cmd_list_destroy(list, true);
-               EXPECT_EQ(ret, VC_ERROR_NONE);
-       }
+       EXPECT_EQ(vc_deinitialize(), VC_ERROR_NONE);
 }
 
 /**
@@ -1044,23 +1139,16 @@ TEST_F(VCTest, vc_unset_command_list_p)
 /**
  * @testcase           utc_vc_unset_command_list_n
  * @since_tizen                2.4
- * @description                Negative UTC for unset command list used as candidate set (Invalid state)
+ * @description                Negative UTC for unset command list used as candidate set (Invalid parameter)
  */
-TEST_F(VCTestvc_unset_command_list_n)
+TEST_F(VCTestInReadyState, utc_vc_unset_command_list_n)
 {
        if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
-
-               int ret = VC_ERROR_NONE;
-               ret = vc_unset_command_list(VC_COMMAND_TYPE_BACKGROUND);
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
-
-               int ret = VC_ERROR_NONE;
-               ret = vc_unset_command_list(VC_COMMAND_TYPE_BACKGROUND);
-               EXPECT_EQ(ret, VC_ERROR_INVALID_STATE);
+               EXPECT_EQ(vc_unset_command_list(-1), VC_ERROR_NOT_SUPPORTED);
+               return;
        }
+
+       EXPECT_EQ(vc_unset_command_list(-1), VC_ERROR_INVALID_PARAMETER);
 }
 
 /**
@@ -1068,24 +1156,75 @@ TEST_F(VCTest, vc_unset_command_list_n)
  * @since_tizen                2.4
  * @description                Negative UTC for unset command list used as candidate set (Invalid state)
  */
-TEST_F(VCTestvc_unset_command_list_n2)
+TEST_F(VCTestInNoneState, utc_vc_unset_command_list_n2)
 {
        if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
+               EXPECT_EQ(vc_unset_command_list(VC_COMMAND_TYPE_BACKGROUND), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_unset_command_list(VC_COMMAND_TYPE_BACKGROUND);
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
+       EXPECT_EQ(vc_unset_command_list(VC_COMMAND_TYPE_BACKGROUND), VC_ERROR_INVALID_STATE);
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_deinitialize();
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+       EXPECT_EQ(vc_initialize(), VC_ERROR_NONE);
+       EXPECT_EQ(vc_unset_command_list(VC_COMMAND_TYPE_BACKGROUND), VC_ERROR_INVALID_STATE);
 
-               ret = vc_unset_command_list(VC_COMMAND_TYPE_BACKGROUND);
-               EXPECT_EQ(ret, VC_ERROR_INVALID_STATE);
+       EXPECT_EQ(vc_deinitialize(), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_set_command_list_from_file_p
+ * @since_tizen                2.4
+ * @description                Positive UTC for set command list used as candidate set from file
+ */
+TEST_F(VCTestInReadyState, utc_vc_set_command_list_from_file_p)
+{
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_set_command_list_from_file(TEST_COMMAND_JSON_PATH, VC_COMMAND_TYPE_FOREGROUND), VC_ERROR_NOT_SUPPORTED);
+               EXPECT_EQ(vc_set_command_list_from_file(TEST_COMMAND_JSON_PATH, VC_COMMAND_TYPE_BACKGROUND), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_set_invocation_name(TEST_INVOCATION_NAME), VC_ERROR_NONE);
+
+       EXPECT_EQ(vc_set_command_list_from_file(TEST_COMMAND_JSON_PATH, VC_COMMAND_TYPE_FOREGROUND), VC_ERROR_NONE);
+       EXPECT_EQ(vc_set_command_list_from_file(TEST_COMMAND_JSON_PATH, VC_COMMAND_TYPE_BACKGROUND), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_set_command_list_from_file_n
+ * @since_tizen                2.4
+ * @description                Negative UTC for set command list used as candidate set from file (Invalid parameter)
+ */
+TEST_F(VCTestInReadyState, utc_vc_set_command_list_from_file_n)
+{
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_set_command_list_from_file(TEST_COMMAND_JSON_PATH, -1), VC_ERROR_NOT_SUPPORTED);
+               EXPECT_EQ(vc_set_command_list_from_file(nullptr, VC_COMMAND_TYPE_FOREGROUND), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_set_command_list_from_file(TEST_COMMAND_JSON_PATH, -1), VC_ERROR_INVALID_PARAMETER);
+       EXPECT_EQ(vc_set_command_list_from_file(nullptr, VC_COMMAND_TYPE_FOREGROUND), VC_ERROR_INVALID_PARAMETER);
+}
+
+/**
+ * @testcase           utc_vc_set_command_list_from_file_n2
+ * @since_tizen                2.4
+ * @description                Negative UTC for set command list used as candidate set from file (Invalid state)
+ */
+TEST_F(VCTestInNoneState, utc_vc_set_command_list_from_file_n2)
+{
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_set_command_list_from_file(TEST_COMMAND_JSON_PATH, VC_COMMAND_TYPE_FOREGROUND), VC_ERROR_NOT_SUPPORTED);
+               return;
        }
+
+       EXPECT_EQ(vc_set_command_list_from_file(TEST_COMMAND_JSON_PATH, VC_COMMAND_TYPE_FOREGROUND), VC_ERROR_INVALID_STATE);
+
+       EXPECT_EQ(vc_initialize(), VC_ERROR_NONE);
+       EXPECT_EQ(vc_set_command_list_from_file(TEST_COMMAND_JSON_PATH, VC_COMMAND_TYPE_FOREGROUND), VC_ERROR_INVALID_STATE);
+
+       EXPECT_EQ(vc_deinitialize(), VC_ERROR_NONE);
 }
 
 /**
@@ -1866,6 +2005,32 @@ TEST_F(VCTest, vc_set_error_cb_p)
 }
 
 /**
+ * @testcase           utc_vc_set_error_cb_p2
+ * @since_tizen                2.4
+ * @description                Positive UTC for set error callback
+ */
+TEST_F(VCTest, utc_vc_set_error_cb_p2)
+{
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_set_error_cb(__vc_error_cb, nullptr), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_set_error_cb(__vc_error_cb, nullptr), VC_ERROR_NONE);
+
+       EXPECT_EQ(vc_prepare_sync(), VC_ERROR_NONE);
+       EXPECT_EQ(__is_state_changed(VC_STATE_READY, 5), true);
+       EXPECT_EQ(__is_service_state_changed(VC_SERVICE_STATE_READY, 5), true);
+
+       terminate_current_engine();
+
+       EXPECT_EQ(__is_error_cb_invoked(5), true);
+       EXPECT_EQ(__is_state_changed(VC_STATE_READY, 5), true);
+
+       EXPECT_EQ(vc_unprepare(), VC_ERROR_NONE);
+}
+
+/**
  * @testcase           utc_vc_set_error_cb_n
  * @since_tizen                2.4
  * @description                Negative UTC for set error callback (Invalid parameter)
@@ -2025,6 +2190,7 @@ TEST_F(VCTest, vc_unset_error_cb_n2)
        }
 }
 
+// TODO: invalid parameter TC is needed?
 /**
  * @testcase           utc_vc_set_invocation_name_p
  * @since_tizen                3.0
@@ -2055,6 +2221,9 @@ TEST_F(VCTest, vc_set_invocation_name_p)
                ret = vc_set_invocation_name(invoc_name);
                EXPECT_EQ(ret, VC_ERROR_NONE);
 
+               ret = vc_set_invocation_name(invoc_name);
+               EXPECT_EQ(ret, VC_ERROR_NONE);
+
                ret = vc_unprepare();
                EXPECT_EQ(ret, VC_ERROR_NONE);
        }
@@ -2086,6 +2255,92 @@ TEST_F(VCTest, vc_set_invocation_name_n)
 }
 
 /**
+ * @testcase           utc_vc_set_server_dialog_p
+ * @since_tizen                5.0
+ * @description                Positive UTC for setting the server dialog
+ */
+TEST_F(VCTestInReadyState, utc_vc_set_server_dialog_p)
+{
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_set_server_dialog(TEST_APP_ID, TEST_CREDENTIAL), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_set_server_dialog(TEST_APP_ID, TEST_CREDENTIAL), VC_ERROR_NONE);
+       EXPECT_EQ(vc_set_server_dialog(nullptr, TEST_CREDENTIAL), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_set_server_dialog_n
+ * @since_tizen                5.0
+ * @description                Negative UTC for setting the server dialog (Invalid parameter)
+ */
+TEST_F(VCTestInReadyState, utc_vc_set_server_dialog_n)
+{
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_set_server_dialog(TEST_APP_ID, nullptr), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_set_server_dialog(TEST_APP_ID, nullptr), VC_ERROR_INVALID_PARAMETER);
+}
+
+/**
+ * @testcase           utc_vc_set_server_dialog_n2
+ * @since_tizen                5.0
+ * @description                Negative UTC for setting the server dialog (Invalid state)
+ */
+TEST_F(VCTestInNoneState, utc_vc_set_server_dialog_n2)
+{
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_set_server_dialog(TEST_APP_ID, TEST_CREDENTIAL), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_set_server_dialog(TEST_APP_ID, TEST_CREDENTIAL), VC_ERROR_INVALID_STATE);
+
+       EXPECT_EQ(vc_initialize(), VC_ERROR_NONE);
+       EXPECT_EQ(vc_set_server_dialog(TEST_APP_ID, TEST_CREDENTIAL), VC_ERROR_INVALID_STATE);
+
+       EXPECT_EQ(vc_deinitialize(), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_unset_server_dialog_p
+ * @since_tizen                5.0
+ * @description                Positive UTC for setting the server dialog
+ */
+TEST_F(VCTestInReadyState, utc_vc_unset_server_dialog_p)
+{
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_unset_server_dialog(TEST_APP_ID), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_unset_server_dialog(TEST_APP_ID), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_unset_server_dialog_n
+ * @since_tizen                5.0
+ * @description                Negative UTC for setting the server dialog (Invalid state)
+ */
+TEST_F(VCTestInNoneState, utc_vc_unset_server_dialog_n)
+{
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_unset_server_dialog(TEST_APP_ID), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_unset_server_dialog(TEST_APP_ID), VC_ERROR_INVALID_STATE);
+
+       EXPECT_EQ(vc_initialize(), VC_ERROR_NONE);
+       EXPECT_EQ(vc_unset_server_dialog(TEST_APP_ID), VC_ERROR_INVALID_STATE);
+
+       EXPECT_EQ(vc_deinitialize(), VC_ERROR_NONE);
+}
+
+/**
  * @testcase           utc_vc_request_dialog_p
  * @since_tizen                3.0
  * @description                Positive UTC for requesting the dialog
@@ -2155,78 +2410,253 @@ TEST_F(VCTest, vc_request_dialog_n)
 }
 
 /**
- * @testcase           utc_vc_cmd_list_create_p
- * @since_tizen                2.4
- * @description                Positive UTC for create command list handle
+ * @testcase           utc_vc_tts_set_streaming_cb_p
+ * @since_tizen                5.5
+ * @description                Positive UTC for setting tts streaming callback
  */
-TEST_F(VCTest, vc_cmd_list_create_p)
+TEST_F(VCTest, utc_vc_tts_set_streaming_cb_p)
 {
        if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
-
-               int ret = VC_ERROR_NONE;
-               vc_cmd_list_h list = NULL;
-               ret = vc_cmd_list_create(&list);
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
-
-               int ret = VC_ERROR_NONE;
-               vc_cmd_list_h list = NULL;
-               ret = vc_cmd_list_create(&list);
-               EXPECT_EQ(ret, VC_ERROR_NONE);
-
-               vc_cmd_list_destroy(list, false);
+               EXPECT_EQ(vc_tts_set_streaming_cb(__vc_tts_streaming_cb, nullptr), VC_ERROR_NOT_SUPPORTED);
+               return;
        }
+
+       EXPECT_EQ(vc_tts_set_streaming_cb(__vc_tts_streaming_cb, nullptr), VC_ERROR_NONE);
 }
 
 /**
- * @testcase           utc_vc_cmd_list_create_n
- * @since_tizen                2.4
- * @description                Negative UTC for create command list handle (Invalid parameter)
+ * @testcase           utc_vc_tts_set_streaming_cb_n
+ * @since_tizen                5.5
+ * @description                Negative UTC for setting tts streaming callback (Invalid parameter)
  */
-TEST_F(VCTest, vc_cmd_list_create_n)
+TEST_F(VCTest, utc_vc_tts_set_streaming_cb_n)
 {
        if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
+               EXPECT_EQ(vc_tts_set_streaming_cb(nullptr, nullptr), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_tts_set_streaming_cb(nullptr, nullptr), VC_ERROR_INVALID_PARAMETER);
+}
+
+/**
+ * @testcase           utc_vc_tts_set_streaming_cb_n2
+ * @since_tizen                5.5
+ * @description                Negative UTC for setting tts streaming callback (Invalid state)
+ */
+TEST_F(VCTestInNoneState, utc_vc_tts_set_streaming_cb_n2)
+{
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_tts_set_streaming_cb(__vc_tts_streaming_cb, nullptr), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_tts_set_streaming_cb(__vc_tts_streaming_cb, nullptr), VC_ERROR_INVALID_STATE);
+
+       EXPECT_EQ(vc_initialize(), VC_ERROR_NONE);
+       EXPECT_EQ(vc_prepare_sync(), VC_ERROR_NONE);
+
+       EXPECT_EQ(vc_tts_set_streaming_cb(__vc_tts_streaming_cb, nullptr), VC_ERROR_INVALID_STATE);
+
+       EXPECT_EQ(vc_unprepare(), VC_ERROR_NONE);
+       EXPECT_EQ(vc_deinitialize(), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_tts_unset_streaming_cb_p
+ * @since_tizen                5.5
+ * @description                Positive UTC for unsetting tts streaming callback
+ */
+TEST_F(VCTest, utc_vc_tts_unset_streaming_cb_p)
+{
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_tts_unset_streaming_cb(), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_tts_unset_streaming_cb(), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_tts_unset_streaming_cb_n
+ * @since_tizen                5.5
+ * @description                Negative UTC for unsetting tts streaming callback (Invalid state)
+ */
+TEST_F(VCTestInNoneState, utc_vc_tts_unset_streaming_cb_n)
+{
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_tts_unset_streaming_cb(), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_tts_unset_streaming_cb(), VC_ERROR_INVALID_STATE);
+
+       EXPECT_EQ(vc_initialize(), VC_ERROR_NONE);
+       EXPECT_EQ(vc_prepare_sync(), VC_ERROR_NONE);
+
+       EXPECT_EQ(vc_tts_unset_streaming_cb(), VC_ERROR_INVALID_STATE);
+
+       EXPECT_EQ(vc_unprepare(), VC_ERROR_NONE);
+       EXPECT_EQ(vc_deinitialize(), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_tts_set_utterance_status_cb_p
+ * @since_tizen                5.5
+ * @description                Positive UTC for setting tts utterance status callback
+ */
+TEST_F(VCTest, utc_vc_tts_set_utterance_status_cb_p)
+{
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_tts_set_utterance_status_cb(__vc_tts_utterance_status_cb, nullptr), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_tts_set_utterance_status_cb(__vc_tts_utterance_status_cb, nullptr), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_tts_set_utterance_status_cb_n
+ * @since_tizen                5.5
+ * @description                Negative UTC for setting tts utterance status callback (Invalid parameter)
+ */
+TEST_F(VCTest, utc_vc_tts_set_utterance_status_cb_n)
+{
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_tts_set_utterance_status_cb(nullptr, nullptr), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_tts_set_utterance_status_cb(nullptr, nullptr), VC_ERROR_INVALID_PARAMETER);
+}
+
+/**
+ * @testcase           utc_vc_tts_set_utterance_status_cb_n2
+ * @since_tizen                5.5
+ * @description                Negative UTC for setting tts utterance status callback (Invalid state)
+ */
+TEST_F(VCTestInNoneState, utc_vc_tts_set_utterance_status_cb_n2)
+{
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_tts_set_utterance_status_cb(__vc_tts_utterance_status_cb, nullptr), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_tts_set_utterance_status_cb(__vc_tts_utterance_status_cb, nullptr), VC_ERROR_INVALID_STATE);
+
+       EXPECT_EQ(vc_initialize(), VC_ERROR_NONE);
+       EXPECT_EQ(vc_prepare_sync(), VC_ERROR_NONE);
+
+       EXPECT_EQ(vc_tts_set_utterance_status_cb(__vc_tts_utterance_status_cb, nullptr), VC_ERROR_INVALID_STATE);
+
+       EXPECT_EQ(vc_unprepare(), VC_ERROR_NONE);
+       EXPECT_EQ(vc_deinitialize(), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_tts_unset_utterance_status_cb_p
+ * @since_tizen                5.5
+ * @description                Positive UTC for unsetting tts utterance status callback
+ */
+TEST_F(VCTest, utc_vc_tts_unset_utterance_status_cb_p)
+{
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_tts_unset_utterance_status_cb(), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_tts_unset_utterance_status_cb(), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_tts_unset_utterance_status_cb_n
+ * @since_tizen                5.5
+ * @description                Negative UTC for unsetting tts utterance status callback (Invalid state)
+ */
+TEST_F(VCTestInNoneState, utc_vc_tts_unset_utterance_status_cb_n)
+{
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_tts_unset_utterance_status_cb(), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_tts_unset_utterance_status_cb(), VC_ERROR_INVALID_STATE);
+
+       EXPECT_EQ(vc_initialize(), VC_ERROR_NONE);
+       EXPECT_EQ(vc_prepare_sync(), VC_ERROR_NONE);
+
+       EXPECT_EQ(vc_tts_unset_utterance_status_cb(), VC_ERROR_INVALID_STATE);
+
+       EXPECT_EQ(vc_unprepare(), VC_ERROR_NONE);
+       EXPECT_EQ(vc_deinitialize(), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_cmd_list_create_p
+ * @since_tizen                2.4
+ * @description                Positive UTC for create command list handle
+ */
+TEST_F(VCTest, vc_cmd_list_create_p)
+{
+       if (false == g_vc_supported) {
+               EXPECT_EQ(g_vc_init, false);
 
                int ret = VC_ERROR_NONE;
-               ret = vc_cmd_list_create(NULL);
+               vc_cmd_list_h list = NULL;
+               ret = vc_cmd_list_create(&list);
                EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
        } else {
                EXPECT_EQ(g_vc_init, true);
 
                int ret = VC_ERROR_NONE;
-               ret = vc_cmd_list_create(NULL);
-               EXPECT_EQ(ret, VC_ERROR_INVALID_PARAMETER);
+               vc_cmd_list_h list = NULL;
+               ret = vc_cmd_list_create(&list);
+               EXPECT_EQ(ret, VC_ERROR_NONE);
+
+               vc_cmd_list_destroy(list, false);
        }
 }
 
 /**
- * @testcase           utc_vc_cmd_list_destroy_p
+ * @testcase           utc_vc_cmd_list_create_n
  * @since_tizen                2.4
- * @description                Positive UTC for destroy command list handle
+ * @description                Negative UTC for create command list handle (Invalid parameter)
  */
-TEST_F(VCTest, vc_cmd_list_destroy_p)
+TEST_F(VCTest, vc_cmd_list_create_n)
 {
        if (false == g_vc_supported) {
                EXPECT_EQ(g_vc_init, false);
 
                int ret = VC_ERROR_NONE;
-               vc_cmd_list_h list = NULL;
-               ret = vc_cmd_list_destroy(list, false);
+               ret = vc_cmd_list_create(NULL);
                EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
        } else {
                EXPECT_EQ(g_vc_init, true);
 
                int ret = VC_ERROR_NONE;
-               vc_cmd_list_h list = NULL;
-               ret = vc_cmd_list_create(&list);
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+               ret = vc_cmd_list_create(NULL);
+               EXPECT_EQ(ret, VC_ERROR_INVALID_PARAMETER);
+       }
+}
 
-               ret = vc_cmd_list_destroy(list, false);
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+/**
+ * @testcase           utc_vc_cmd_list_destroy_p
+ * @since_tizen                2.4
+ * @description                Positive UTC for destroy command list handle
+ */
+TEST_F(VCTest, vc_cmd_list_destroy_p)
+{
+       vc_cmd_list_h list = nullptr;
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_cmd_list_destroy(list, false), VC_ERROR_NOT_SUPPORTED);
+               return;
        }
+
+       EXPECT_EQ(vc_cmd_list_create(&list), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_list_destroy(list, false), VC_ERROR_NONE);
+
+       EXPECT_EQ(vc_cmd_list_create(&list), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_list_destroy(list, true), VC_ERROR_NONE);
 }
 
 /**
@@ -2258,28 +2688,26 @@ TEST_F(VCTest, vc_cmd_list_destroy_n)
  */
 TEST_F(VCTest, vc_cmd_list_get_count_p)
 {
+       vc_cmd_list_h list = nullptr;
+       int cnt = -1;
        if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
+               EXPECT_EQ(vc_cmd_list_get_count(list, &cnt), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
 
-               int ret = VC_ERROR_NONE;
-               vc_cmd_list_h list = NULL;
-               int cnt = -1;
-               ret = vc_cmd_list_get_count(list, &cnt);
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
+       EXPECT_EQ(vc_cmd_list_create(&list), VC_ERROR_NONE);
 
-               int ret = VC_ERROR_NONE;
-               vc_cmd_list_h list = NULL;
-               ret = vc_cmd_list_create(&list);
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_list_get_count(list, &cnt), VC_ERROR_NONE);
+       EXPECT_EQ(cnt, 0);
 
-               int cnt = -1;
-               ret = vc_cmd_list_get_count(list, &cnt);
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+       vc_cmd_h command = nullptr;
+       EXPECT_EQ(vc_cmd_create(&command), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_list_add(list, command), VC_ERROR_NONE);
 
-               vc_cmd_list_destroy(list, false);
-       }
+       EXPECT_EQ(vc_cmd_list_get_count(list, &cnt), VC_ERROR_NONE);
+       EXPECT_EQ(cnt, 1);
+
+       EXPECT_EQ(vc_cmd_list_destroy(list, true), VC_ERROR_NONE);
 }
 
 /**
@@ -2289,19 +2717,19 @@ TEST_F(VCTest, vc_cmd_list_get_count_p)
  */
 TEST_F(VCTest, vc_cmd_list_get_count_n)
 {
+       vc_cmd_list_h list = nullptr;
+       int cnt = 0;
        if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
+               EXPECT_EQ(vc_cmd_list_get_count(nullptr, &cnt), VC_ERROR_NOT_SUPPORTED);
+               EXPECT_EQ(vc_cmd_list_get_count(list, nullptr), VC_ERROR_NOT_SUPPORTED);
+       }
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_cmd_list_get_count(NULL, NULL);
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
+       EXPECT_EQ(vc_cmd_list_create(&list), VC_ERROR_NONE);
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_cmd_list_get_count(NULL, NULL);
-               EXPECT_EQ(ret, VC_ERROR_INVALID_PARAMETER);
-       }
+       EXPECT_EQ(vc_cmd_list_get_count(nullptr, &cnt), VC_ERROR_INVALID_PARAMETER);
+       EXPECT_EQ(vc_cmd_list_get_count(list, nullptr), VC_ERROR_INVALID_PARAMETER);
+
+       EXPECT_EQ(vc_cmd_list_destroy(list, false), VC_ERROR_NONE);
 }
 
 /**
@@ -2345,19 +2773,21 @@ TEST_F(VCTest, vc_cmd_list_add_p)
  */
 TEST_F(VCTest, vc_cmd_list_add_n)
 {
+       vc_cmd_list_h list = nullptr;
+       vc_cmd_h cmd = nullptr;
        if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
+               EXPECT_EQ(vc_cmd_list_add(list, nullptr), VC_ERROR_NOT_SUPPORTED);
+               EXPECT_EQ(vc_cmd_list_add(nullptr, cmd), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_cmd_list_add(NULL, NULL);
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
+       EXPECT_EQ(vc_cmd_list_create(&list), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_create(&cmd), VC_ERROR_NONE);
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_cmd_list_add(NULL, NULL);
-               EXPECT_EQ(ret, VC_ERROR_INVALID_PARAMETER);
-       }
+       EXPECT_EQ(vc_cmd_list_add(list, nullptr), VC_ERROR_INVALID_PARAMETER);
+       EXPECT_EQ(vc_cmd_list_add(nullptr, cmd), VC_ERROR_INVALID_PARAMETER);
+
+       EXPECT_EQ(vc_cmd_list_destroy(list, true), VC_ERROR_NONE);
 }
 
 /**
@@ -2404,19 +2834,79 @@ TEST_F(VCTest, vc_cmd_list_remove_p)
  */
 TEST_F(VCTest, vc_cmd_list_remove_n)
 {
+       vc_cmd_list_h list = nullptr;
+       vc_cmd_h cmd = nullptr;
        if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
+               EXPECT_EQ(vc_cmd_list_remove(list, nullptr), VC_ERROR_NOT_SUPPORTED);
+               EXPECT_EQ(vc_cmd_list_remove(nullptr, cmd), VC_ERROR_NOT_SUPPORTED);
+               EXPECT_EQ(vc_cmd_list_remove(list, cmd), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_cmd_list_remove(NULL, NULL);
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
+       EXPECT_EQ(vc_cmd_list_create(&list), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_create(&cmd), VC_ERROR_NONE);
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_cmd_list_remove(NULL, NULL);
-               EXPECT_EQ(ret, VC_ERROR_INVALID_PARAMETER);
+       EXPECT_EQ(vc_cmd_list_remove(list, nullptr), VC_ERROR_INVALID_PARAMETER);
+       EXPECT_EQ(vc_cmd_list_remove(nullptr, cmd), VC_ERROR_INVALID_PARAMETER);
+       EXPECT_EQ(vc_cmd_list_remove(list, cmd), VC_ERROR_INVALID_PARAMETER);
+
+       EXPECT_EQ(vc_cmd_list_destroy(list, false), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_destroy(cmd), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_cmd_list_remove_all_p
+ * @since_tizen                2.4
+ * @description                Positive UTC for destroy command list handle
+ */
+TEST_F(VCTest, utc_vc_cmd_list_remove_all_p)
+{
+       vc_cmd_list_h list = nullptr;
+       vc_cmd_h cmd = nullptr;
+       int cnt = -1;
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_cmd_list_remove_all(list, false), VC_ERROR_NOT_SUPPORTED);
+               EXPECT_EQ(vc_cmd_list_remove_all(list, true), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_cmd_list_create(&list), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_create(&cmd), VC_ERROR_NONE);
+
+       EXPECT_EQ(vc_cmd_list_add(list, cmd), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_list_get_count(list, &cnt), VC_ERROR_NONE);
+       EXPECT_EQ(cnt, 1);
+
+       EXPECT_EQ(vc_cmd_list_remove_all(list, false), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_list_get_count(list, &cnt), VC_ERROR_NONE);
+       EXPECT_EQ(cnt, 0);
+
+       EXPECT_EQ(vc_cmd_list_add(list, cmd), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_list_get_count(list, &cnt), VC_ERROR_NONE);
+       EXPECT_EQ(cnt, 1);
+
+       EXPECT_EQ(vc_cmd_list_remove_all(list, true), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_list_get_count(list, &cnt), VC_ERROR_NONE);
+       EXPECT_EQ(cnt, 0);
+
+       EXPECT_EQ(vc_cmd_list_destroy(list, false), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_cmd_list_remove_all_n
+ * @since_tizen                2.4
+ * @description                Negative UTC for destroy command list handle (invalid parameter)
+ */
+TEST_F(VCTest, utc_vc_cmd_list_remove_all_n)
+{
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_cmd_list_remove_all(nullptr, false), VC_ERROR_NOT_SUPPORTED);
+               EXPECT_EQ(vc_cmd_list_remove_all(nullptr, true), VC_ERROR_NOT_SUPPORTED);
+               return;
        }
+
+       EXPECT_EQ(vc_cmd_list_remove_all(nullptr, false), VC_ERROR_INVALID_PARAMETER);
+       EXPECT_EQ(vc_cmd_list_remove_all(nullptr, true), VC_ERROR_INVALID_PARAMETER);
 }
 
 /**
@@ -2462,19 +2952,70 @@ TEST_F(VCTest, vc_cmd_list_foreach_commands_p)
  */
 TEST_F(VCTest, vc_cmd_list_foreach_commands_n)
 {
+       vc_cmd_list_h list = nullptr;
+       vc_cmd_h cmd = nullptr;
        if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
+               EXPECT_EQ(vc_cmd_list_foreach_commands(list, nullptr, nullptr), VC_ERROR_NOT_SUPPORTED);
+               EXPECT_EQ(vc_cmd_list_foreach_commands(nullptr, __vc_cmd_list_cb, nullptr), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_cmd_list_foreach_commands(NULL, NULL, NULL);
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
+       EXPECT_EQ(vc_cmd_list_create(&list), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_create(&cmd), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_list_add(list, cmd), VC_ERROR_NONE);
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_cmd_list_foreach_commands(NULL, NULL, NULL);
-               EXPECT_EQ(ret, VC_ERROR_INVALID_PARAMETER);
+       EXPECT_EQ(vc_cmd_list_foreach_commands(list, nullptr, nullptr), VC_ERROR_INVALID_PARAMETER);
+       EXPECT_EQ(vc_cmd_list_foreach_commands(nullptr, __vc_cmd_list_cb, nullptr), VC_ERROR_INVALID_PARAMETER);
+
+       EXPECT_EQ(vc_cmd_list_destroy(list, true), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_cmd_list_filter_by_type_p
+ * @since_tizen                3.0
+ * @description                Positive UTC for get filtered command list by type
+ */
+TEST_F(VCTest, utc_vc_cmd_list_filter_by_type_p)
+{
+       vc_cmd_list_h list = nullptr;
+       int cnt = -1;
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_cmd_list_filter_by_type(g_test_commands, VC_COMMAND_TYPE_FOREGROUND, &list), VC_ERROR_NOT_SUPPORTED);
+               EXPECT_EQ(vc_cmd_list_filter_by_type(g_test_commands, VC_COMMAND_TYPE_BACKGROUND, &list), VC_ERROR_NOT_SUPPORTED);
+               return;
        }
+
+       EXPECT_EQ(vc_cmd_list_filter_by_type(g_test_commands, VC_COMMAND_TYPE_FOREGROUND, &list), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_list_get_count(list, &cnt), VC_ERROR_NONE);
+       EXPECT_EQ(cnt, 1);
+       EXPECT_EQ(vc_cmd_list_destroy(list, true), VC_ERROR_NONE);
+       list = nullptr;
+
+       EXPECT_EQ(vc_cmd_list_filter_by_type(g_test_commands, VC_COMMAND_TYPE_BACKGROUND, &list), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_list_get_count(list, &cnt), VC_ERROR_NONE);
+       EXPECT_EQ(cnt, 0);
+       EXPECT_EQ(vc_cmd_list_destroy(list, true), VC_ERROR_NONE);
+       list = nullptr;
+}
+
+/**
+ * @testcase           utc_vc_cmd_list_filter_by_type_n
+ * @since_tizen                3.0
+ * @description                Negative UTC for get filtered command list by type (invalid parameter)
+ */
+TEST_F(VCTest, utc_vc_cmd_list_filter_by_type_n)
+{
+       vc_cmd_list_h list = nullptr;
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_cmd_list_filter_by_type(nullptr, VC_COMMAND_TYPE_FOREGROUND, &list), VC_ERROR_NOT_SUPPORTED);
+               EXPECT_EQ(vc_cmd_list_filter_by_type(g_test_commands, -1, &list), VC_ERROR_NOT_SUPPORTED);
+               EXPECT_EQ(vc_cmd_list_filter_by_type(g_test_commands, VC_COMMAND_TYPE_FOREGROUND, nullptr), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_cmd_list_filter_by_type(nullptr, VC_COMMAND_TYPE_FOREGROUND, &list), VC_ERROR_INVALID_PARAMETER);
+       EXPECT_EQ(vc_cmd_list_filter_by_type(g_test_commands, -1, &list), VC_ERROR_INVALID_PARAMETER);
+       EXPECT_EQ(vc_cmd_list_filter_by_type(g_test_commands, VC_COMMAND_TYPE_FOREGROUND, nullptr), VC_ERROR_INVALID_PARAMETER);
 }
 
 /**
@@ -2536,6 +3077,25 @@ TEST_F(VCTest, vc_cmd_list_first_n)
 }
 
 /**
+ * @testcase           utc_vc_cmd_list_first_n2
+ * @since_tizen                2.4
+ * @description                Negative UTC for move pointer to the first of command list (Empty list)
+ */
+TEST_F(VCTest, utc_vc_cmd_list_first_n2)
+{
+       vc_cmd_list_h list = nullptr;
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_cmd_list_first(list), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_cmd_list_create(&list), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_list_first(list), VC_ERROR_EMPTY);
+
+       EXPECT_EQ(vc_cmd_list_destroy(list, true), VC_ERROR_NONE);
+}
+
+/**
  * @testcase           utc_vc_cmd_list_last_p
  * @since_tizen                2.4
  * @description                Positive UTC for move pointer to the last of command list
@@ -2594,6 +3154,25 @@ TEST_F(VCTest, vc_cmd_list_last_n)
 }
 
 /**
+ * @testcase           utc_vc_cmd_list_last_n2
+ * @since_tizen                2.4
+ * @description                Negative UTC for move pointer to the last of command list (Empty list)
+ */
+TEST_F(VCTest, utc_vc_cmd_list_last_n2)
+{
+       vc_cmd_list_h list = nullptr;
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_cmd_list_last(list), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_cmd_list_create(&list), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_list_last(list), VC_ERROR_EMPTY);
+
+       EXPECT_EQ(vc_cmd_list_destroy(list, true), VC_ERROR_NONE);
+}
+
+/**
  * @testcase           utc_vc_cmd_list_next_p
  * @since_tizen                2.4
  * @description                Positive UTC for move pointer to next command in command list
@@ -2658,6 +3237,48 @@ TEST_F(VCTest, vc_cmd_list_next_n)
 }
 
 /**
+ * @testcase           utc_vc_cmd_list_next_n2
+ * @since_tizen                2.4
+ * @description                Negative UTC for move pointer to next command in command list (Empty list)
+ */
+TEST_F(VCTest, utc_vc_cmd_list_next_n2)
+{
+       vc_cmd_list_h list = nullptr;
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_cmd_list_last(list), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_cmd_list_create(&list), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_list_next(list), VC_ERROR_EMPTY);
+
+       EXPECT_EQ(vc_cmd_list_destroy(list, true), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_cmd_list_next_n3
+ * @since_tizen                2.4
+ * @description                Negative UTC for move pointer to next command in command list (Iteration end)
+ */
+TEST_F(VCTest, utc_vc_cmd_list_next_n3)
+{
+       vc_cmd_list_h list = nullptr;
+       vc_cmd_h cmd = nullptr;
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_cmd_list_next(list), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_cmd_list_create(&list), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_create(&cmd), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_list_add(list, cmd), VC_ERROR_NONE);
+
+       EXPECT_EQ(vc_cmd_list_next(list), VC_ERROR_ITERATION_END);
+
+       EXPECT_EQ(vc_cmd_list_destroy(list, true), VC_ERROR_NONE);
+}
+
+/**
  * @testcase           utc_vc_cmd_list_prev_p
  * @since_tizen                2.4
  * @description                Positive UTC for move pointer to previous command in command list
@@ -2722,6 +3343,48 @@ TEST_F(VCTest, vc_cmd_list_prev_n)
 }
 
 /**
+ * @testcase           utc_vc_cmd_list_prev_n2
+ * @since_tizen                2.4
+ * @description                Negative UTC for move pointer to next command in command list (Empty list)
+ */
+TEST_F(VCTest, utc_vc_cmd_list_prev_n2)
+{
+       vc_cmd_list_h list = nullptr;
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_cmd_list_prev(list), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_cmd_list_create(&list), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_list_prev(list), VC_ERROR_EMPTY);
+
+       EXPECT_EQ(vc_cmd_list_destroy(list, true), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_cmd_list_prev_n3
+ * @since_tizen                2.4
+ * @description                Negative UTC for move pointer to next command in command list (Iteration end)
+ */
+TEST_F(VCTest, utc_vc_cmd_list_prev_n3)
+{
+       vc_cmd_list_h list = nullptr;
+       vc_cmd_h cmd = nullptr;
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_cmd_list_prev(list), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_cmd_list_create(&list), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_create(&cmd), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_list_add(list, cmd), VC_ERROR_NONE);
+
+       EXPECT_EQ(vc_cmd_list_prev(list), VC_ERROR_ITERATION_END);
+
+       EXPECT_EQ(vc_cmd_list_destroy(list, true), VC_ERROR_NONE);
+}
+
+/**
  * @testcase           utc_vc_cmd_list_get_current_p
  * @since_tizen                2.4
  * @description                Positive UTC for get command handle of current pointer
@@ -2769,19 +3432,36 @@ TEST_F(VCTest, vc_cmd_list_get_current_p)
  */
 TEST_F(VCTest, vc_cmd_list_get_current_n)
 {
+       vc_cmd_list_h list = nullptr;
+       vc_cmd_h cmd = nullptr;
        if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
+               EXPECT_EQ(vc_cmd_list_get_current(list, &cmd), VC_ERROR_NOT_SUPPORTED);
+               EXPECT_EQ(vc_cmd_list_get_current(list, &cmd), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_cmd_list_get_current(NULL, NULL);
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
+       EXPECT_EQ(vc_cmd_list_get_current(nullptr, &cmd), VC_ERROR_INVALID_PARAMETER);
+       EXPECT_EQ(vc_cmd_list_get_current(list, nullptr), VC_ERROR_INVALID_PARAMETER);
+}
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_cmd_list_get_current(NULL, NULL);
-               EXPECT_EQ(ret, VC_ERROR_INVALID_PARAMETER);
+/**
+ * @testcase           utc_vc_cmd_list_get_current_n2
+ * @since_tizen                2.4
+ * @description                Negative UTC for get command handle of current pointer (Empty list)
+ */
+TEST_F(VCTest, utc_vc_cmd_list_get_current_n2)
+{
+       vc_cmd_list_h list = nullptr;
+       vc_cmd_h cmd = nullptr;
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_cmd_list_get_current(list, &cmd), VC_ERROR_NOT_SUPPORTED);
+               return;
        }
+
+       EXPECT_EQ(vc_cmd_list_create(&list), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_list_get_current(list, &cmd), VC_ERROR_EMPTY);
+
+       EXPECT_EQ(vc_cmd_list_destroy(list, true), VC_ERROR_NONE);
 }
 
 /**
@@ -2864,21 +3544,20 @@ TEST_F(VCTest, vc_cmd_destroy_p)
  * @since_tizen                2.4
  * @description                Negative UTC for destroy command handle (Invalid parameter)
  */
-TEST_F(VCTest, vc_cmd_destroy_n)
+TEST_F(VCTest, utc_vc_cmd_destroy_n)
 {
+       vc_cmd_h cmd = nullptr;
        if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
+               EXPECT_EQ(vc_cmd_destroy(nullptr), VC_ERROR_NOT_SUPPORTED);
+               EXPECT_EQ(vc_cmd_destroy(cmd), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_cmd_destroy(NULL);
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
+       EXPECT_EQ(vc_cmd_destroy(nullptr), VC_ERROR_INVALID_PARAMETER);
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_cmd_destroy(NULL);
-               EXPECT_EQ(ret, VC_ERROR_INVALID_PARAMETER);
-       }
+       EXPECT_EQ(vc_cmd_create(&cmd), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_destroy(cmd), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_destroy(cmd), VC_ERROR_INVALID_PARAMETER);
 }
 
 /**
@@ -2906,6 +3585,9 @@ TEST_F(VCTest, vc_cmd_set_command_p)
                ret = vc_cmd_set_command(cmd, "voice");
                EXPECT_EQ(ret, VC_ERROR_NONE);
 
+               ret = vc_cmd_set_command(cmd, "voice");
+               EXPECT_EQ(ret, VC_ERROR_NONE);
+
                vc_cmd_destroy(cmd);
        }
 }
@@ -2937,41 +3619,27 @@ TEST_F(VCTest, vc_cmd_set_command_n)
  * @since_tizen                2.4
  * @description                Positive UTC for get command text in handle
  */
-TEST_F(VCTest, vc_cmd_get_command_p)
+TEST_F(VCTest, utc_vc_cmd_get_command_p)
 {
+       const char *command_text = "voice";
+       vc_cmd_h cmd = nullptr;
+       char *text = nullptr;
        if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
-
-               int ret = VC_ERROR_NONE;
-               vc_cmd_h cmd = NULL;
-               char *text = NULL;
-               ret = vc_cmd_get_command(cmd, &text);
-               if (NULL != text) {
-                               free(text);
-                               text = NULL;
-               }
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
+               EXPECT_EQ(vc_cmd_get_command(cmd, &text), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
 
-               int ret = VC_ERROR_NONE;
-               vc_cmd_h cmd = NULL;
-               ret = vc_cmd_create(&cmd);
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_create(&cmd), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_get_command(cmd, &text), VC_ERROR_NONE);
+       EXPECT_EQ(text, nullptr);
 
-               ret = vc_cmd_set_command(cmd, "voice");
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_set_command(cmd, command_text), VC_ERROR_NONE);
 
-               char *text = NULL;
-               ret = vc_cmd_get_command(cmd, &text);
-               if (NULL != text) {
-                               free(text);
-                               text = NULL;
-               }
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_get_command(cmd, &text), VC_ERROR_NONE);
+       EXPECT_STREQ(text, command_text);
+       free(text);
 
-               vc_cmd_destroy(cmd);
-       }
+       EXPECT_EQ(vc_cmd_destroy(cmd), VC_ERROR_NONE);
 }
 
 /**
@@ -2997,45 +3665,75 @@ TEST_F(VCTest, vc_cmd_get_command_n)
 }
 
 /**
+ * @testcase           utc_vc_cmd_set_unfixed_command_p
+ * @since_tizen                2.4
+ * @description                Positive UTC for setting the unfixed command text in handle
+ */
+TEST_F(VCTest, utc_vc_cmd_set_unfixed_command_p)
+{
+       const char *command_text = "voice";
+       vc_cmd_h cmd = nullptr;
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_cmd_set_unfixed_command(cmd, command_text), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_cmd_create(&cmd), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_set_unfixed_command(cmd, command_text), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_set_unfixed_command(cmd, command_text), VC_ERROR_NONE);
+
+       EXPECT_EQ(vc_cmd_destroy(cmd), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_cmd_set_unfixed_command_n
+ * @since_tizen                2.4
+ * @description                Negative UTC for setting the unfixed command text in handle (Invalid parameter)
+ */
+TEST_F(VCTest, utc_vc_cmd_set_unfixed_command_n)
+{
+       const char *command_text = "voice";
+       vc_cmd_h cmd = nullptr;
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_cmd_set_unfixed_command(nullptr, command_text), VC_ERROR_NOT_SUPPORTED);
+               EXPECT_EQ(vc_cmd_set_unfixed_command(cmd, nullptr), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_cmd_create(&cmd), VC_ERROR_NONE);
+
+       EXPECT_EQ(vc_cmd_set_unfixed_command(nullptr, command_text), VC_ERROR_INVALID_PARAMETER);
+       EXPECT_EQ(vc_cmd_set_unfixed_command(cmd, nullptr), VC_ERROR_INVALID_PARAMETER);
+
+       EXPECT_EQ(vc_cmd_destroy(cmd), VC_ERROR_NONE);
+}
+
+/**
  * @testcase           utc_vc_cmd_get_unfixed_command_p
  * @since_tizen                3.0
  * @description                Positive UTC for getting the unfixed command text in handle
  */
 TEST_F(VCTest, vc_cmd_get_unfixed_command_p)
 {
+       const char *command_text = "voice";
+       vc_cmd_h cmd = nullptr;
+       char *text = nullptr;
        if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
-
-               int ret = VC_ERROR_NONE;
-               vc_cmd_h cmd = NULL;
-               char *text = NULL;
-               ret = vc_cmd_create(&cmd);
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
+               EXPECT_EQ(vc_cmd_get_unfixed_command(cmd, &text), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
 
-               ret = vc_cmd_get_unfixed_command(cmd, &text);
-               if (NULL != text) {
-                       free(text);
-                       text = NULL;
-               }
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
+       EXPECT_EQ(vc_cmd_create(&cmd), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_get_unfixed_command(cmd, &text), VC_ERROR_NONE);
+       EXPECT_EQ(text, nullptr);
 
-               int ret = VC_ERROR_NONE;
-               vc_cmd_h cmd = NULL;
-               ret = vc_cmd_create(&cmd);
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_set_unfixed_command(cmd, command_text), VC_ERROR_NONE);
 
-               char *text = NULL;
-               ret = vc_cmd_get_unfixed_command(cmd, &text);
-               if (NULL != text) {
-                       free(text);
-                       text = NULL;
-               }
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_get_unfixed_command(cmd, &text), VC_ERROR_NONE);
+       EXPECT_STREQ(text, command_text);
+       free(text);
 
-               vc_cmd_destroy(cmd);
-       }
+       EXPECT_EQ(vc_cmd_destroy(cmd), VC_ERROR_NONE);
 }
 
 /**
@@ -3094,21 +3792,21 @@ TEST_F(VCTest, vc_cmd_set_type_p)
  * @since_tizen                2.4
  * @description                Negative UTC for set command type in handle (Invalid parameter)
  */
-TEST_F(VCTest, vc_cmd_set_type_n)
+TEST_F(VCTest, utc_vc_cmd_set_type_n)
 {
+       vc_cmd_h cmd = nullptr;
        if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
+               EXPECT_EQ(vc_cmd_set_type(nullptr, VC_COMMAND_TYPE_FOREGROUND), VC_ERROR_NOT_SUPPORTED);
+               EXPECT_EQ(vc_cmd_set_type(cmd, -1), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_cmd_set_type(NULL, VC_COMMAND_TYPE_BACKGROUND);
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
+       EXPECT_EQ(vc_cmd_create(&cmd), VC_ERROR_NONE);
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_cmd_set_type(NULL, VC_COMMAND_TYPE_BACKGROUND);
-               EXPECT_EQ(ret, VC_ERROR_INVALID_PARAMETER);
-       }
+       EXPECT_EQ(vc_cmd_set_type(nullptr, VC_COMMAND_TYPE_FOREGROUND), VC_ERROR_INVALID_PARAMETER);
+       EXPECT_EQ(vc_cmd_set_type(cmd, -1), VC_ERROR_INVALID_PARAMETER);
+
+       EXPECT_EQ(vc_cmd_destroy(cmd), VC_ERROR_NONE);
 }
 
 /**
@@ -3116,33 +3814,22 @@ TEST_F(VCTest, vc_cmd_set_type_n)
  * @since_tizen                2.4
  * @description                Positive UTC for get command type in handle
  */
-TEST_F(VCTest, vc_cmd_get_type_p)
+TEST_F(VCTest, utc_vc_cmd_get_type_p)
 {
+       vc_cmd_h cmd = nullptr;
+       int type = -1;
        if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
-
-               int ret = VC_ERROR_NONE;
-               vc_cmd_h cmd = NULL;
-               int type;
-               ret = vc_cmd_get_type(cmd, &type);
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
-
-               int ret = VC_ERROR_NONE;
-               vc_cmd_h cmd = NULL;
-               ret = vc_cmd_create(&cmd);
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+               EXPECT_EQ(vc_cmd_get_type(cmd, &type), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
 
-               ret = vc_cmd_set_type(cmd, VC_COMMAND_TYPE_BACKGROUND);
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_create(&cmd), VC_ERROR_NONE);
 
-               int type;
-               ret = vc_cmd_get_type(cmd, &type);
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_set_type(cmd, VC_COMMAND_TYPE_BACKGROUND), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_get_type(cmd, &type), VC_ERROR_NONE);
+       EXPECT_EQ(type, VC_COMMAND_TYPE_BACKGROUND);
 
-               vc_cmd_destroy(cmd);
-       }
+       EXPECT_EQ(vc_cmd_destroy(cmd), VC_ERROR_NONE);
 }
 
 /**
@@ -3206,21 +3893,21 @@ TEST_F(VCTest, vc_cmd_set_format_p)
  * @since_tizen                3.0
  * @description                Negative UTC for setting command format in handle (Invalid parameter)
  */
-TEST_F(VCTest, vc_cmd_set_format_n)
+TEST_F(VCTest, utc_vc_cmd_set_format_n)
 {
+       vc_cmd_h cmd = nullptr;
        if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
+               EXPECT_EQ(vc_cmd_set_format(nullptr, VC_COMMAND_FORMAT_FIXED), VC_ERROR_NOT_SUPPORTED);
+               EXPECT_EQ(vc_cmd_set_format(cmd, -1), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_cmd_set_format(NULL, VC_COMMAND_FORMAT_FIXED);
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
+       EXPECT_EQ(vc_cmd_create(&cmd), VC_ERROR_NONE);
 
-               int ret = VC_ERROR_NONE;
-               ret = vc_cmd_set_format(NULL, VC_COMMAND_FORMAT_FIXED);
-               EXPECT_EQ(ret, VC_ERROR_INVALID_PARAMETER);
-       }
+       EXPECT_EQ(vc_cmd_set_format(nullptr, VC_COMMAND_FORMAT_FIXED), VC_ERROR_INVALID_PARAMETER);
+       EXPECT_EQ(vc_cmd_set_format(cmd, -1), VC_ERROR_INVALID_PARAMETER);
+
+       EXPECT_EQ(vc_cmd_destroy(cmd), VC_ERROR_NONE);
 }
 
 /**
@@ -3228,33 +3915,22 @@ TEST_F(VCTest, vc_cmd_set_format_n)
  * @since_tizen                3.0
  * @description                Positive UTC for getting command format in handle
  */
-TEST_F(VCTest, vc_cmd_get_format_p)
+TEST_F(VCTest, utc_vc_cmd_get_format_p)
 {
+       vc_cmd_h cmd = nullptr;
+       int type = -1;
        if (false == g_vc_supported) {
-               EXPECT_EQ(g_vc_init, false);
-
-               int ret = VC_ERROR_NONE;
-               vc_cmd_h cmd = NULL;
-               int format;
-               ret = vc_cmd_get_format(cmd, &format);
-               EXPECT_EQ(ret, VC_ERROR_NOT_SUPPORTED);
-       } else {
-               EXPECT_EQ(g_vc_init, true);
-
-               int ret = VC_ERROR_NONE;
-               vc_cmd_h cmd = NULL;
-               ret = vc_cmd_create(&cmd);
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+               EXPECT_EQ(vc_cmd_get_format(cmd, &type), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
 
-               ret = vc_cmd_set_format(cmd, VC_COMMAND_FORMAT_FIXED);
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_create(&cmd), VC_ERROR_NONE);
 
-               int format;
-               ret = vc_cmd_get_format(cmd, &format);
-               EXPECT_EQ(ret, VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_set_format(cmd, VC_CMD_FORMAT_FIXED_AND_NONFIXED), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_get_format(cmd, &type), VC_ERROR_NONE);
+       EXPECT_EQ(type, VC_CMD_FORMAT_FIXED_AND_NONFIXED);
 
-               vc_cmd_destroy(cmd);
-       }
+       EXPECT_EQ(vc_cmd_destroy(cmd), VC_ERROR_NONE);
 }
 
 /**
@@ -3279,4 +3955,180 @@ TEST_F(VCTest, vc_cmd_get_format_n)
        }
 }
 
+/**
+ * @testcase           utc_vc_cmd_set_pid_p
+ * @since_tizen                3.0
+ * @description                Positive UTC for setting pid in handle
+ */
+TEST_F(VCTest, utc_vc_cmd_set_pid_p)
+{
+       vc_cmd_h cmd = nullptr;
+       int pid = getpid();
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_cmd_set_pid(cmd, pid), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_cmd_create(&cmd), VC_ERROR_NONE);
+
+       EXPECT_EQ(vc_cmd_set_pid(cmd, pid), VC_ERROR_NONE);
+
+       EXPECT_EQ(vc_cmd_destroy(cmd), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_cmd_set_pid_n
+ * @since_tizen                3.0
+ * @description                Negative UTC for setting pid in handle (Invalid handle)
+ */
+TEST_F(VCTest, utc_vc_cmd_set_pid_n)
+{
+       vc_cmd_h cmd = nullptr;
+       int pid = getpid();
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_cmd_set_pid(nullptr, pid), VC_ERROR_NOT_SUPPORTED);
+               EXPECT_EQ(vc_cmd_set_pid(cmd, -1), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_cmd_create(&cmd), VC_ERROR_NONE);
+
+       EXPECT_EQ(vc_cmd_set_pid(nullptr, pid), VC_ERROR_INVALID_PARAMETER);
+       EXPECT_EQ(vc_cmd_set_pid(cmd, -1), VC_ERROR_INVALID_PARAMETER);
+
+       EXPECT_EQ(vc_cmd_destroy(cmd), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_cmd_get_pid_p
+ * @since_tizen                3.0
+ * @description                Positive UTC for getting pid format in handle
+ */
+TEST_F(VCTest, utc_vc_cmd_get_pid_p)
+{
+       vc_cmd_h cmd = nullptr;
+       int pid = -1;
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_cmd_get_pid(cmd, &pid), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_cmd_create(&cmd), VC_ERROR_NONE);
+
+       EXPECT_EQ(vc_cmd_set_pid(cmd, getpid()), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_get_pid(cmd, &pid), VC_ERROR_NONE);
+       EXPECT_EQ(pid, getpid());
+
+       EXPECT_EQ(vc_cmd_destroy(cmd), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_cmd_get_pid_n
+ * @since_tizen                3.0
+ * @description                Positive UTC for getting pid format in handle
+ */
+TEST_F(VCTest, utc_vc_cmd_get_pid_n)
+{
+       vc_cmd_h cmd = nullptr;
+       int pid = -1;
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_cmd_get_pid(nullptr, &pid), VC_ERROR_NOT_SUPPORTED);
+               EXPECT_EQ(vc_cmd_get_pid(cmd, nullptr), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_cmd_create(&cmd), VC_ERROR_NONE);
+
+       EXPECT_EQ(vc_cmd_get_pid(nullptr, &pid), VC_ERROR_INVALID_PARAMETER);
+       EXPECT_EQ(vc_cmd_get_pid(cmd, nullptr), VC_ERROR_INVALID_PARAMETER);
+
+       EXPECT_EQ(vc_cmd_destroy(cmd), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_cmd_set_domain_p
+ * @since_tizen                3.0
+ * @description                Positive UTC for setting command domain in handle
+ */
+TEST_F(VCTest, utc_vc_cmd_set_domain_p)
+{
+       vc_cmd_h cmd = nullptr;
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_cmd_set_domain(cmd, 1), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_cmd_create(&cmd), VC_ERROR_NONE);
+
+       EXPECT_EQ(vc_cmd_set_domain(cmd, 1), VC_ERROR_NONE);
+
+       EXPECT_EQ(vc_cmd_destroy(cmd), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_cmd_set_domain_n
+ * @since_tizen                3.0
+ * @description                Negative UTC for setting command domain in handle (Invalid parameter)
+ */
+TEST_F(VCTest, utc_vc_cmd_set_domain_n)
+{
+       vc_cmd_h cmd = nullptr;
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_cmd_set_domain(nullptr, 1), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_cmd_create(&cmd), VC_ERROR_NONE);
+
+       EXPECT_EQ(vc_cmd_set_domain(nullptr, 1), VC_ERROR_INVALID_PARAMETER);
+
+       EXPECT_EQ(vc_cmd_destroy(cmd), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_cmd_get_domain_p
+ * @since_tizen                3.0
+ * @description                Positive UTC for getting command domain in handle
+ */
+TEST_F(VCTest, utc_vc_cmd_get_domain_p)
+{
+       vc_cmd_h cmd = nullptr;
+       int domain = -1;
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_cmd_get_domain(cmd, &domain), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_cmd_create(&cmd), VC_ERROR_NONE);
+
+       EXPECT_EQ(vc_cmd_set_domain(cmd, 1), VC_ERROR_NONE);
+       EXPECT_EQ(vc_cmd_get_domain(cmd, &domain), VC_ERROR_NONE);
+       EXPECT_EQ(domain, 1);
+
+       EXPECT_EQ(vc_cmd_destroy(cmd), VC_ERROR_NONE);
+}
+
+/**
+ * @testcase           utc_vc_cmd_get_domain_n
+ * @since_tizen                3.0
+ * @description                Negative UTC for getting command domain in handle (Invalid parameter)
+ */
+TEST_F(VCTest, utc_vc_cmd_get_domain_n)
+{
+       vc_cmd_h cmd = nullptr;
+       int domain = -1;
+       if (false == g_vc_supported) {
+               EXPECT_EQ(vc_cmd_get_domain(nullptr, &domain), VC_ERROR_NOT_SUPPORTED);
+               EXPECT_EQ(vc_cmd_get_domain(cmd, nullptr), VC_ERROR_NOT_SUPPORTED);
+               return;
+       }
+
+       EXPECT_EQ(vc_cmd_create(&cmd), VC_ERROR_NONE);
+
+       EXPECT_EQ(vc_cmd_get_domain(nullptr, &domain), VC_ERROR_INVALID_PARAMETER);
+       EXPECT_EQ(vc_cmd_get_domain(cmd, nullptr), VC_ERROR_INVALID_PARAMETER);
+
+       EXPECT_EQ(vc_cmd_destroy(cmd), VC_ERROR_NONE);
+}
+
 } // namespace