Bug 1079774 - [mozrunner] Reduce time spent detecting crashes on devices. r=ahalberstadt
authorDave Hunt <dhunt@mozilla.com>
Wed, 08 Oct 2014 03:58:00 +0200
changeset 232787 d3e3fc74801b9f9fbbc29c971e6a0a3e4334f5b7
parent 232786 7ec922b5772f05aacd915e9344e1804b41185fd4
child 232788 61b3f3d9bffe987e2098c37df5447db3dd883747
push id4187
push userbhearsum@mozilla.com
push dateFri, 28 Nov 2014 15:29:12 +0000
treeherdermozilla-beta@f23cc6a30c11 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersahalberstadt
bugs1079774
milestone35.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 1079774 - [mozrunner] Reduce time spent detecting crashes on devices. r=ahalberstadt
testing/mozbase/mozrunner/mozrunner/devices/base.py
--- a/testing/mozbase/mozrunner/mozrunner/devices/base.py
+++ b/testing/mozbase/mozrunner/mozrunner/devices/base.py
@@ -56,18 +56,19 @@ class Device(object):
         """
         Saves any minidumps found in the remote profile on the local filesystem.
 
         :returns: Path to directory containing the dumps.
         """
         remote_dump_dir = posixpath.join(self.app_ctx.remote_profile, 'minidumps')
         local_dump_dir = tempfile.mkdtemp()
         self.dm.getDirectory(remote_dump_dir, local_dump_dir)
-        for f in self.dm.listFiles(remote_dump_dir):
-            self.dm.removeFile(posixpath.join(remote_dump_dir, f))
+        if os.listdir(local_dump_dir):
+            for f in self.dm.listFiles(remote_dump_dir):
+                self.dm.removeFile(posixpath.join(remote_dump_dir, f))
         return local_dump_dir
 
     def setup_profile(self, profile):
         """
         Copy profile to the device and update the remote profiles.ini
         to point to the new profile.
 
         :param profile: mozprofile object to copy over.