[TCT][external_wrapper.sh][Non-ACR][Add commands for mem_leak]
authorso2.park <so2.park@samsung.com>
Tue, 25 Oct 2016 09:21:58 +0000 (18:21 +0900)
committerso2.park <so2.park@samsung.com>
Tue, 25 Oct 2016 09:21:58 +0000 (18:21 +0900)
Change-Id: I6d5f6ad5c777a433e3d38e20c1170b28767da323
Signed-off-by: so2.park <so2.park@samsung.com>
scripts_tpk/external_wrapper.sh

index a257136..049a4e3 100755 (executable)
@@ -19,6 +19,8 @@
 
 TIMEOUT_VALUE=60 #default timeout value
 FILE="/tmp/TC_Timeout.txt"
+SCRIPT_DIR="/home/owner/share"
+
 # extract TCT configuration directory from TCT_CONFIG_FILE (/tmp/TCT_CONFIG)
 TCT_CONFIG_FILE=/tmp/TCT_CONFIG
 if [ ! -f $TCT_CONFIG_FILE ];then
@@ -64,12 +66,24 @@ function Execute {
        rm -f $UTC_LOG
        rm -f $UTC_LOG_CORE
 
+       ## pre-launch script
+       if [ -f $SCRIPT_DIR/pre_launch.sh ];
+       then
+               bash $SCRIPT_DIR/pre_launch.sh $1 $2
+       fi
+
        RET=`su -c "app_launcher -s $1 testcase_name $2" $DEVICE_EXECUTION_MODE_30`
        if [[ $RET != *"successfully launched"* ]];then
                echo "Launch Failed"
                su -c "app_launcher -s $1 > /dev/null" $DEVICE_EXECUTION_MODE_30
                exit 1
        fi
+       ## post-launch script
+       if [ -f $SCRIPT_DIR/post_launch.sh ];
+       then
+               bash $SCRIPT_DIR/post_launch.sh $1 $2
+       fi
+
 
        COUNTER=0