Bug 1549992 [mozdevice] mozdevice is not returning exception launch_application is returning a error r=bc
authorFlorin Strugariu <fstrugariu@mozilla.com>
Thu, 09 May 2019 13:24:16 +0000
changeset 532202 a22ba2fa077a0b0f9fc21bc0b1bcbb6737331f74
parent 532201 c052518818dff9b913814d785606a0d11ec65e4e
child 532203 8deb4484f31c1427f92dd7bec741ff11197299c2
push id11265
push userffxbld-merge
push dateMon, 13 May 2019 10:53:39 +0000
treeherdermozilla-beta@77e0fe8dbdd3 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbc
bugs1549992
milestone68.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1549992 [mozdevice] mozdevice is not returning exception launch_application is returning a error r=bc Differential Revision: https://phabricator.services.mozilla.com/D30368
testing/mozbase/mozdevice/mozdevice/adb.py
--- a/testing/mozbase/mozdevice/mozdevice/adb.py
+++ b/testing/mozbase/mozdevice/mozdevice/adb.py
@@ -3036,17 +3036,21 @@ class ADBDevice(ADBCommand):
                     extra_type_param = "--es"
                 acmd.extend([extra_type_param, str(key), str(val)])
 
         if url:
             acmd.extend(["-d", url])
 
         cmd = self._escape_command_line(acmd)
         self._logger.info('launch_application: %s' % cmd)
-        self.shell_output(cmd, timeout=timeout)
+        cmd_output = self.shell_output(cmd, timeout=timeout)
+        if 'Error:' in cmd_output:
+            for line in cmd_output.split('\n'):
+                self._logger.info(line)
+            raise ADBError('launch_activity %s/%s failed' % (app_name, activity_name))
 
     def launch_fennec(self, app_name, intent="android.intent.action.VIEW",
                       moz_env=None, extra_args=None, url=None, wait=True,
                       fail_if_running=True, timeout=None):
         """Convenience method to launch Fennec on Android with various
         debugging arguments
 
         :param str app_name: Name of fennec application (e.g.