From: Sanghoon Lee Date: Mon, 22 Apr 2019 07:03:28 +0000 (+0900) Subject: [Non-ACR][inst.py][Updated inst logic for Inputmethod manual testing] X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=14e17c1c8f3a631d937f62e5b9c198d1b0ebf45d;p=test%2Ftct%2Fcsharp%2Fapi.git [Non-ACR][inst.py][Updated inst logic for Inputmethod manual testing] Change-Id: I3ddcc7d469ff46ea379f7e00e793ef5a64663c4b --- diff --git a/tool/script/template/inst.py b/tool/script/template/inst.py index ab8dc9d..b6c2afa 100755 --- a/tool/script/template/inst.py +++ b/tool/script/template/inst.py @@ -190,6 +190,20 @@ def checkPlatformArch(config_key): return True return False +def checkProfile(): + config_key = 'tizen.org/feature/profile' + (return_code, output) = doRemoteCMD("cat /etc/config/model-config.xml | grep %s" % (config_key)) + output_len = len(output) + + #'mobile/wearable/tv' + for out in output: + if config_key in out: + if 'mobile' in out: + return 'mobile' + elif 'wearable' in out: + return 'wearable' + elif 'tv' in out: + return 'tv' def instPKGs(): action_status = True @@ -263,6 +277,20 @@ def instPKGs(): else: print("Skipped installation on this platform. file name is %s" % (file)) + elif file == "org.tizen.example.IMESample.Tizen.Mobile-1.0.0.tpk": + check_profile = checkProfile() + if check_profile != 'wearable': + (return_code, output) = doRemoteCMD("pkgcmd -i -t tpk -q -p %s/%s" % (SRC_DIR, file)) + else: + print("Skipped installation on this profile. file name is %s" % (file)) + + elif file == "org.tizen.example.IMESample.Tizen.Wearable-1.0.0.tpk": + check_profile = checkProfile() + if check_profile == 'wearable': + (return_code, output) = doRemoteCMD("pkgcmd -i -t tpk -q -p %s/%s" % (SRC_DIR, file)) + else: + print("Skipped installation on this profile. file name is %s" % (file)) + else: (return_code, output) = doRemoteCMD( "pkgcmd -i -t tpk -q -p %s/%s" % (SRC_DIR, file))