Update tct-testconfig for bluetooth and messaging testing
authorjiehua.xiong <jiehuax.xiong@intel.com>
Wed, 9 Oct 2013 04:45:44 +0000 (12:45 +0800)
committerGerrit Code Review <gerrit@gerrit.vlan144.tizendev.org>
Wed, 9 Oct 2013 06:34:28 +0000 (06:34 +0000)
Use json to update constant variable in AJAX

Change-Id: I338ef5a7bf3aa8258b33f00738404a31e99d9a24

tct-bluetooth-tizen-tests/bluetooth/support/bluetooth_common.js
tct-bluetooth-tizen-tests/bluetooth/support/getJsonConf.js [new file with mode: 0644]
tct-messaging-email-tizen-tests/messaging/support/getJsonConf.js [new file with mode: 0644]
tct-messaging-email-tizen-tests/messaging/support/messaging_common.js
tct-messaging-mms-tizen-tests/messaging/support/getJsonConf.js [new file with mode: 0644]
tct-messaging-mms-tizen-tests/messaging/support/messaging_common.js
tct-messaging-sms-tizen-tests/messaging/support/getJsonConf.js [new file with mode: 0644]
tct-messaging-sms-tizen-tests/messaging/support/messaging_common.js
tct-testconfig/preconfigure.json [new file with mode: 0644]
tct-testconfig/tct-testconfig.ini
tct-testconfig/tct-testconfig.sh [deleted file]

index 41edbe3f6aa227d04d899d0b27e891cff3ecc014..6b4d851edae07d5dfe2edabdbd7d526a82a4f2b2 100644 (file)
@@ -331,3 +331,7 @@ function cancelDiscovery() {
         console.log("Error while stopDiscovery : " + e.message);
     })
 }
+
+// change REMOTE_DEVICE_ADDRESS and REMOTE_DEVICE_NAME
+document.write('<script src="../testkit/web/jquery-1.10.2.min.js"></script>');
+document.write('<script src="support/getJsonConf.js"></script>');
diff --git a/tct-bluetooth-tizen-tests/bluetooth/support/getJsonConf.js b/tct-bluetooth-tizen-tests/bluetooth/support/getJsonConf.js
new file mode 100644 (file)
index 0000000..fa7cef9
--- /dev/null
@@ -0,0 +1,44 @@
+/*
+Copyright (c) 2013 Intel Corporation.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+* Redistributions of works must retain the original copyright notice, this list
+  of conditions and the following disclaimer.
+* Redistributions in binary form must reproduce the original copyright notice,
+  this list of conditions and the following disclaimer in the documentation
+  and/or other materials provided with the distribution.
+* Neither the name of Intel Corporation nor the names of its contributors
+  may be used to endorse or promote products derived from this work without
+  specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY INTEL CORPORATION "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL INTEL CORPORATION BE LIABLE FOR ANY DIRECT,
+INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+Authors:
+        Li, Hao <haox.li@intel.com>
+
+*/
+
+
+
+$.ajax({
+  url:"/opt/usr/media/tct/preconfigure.json",
+  dataType:"json",
+  data:{},
+  async:false,
+  success:function(data){
+    REMOTE_DEVICE_ADDRESS = data[0]["BT_REMOTE_DEVICE_ADDRESS"];
+    REMOTE_DEVICE_NAME = data[0]["BT_REMOTE_DEVICE_NAME"];
+
+  }
+})
diff --git a/tct-messaging-email-tizen-tests/messaging/support/getJsonConf.js b/tct-messaging-email-tizen-tests/messaging/support/getJsonConf.js
new file mode 100644 (file)
index 0000000..7952475
--- /dev/null
@@ -0,0 +1,50 @@
+/*
+Copyright (c) 2013 Intel Corporation.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+* Redistributions of works must retain the original copyright notice, this list
+  of conditions and the following disclaimer.
+* Redistributions in binary form must reproduce the original copyright notice,
+  this list of conditions and the following disclaimer in the documentation
+  and/or other materials provided with the distribution.
+* Neither the name of Intel Corporation nor the names of its contributors
+  may be used to endorse or promote products derived from this work without
+  specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY INTEL CORPORATION "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL INTEL CORPORATION BE LIABLE FOR ANY DIRECT,
+INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+Authors:
+        Li, Hao <haox.li@intel.com>
+
+*/
+
+$.ajax({
+  url:"/opt/usr/media/tct/preconfigure.json",
+  dataType:"json",
+  data:{},
+  async:false,
+  success:function(data){
+    TEST_EMAIL_RECIPIENT_1 = data[0]["EMAIL_RECIPIENT_1"];
+    TEST_EMAIL_RECIPIENT_2 = data[0]["EMAIL_RECIPIENT_2"];
+    emailMessageInitDict = {
+      subject: "sample subject",
+      to: [TEST_EMAIL_RECIPIENT_1],
+      cc: [TEST_EMAIL_RECIPIENT_2],
+      bcc: [TEST_EMAIL_RECIPIENT_1, TEST_EMAIL_RECIPIENT_2],
+      plainBody: "sample plainBody",
+      htmlBody: "sample htmlBody",
+      isHighPriority: false
+    };
+  }
+})
index 30cdb1628ccff9ea1ab6183204ae537bef8cba0b..c70a80c093f21e216077980ee85326584f254b98 100755 (executable)
@@ -198,6 +198,10 @@ function getInboxFolder(t, folders) {
     return inboxFolder;
 }
 
+// change TEST_EMAIL_RECIPIENT_1 and TEST_EMAIL_RECIPIENT_2
+document.write('<script src="../testkit/web/jquery-1.10.2.min.js"></script>');
+document.write('<script src="support/getJsonConf.js"></script>');
+
 function findMessages(t, service, folder, subject, onSuccess, onError) {
     var subjectFilter, folderFilter, compositefilter;
 
diff --git a/tct-messaging-mms-tizen-tests/messaging/support/getJsonConf.js b/tct-messaging-mms-tizen-tests/messaging/support/getJsonConf.js
new file mode 100644 (file)
index 0000000..e63151a
--- /dev/null
@@ -0,0 +1,47 @@
+/*
+Copyright (c) 2013 Intel Corporation.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+* Redistributions of works must retain the original copyright notice, this list
+  of conditions and the following disclaimer.
+* Redistributions in binary form must reproduce the original copyright notice,
+  this list of conditions and the following disclaimer in the documentation
+  and/or other materials provided with the distribution.
+* Neither the name of Intel Corporation nor the names of its contributors
+  may be used to endorse or promote products derived from this work without
+  specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY INTEL CORPORATION "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL INTEL CORPORATION BE LIABLE FOR ANY DIRECT,
+INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+Authors:
+        Li, Hao <haox.li@intel.com>
+
+*/
+
+
+$.ajax({
+  url:"/opt/usr/media/tct/preconfigure.json",
+  dataType:"json",
+  data:{},
+  async:false,
+  success:function(data){
+    TEST_SMS_RECIPIENT = data[0]["MMS_RECIPIENT_1"];
+    TEST_SMS_RECIPIENT_2 = data[0]["MMS_RECIPIENT_2"];
+    mmsMessageInitDict = {
+      subject: "sample subject",
+      to: [TEST_SMS_RECIPIENT],
+      plainBody: "sample plainBody"
+    };
+  }
+})
index 2e251bf32fda15aa04208e00ece7b11f8967074d..7e6a1b5e499b152adfdd949fb16ce10bf13e4ae8 100755 (executable)
@@ -108,3 +108,7 @@ function removeAllMessages(t, service, onSuccess) {
         service.messageStorage.findMessages(MMStypeFilter, findSuccess, findError);
     });
 }
+
+// change TEST_SMS_RECIPIENT and TEST_SMS_RECIPIENT_2
+document.write('<script src="../testkit/web/jquery-1.10.2.min.js"></script>');
+document.write('<script src="support/getJsonConf.js"></script>');
diff --git a/tct-messaging-sms-tizen-tests/messaging/support/getJsonConf.js b/tct-messaging-sms-tizen-tests/messaging/support/getJsonConf.js
new file mode 100644 (file)
index 0000000..7faa045
--- /dev/null
@@ -0,0 +1,46 @@
+/*
+Copyright (c) 2013 Intel Corporation.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+* Redistributions of works must retain the original copyright notice, this list
+  of conditions and the following disclaimer.
+* Redistributions in binary form must reproduce the original copyright notice,
+  this list of conditions and the following disclaimer in the documentation
+  and/or other materials provided with the distribution.
+* Neither the name of Intel Corporation nor the names of its contributors
+  may be used to endorse or promote products derived from this work without
+  specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY INTEL CORPORATION "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL INTEL CORPORATION BE LIABLE FOR ANY DIRECT,
+INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+Authors:
+        Li, Hao <haox.li@intel.com>
+
+*/
+
+
+$.ajax({
+  url:"/opt/usr/media/tct/preconfigure.json",
+  dataType:"json",
+  data:{},
+  async:false,
+  success:function(data){
+    TEST_SMS_RECIPIENT = data[0]["SMS_RECIPIENT_1"];
+    TEST_SMS_RECIPIENT_2 = data[0]["SMS_RECIPIENT_2"];
+    smsMessageInitDict = {
+      to: [TEST_SMS_RECIPIENT],
+      plainBody: "sample plainBody"
+    };
+  }
+})
index 6279e6d10ca3800110855407463460ead6e969e6..0393f062488f33a675ed34c0daccf5496b7d0761 100755 (executable)
@@ -105,3 +105,7 @@ function removeAllMessages(t, service, onSuccess) {
         service.messageStorage.findMessages(typeFilter, findSuccess, findError);
     });
 }
+
+// change TEST_SMS_RECIPIENT and TEST_SMS_RECIPIENT_2
+document.write('<script src="../testkit/web/jquery-1.10.2.min.js"></script>');
+document.write('<script src="support/getJsonConf.js"></script>');
diff --git a/tct-testconfig/preconfigure.json b/tct-testconfig/preconfigure.json
new file mode 100644 (file)
index 0000000..d600cdc
--- /dev/null
@@ -0,0 +1,10 @@
+[{
+    "BT_REMOTE_DEVICE_ADDRESS": "127.0.0.1",
+    "BT_REMOTE_DEVICE_NAME": "localhost",
+    "EMAIL_RECIPIENT_1": "123@intel.com",
+    "EMAIL_RECIPIENT_2": "456@intel.com",
+    "MMS_RECIPIENT_1": "123456789",
+    "MMS_RECIPIENT_2": "987654321",
+    "SMS_RECIPIENT_1": "123456789",
+    "SMS_RECIPIENT_2": "987654321"
+}]
index dd52fafa50e4bdd76049c27c8bfa5023eae1f835..b8949f7fbc2246a8378918ea80da9bf983c839a1 100755 (executable)
@@ -25,5 +25,3 @@ MMS_RECIPIENT_2=your MMS recipient 2
 SMS_RECIPIENT_1=your SMS recipient 1
 # Second SMS recipient, must be set to phone number(different from first SMS recipient and without country calling code)
 SMS_RECIPIENT_2=your SMS recipient 2
-[tct-geoallow-w3c-tests]
-[tct-geodeny-w3c-tests]
diff --git a/tct-testconfig/tct-testconfig.sh b/tct-testconfig/tct-testconfig.sh
deleted file mode 100755 (executable)
index f1eae9a..0000000
+++ /dev/null
@@ -1,324 +0,0 @@
-#!/bin/bash
-##
-# Copyright (c) 2012 Intel Corporation.
-#
-# Redistribution and use in source and binary forms, with or without modification,
-# are permitted provided that the following conditions are met:
-#
-# * Redistributions of works must retain the original copyright notice, this list
-#   of conditions and the following disclaimer.
-# * Redistributions in binary form must reproduce the original copyright notice,
-#   this list of conditions and the following disclaimer in the documentation
-#   and/or other materials provided with the distribution.
-# * Neither the name of Intel Corporation nor the names of its contributors
-#   may be used to endorse or promote products derived from this work without
-#   specific prior written permission.
-#
-# THIS SOFTWARE IS PROVIDED BY INTEL CORPORATION "AS IS"
-# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-# ARE DISCLAIMED. IN NO EVENT SHALL INTEL CORPORATION BE LIABLE FOR ANY DIRECT,
-# INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
-# BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
-# OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
-# NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
-# EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-#
-# Authors:
-#          Yugang.fan <yugang.fan@intel.com>
-#          Lin, Wanming <wanmingx.lin@intel.com>
-
-CONFIG_FILE=
-CONFIG_GEO=
-BT_REMOTE_DEVICE_ADDRESS=
-BT_REMOTE_DEVICE_NAME=
-MMS_RECIPIENT_1=
-MMS_RECIPIENT_2=
-SMS_RECIPIENT_1=
-SMS_RECIPIENT_2=
-EMAIL_RECIPIENT_1=
-EMAIL_RECIPIENT_2=
-packageParam="false"
-PACKAGE_NAME=
-
-
-function showUsage(){
-cat << EOF
-Usage: tct-testconfig.sh [...]
-  -p packages need to be updated.[options: tct-bluetooth-tizen-tests,tct-messaging-email-tizen-tests...]
-  -f Set argument of config file path.
-  Show usage except the above options.
-E.g.
-  sh tct-testconfig.sh -f your-config-file
-  sh tct-testconfig.sh -f your-cinfig-file -p packagename1,packagename2[optional]
-EOF
-}
-
-function getParamsFromConfig(){
-if [ -n "$CONFIG_FILE" ] && [ -f "$CONFIG_FILE" ]; then
-        echo -n -e "\033[34mGot config file: $CONFIG_FILE\033[0m\n"
-        while read LINE
-        do
-                ParamName=`echo $LINE | sed 's/\(^[^=^ ]*\)[ ]*=.*$/\1/g'`
-                ParamValue=`echo $LINE | sed 's/\(^[^=^ ]*\)[ ]*=\(.*\)$/\2/g'`
-                case $ParamName in
-                'BT_REMOTE_DEVICE_ADDRESS')
-                        BT_REMOTE_DEVICE_ADDRESS=$ParamValue
-                        ;;
-                'BT_REMOTE_DEVICE_NAME')
-                        BT_REMOTE_DEVICE_NAME=$ParamValue
-                        ;;
-                'SMS_RECIPIENT_1')
-                        SMS_RECIPIENT_1=$ParamValue
-                        ;;
-                'SMS_RECIPIENT_2')
-                        SMS_RECIPIENT_2=$ParamValue
-                        ;;
-                'MMS_RECIPIENT_1')
-                        MMS_RECIPIENT_1=$ParamValue
-                        ;;
-                'MMS_RECIPIENT_2')
-                        MMS_RECIPIENT_2=$ParamValue
-                        ;;
-                'EMAIL_RECIPIENT_1')
-                        EMAIL_RECIPIENT_1=$ParamValue
-                        ;;
-                'EMAIL_RECIPIENT_2')
-                        EMAIL_RECIPIENT_2=$ParamValue
-                        ;;
-                * )
-                        ;;
-                esac
-        done < $CONFIG_FILE
-else
-        echo -n -e "\033[31mCan't find config file: $CONFIG_FILE ...\033[0m\n"
-        exit -1
-fi
-}
-
-function configBluetooth(){
-
-CMD=(
-    "" \
-    "" \
-)
-
-FILE_LIST=(
-"/opt/usr/apps/api1bluet0/res/wgt/opt/tct-bluetooth-tizen-tests/bluetooth/support/bluetooth_common.js" \
-"/opt/usr/apps/api1bluet0/res/wgt/opt/tct-bluetooth-tizen-tests/bluetooth/support/bluetooth_common.js" \
-)
-
-CMD_LIST=(
-    "eval sed -i 's/var\sREMOTE\_DEVICE\_ADDRESS\s\=\s\"\([^\"]*\)\"/var\ REMOTE\_DEVICE\_ADDRESS\ =\ \"$BT_REMOTE_DEVICE_ADDRESS\"/g' FILE" \
-    "eval sed -i 's/var\sREMOTE\_DEVICE\_NAME\s\=\s\"\([^\"]*\)\"/var\ REMOTE\_DEVICE\_NAME\ =\ \"$BT_REMOTE_DEVICE_NAME\"/g' FILE" \
-)
-
-i=0
-for iSuite in ${FILE_LIST[@]}
-do
-        j=$i
-        i=`expr $i+1`
-        echo -n -e "\n==>> Configuring $iSuite\033[0m\n"
-
-        CMD=${CMD_LIST[$j]/FILE/${FILE_LIST[$j]}}
-        echo -n -e "Config CMD: \033[34m${CMD} \033[0m\n"
-
-        `${CMD}`
-        if [ $? -ne 0 ]; then
-                echo -n -e "\033[31mConfig ${FILE_LIST[$j]} fail ...\033[0m\n"
-        else
-                echo -n -e "\033[32mConfig ${FILE_LIST[$j]} successfully ...\033[0m\n"
-        fi
-        sync
-done
-}
-
-function configEmail(){
-
-CMD=(
-    "" \
-    "" \
-)
-
-FILE_LIST=(
-    "/opt/usr/apps/api1msg003/res/wgt/opt/tct-messaging-email-tizen-tests/messaging/support/messaging_common.js" \
-    "/opt/usr/apps/api1msg003/res/wgt/opt/tct-messaging-email-tizen-tests/messaging/support/messaging_common.js" \
-)
-CMD_LIST=(
-    "eval sed -i 's/var\sTEST\_EMAIL\_RECIPIENT\_1\s\=\s\"\([^\"]*\)\"/var\ TEST\_EMAIL\_RECIPIENT\_1\ =\ \"$EMAIL_RECIPIENT_1\"/g' FILE" \
-    "eval sed -i 's/var\sTEST\_EMAIL\_RECIPIENT\_2\s\=\s\"\([^\"]*\)\"/var\ TEST\_EMAIL\_RECIPIENT\_2\ =\ \"$EMAIL_RECIPIENT_2\"/g' FILE" \
-)
-
-i=0
-for iSuite in ${FILE_LIST[@]}
-do
-        j=$i
-        i=`expr $i+1`
-        echo -n -e "\n==>> Configuring $iSuite\033[0m\n"
-
-        CMD=${CMD_LIST[$j]//FILE/${FILE_LIST[$j]}}
-        echo -n -e "Config CMD: \033[34m${CMD} \033[0m\n"
-
-        `${CMD}`
-        if [ $? -ne 0 ]; then
-                echo -n -e "\033[31mConfig ${FILE_LIST[$j]} fail ...\033[0m\n"
-        else
-                echo -n -e "\033[32mConfig ${FILE_LIST[$j]} successfully ...\033[0m\n"
-        fi
-        sync
-done
-}
-
-function configMms(){
-
-CMD=(
-    "" \
-    "" \
-)
-
-FILE_LIST=(
-    "/opt/usr/apps/api1msg002/res/wgt/opt/tct-messaging-mms-tizen-tests/messaging/support/messaging_common.js" \
-    "/opt/usr/apps/api1msg002/res/wgt/opt/tct-messaging-mms-tizen-tests/messaging/support/messaging_common.js" \
-)
-CMD_LIST=(
-    "eval sed -i 's/var\sTEST\_SMS\_RECIPIENT\s\=\s\"\([^\"]*\)\"/var\ TEST\_SMS\_RECIPIENT\ =\ \"$MMS_RECIPIENT_1\"/g' FILE" \
-    "eval sed -i 's/var\sTEST\_SMS\_RECIPIENT\_2\s\=\s\"\([^\"]*\)\"/var\ TEST\_SMS\_RECIPIENT\_2\ =\ \"$MMS_RECIPIENT_2\"/g' FILE" \
-)
-
-i=0
-for iSuite in ${FILE_LIST[@]}
-do
-        j=$i
-        i=`expr $i+1`
-        echo -n -e "\n==>> Configuring $iSuite\033[0m\n"
-
-        CMD=${CMD_LIST[$j]//FILE/${FILE_LIST[$j]}}
-        echo -n -e "Config CMD: \033[34m${CMD} \033[0m\n"
-
-        `${CMD}`
-        if [ $? -ne 0 ]; then
-                echo -n -e "\033[31mConfig ${FILE_LIST[$j]} fail ...\033[0m\n"
-        else
-                echo -n -e "\033[32mConfig ${FILE_LIST[$j]} successfully ...\033[0m\n"
-        fi
-        sync
-done
-}
-
-function configSms(){
-
-CMD=(
-    "" \
-    "" \
-)
-
-FILE_LIST=(
-    "/opt/usr/apps/api1msg001/res/wgt/opt/tct-messaging-sms-tizen-tests/messaging/support/messaging_common.js" \
-    "/opt/usr/apps/api1msg001/res/wgt/opt/tct-messaging-sms-tizen-tests/messaging/support/messaging_common.js" \
-)
-CMD_LIST=(
-    "eval sed -i 's/var\sTEST\_SMS\_RECIPIENT\s\=\s\"\([^\"]*\)\"/var\ TEST\_SMS\_RECIPIENT\ =\ \"$SMS_RECIPIENT_1\"/g' FILE" \
-    "eval sed -i 's/var\sTEST\_SMS\_RECIPIENT\_2\s\=\s\"\([^\"]*\)\"/var\ TEST\_SMS\_RECIPIENT\_2\ =\ \"$SMS_RECIPIENT_2\"/g' FILE" \
-)
-
-i=0
-for iSuite in ${FILE_LIST[@]}
-do
-        j=$i
-        i=`expr $i+1`
-        echo -n -e "\n==>> Configuring $iSuite\033[0m\n"
-
-        CMD=${CMD_LIST[$j]//FILE/${FILE_LIST[$j]}}
-        echo -n -e "Config CMD: \033[34m${CMD} \033[0m\n"
-
-        `${CMD}`
-        if [ $? -ne 0 ]; then
-                echo -n -e "\033[31mConfig ${FILE_LIST[$j]} fail ...\033[0m\n"
-        else
-                echo -n -e "\033[32mConfig ${FILE_LIST[$j]} successfully ...\033[0m\n"
-        fi
-        sync
-done
-}
-
-function getPackage(){
-        if [ -n "$PACKAGE_NAME" ]; then
-                #PackageName=($PACKAGE_NAME)
-                PackageName=(${PACKAGE_NAME//,/ })
-                if [ ${#PackageName[*]} -lt 3 ]; then
-                    for pname in ${PackageName[@]}
-                    do
-                        case $pname in
-                                'tct-bluetooth-tizen-tests')
-                                configBluetooth;
-                                ;;
-                                'tct-messaging-email-tizen-tests')
-                                configEmail;
-                                ;;
-                                'tct-messaging-mms-tizen-tests')
-                                configMms;
-                                ;;
-                                'tct-messaging-sms-tizen-tests')
-                                configSms;
-                                ;;
-                                'tct-geoallow-w3c-tests')
-                                ConfigGeo;
-                                ;;
-                                'tct-geodeny-w3c-tests')
-                                ConfigGeo;
-                                ;;
-                                * )
-                                echo "fail, error package name:$pname";
-                                exit -1
-                                ;;
-                                esac
-                    done
-                else
-                    showUsage;
-                    exit -1
-               fi
-        else
-                showUsage;
-                exit -1
-        fi
-}
-
-function ConfigGeo(){
-        su -c "vconftool set -t int db/location/replay/ReplayEnabled 1 -f"
-        echo "Config geolocation successfully..."
-}
-
-while getopts "f:p:" arg
-do
-        case $arg in
-                f)
-                CONFIG_FILE=$OPTARG;
-                ;;
-                p)
-                packageParam="true";
-                PACKAGE_NAME=$OPTARG;
-                ;;
-                ?)
-                showUsage;
-                exit -1
-                ;;
-                esac
-done
-
-if [ "$packageParam" = "false" ] && [ -n "$CONFIG_FILE" ]; then
-        getParamsFromConfig;
-        configBluetooth;
-        configEmail;
-        configMms;
-        configSms;
-        ConfigGeo;
-        exit 0
-elif [ "$packageParam" = "true" ] && [ -n "$CONFIG_FILE" ]; then
-        getParamsFromConfig;
-        getPackage;
-        exit 0
-else
-        showUsage;
-        exit -1
-fi