From: yuanzhongyuan Date: Fri, 12 May 2017 03:00:50 +0000 (+0800) Subject: [widget02][Modify xwalk_common.sh to avoid duplicate pkg name issue] X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=ff744317373f2ec9865c1091c0aaf6ec98441f55;p=test%2Ftct%2Fweb%2Fapi.git [widget02][Modify xwalk_common.sh to avoid duplicate pkg name issue] Change-Id: I4a94e62d8919bd45ab2af5ade04e5297ca225c8a --- diff --git a/common/tct-widget02-w3c-tests/scripts/xwalk_common.sh b/common/tct-widget02-w3c-tests/scripts/xwalk_common.sh index 6e7f1552e..ff727660d 100755 --- a/common/tct-widget02-w3c-tests/scripts/xwalk_common.sh +++ b/common/tct-widget02-w3c-tests/scripts/xwalk_common.sh @@ -39,7 +39,7 @@ function install_app(){ ##usage: uninstall_app $app_name(e.g. uninstall_app tct-sp02-wrt-tests)## function uninstall_app(){ - pkgids=`pkgcmd -l |grep -w $1 |awk -F "pkgid" '{print $2}' |awk -F '[' '{print $2}'|awk -F ']' '{print $1}'` + pkgids=`pkgcmd -l |grep -w $1 |awk -F "pkgid" '{print $2}' |awk -F '[' '{print $2}'|awk -F ']' '{print $1}' |grep '^..........$'` for pkgid in $pkgids do pkgcmd -u -t wgt -q -n $pkgid @@ -48,7 +48,7 @@ function uninstall_app(){ ##usage: find_app $app_name(e.g. uninstall_app tct-sp02-wrt-tests)## function find_app(){ - pkgids=`pkgcmd -l |grep -w $1 |awk -F "pkgid" '{print $2}' |awk -F '[' '{print $2}'|awk -F ']' '{print $1}'` + pkgids=`pkgcmd -l |grep -w $1 |awk -F "pkgid" '{print $2}' |awk -F '[' '{print $2}'|awk -F ']' '{print $1}' |grep '^..........$'` appid=`app_launcher -l | grep -w $1 | awk '{print $2}'` appid=${appid:1:-1} }