зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1435031 - Make it easier to use geckoview_example from android_emulator_unittest.py; r=jmaher
In general, there is no simple mapping between apk name (geckoview_example.apk) and package name (org.mozilla.geckoview_example). With bug 1434411, it will be relatively easy to add or modify tasks to use a geckoview apk in taskcluster tests. At the mozharness level, scripts are expected to expand mozharness configurations containing "%(app)" into package names. For Firefox, android_emulator_unittest extracts and reads package_name.txt, but there is no such file in the geckoview apk. In future we might add package_name.txt to the geckoview apk, or possibly use a tool like aapt, but for our immediate needs this simple hack does the job: If "geckoview" is in the apk name, assume we are installing org.mozilla.geckoview_example.
This commit is contained in:
Родитель
fcd9a3a0c8
Коммит
b83a0a1401
|
@ -376,6 +376,11 @@ class AndroidEmulatorTest(TestingMixin, EmulatorMixin, BaseScript, MozbaseMixin)
|
|||
self.warning("Failed to take screenshot: %s" % err.strerror)
|
||||
|
||||
def _query_package_name(self):
|
||||
if self.app_name is None:
|
||||
# For convenience, assume geckoview_example when install target
|
||||
# looks like geckoview.
|
||||
if 'geckoview' in self.installer_path:
|
||||
self.app_name = 'org.mozilla.geckoview_example'
|
||||
if self.app_name is None:
|
||||
# Find appname from package-name.txt - assumes download-and-extract
|
||||
# has completed successfully.
|
||||
|
|
Загрузка…
Ссылка в новой задаче