mirror of
https://github.com/ARM-software/workload-automation.git
synced 2025-01-19 04:21:17 +00:00
AndroidWorkload: Uninstall uiauto apks before reinstalling
Due to the fact that uiauto apk files built on different machines will be signed with different keys, adb will fail to overwrite a previous version even when set to replace. This commit now will uninstall the previous uiauto apk file if present before attempting to install the new version.
This commit is contained in:
parent
27b488cc56
commit
4d397ab465
@ -293,7 +293,9 @@ class UiAutomatorGUI(object):
|
||||
instrumentation_string)
|
||||
|
||||
def deploy(self):
|
||||
self.target.install_apk(self.uiauto_file, replace=True)
|
||||
if self.target.package_is_installed(self.uiauto_package):
|
||||
self.target.uninstall_package(self.uiauto_package)
|
||||
self.target.install_apk(self.uiauto_file)
|
||||
|
||||
def set(self, name, value):
|
||||
self.uiauto_params[name] = value
|
||||
|
Loading…
x
Reference in New Issue
Block a user