Bug 978132 - Copy more binaries to device for Android xpcshell tests; r=jmaher
authorGeoff Brown <gbrown@mozilla.com>
Tue, 29 Apr 2014 15:09:27 -0600
changeset 181274 a0db52e1d0ab9cb0d820f1a0d65a2891e9b585bd
parent 181273 9d7d10a54e444dba42d60702ed743a842a466409
child 181275 5b722269feee1758bc7c7dfb20e9bca8fcee9900
push id272
push userpvanderbeken@mozilla.com
push dateMon, 05 May 2014 16:31:18 +0000
reviewersjmaher
bugs978132
milestone32.0a1
Bug 978132 - Copy more binaries to device for Android xpcshell tests; r=jmaher
testing/xpcshell/remotexpcshelltests.py
--- a/testing/xpcshell/remotexpcshelltests.py
+++ b/testing/xpcshell/remotexpcshelltests.py
@@ -358,19 +358,34 @@ class XPCShellRemote(xpcshell.XPCShellTe
             self.device.mkDir(self.remoteScriptsDir)
         if (not self.device.dirExists(self.remoteComponentsDir)):
             self.device.mkDir(self.remoteComponentsDir)
 
         local = os.path.join(os.path.dirname(os.path.abspath(__file__)), 'head.js')
         remoteFile = remoteJoin(self.remoteScriptsDir, "head.js")
         self.device.pushFile(local, remoteFile)
 
-        local = os.path.join(self.localBin, "xpcshell")
-        remoteFile = remoteJoin(self.remoteBinDir, "xpcshell")
-        self.device.pushFile(local, remoteFile)
+        # The xpcshell binary is required for all tests. Additional binaries
+        # are required for some tests. This list should be similar to
+        # TEST_HARNESS_BINS in testing/mochitest/Makefile.in.
+        binaries = ["xpcshell",
+                    "ssltunnel",
+                    "certutil",
+                    "pk12util",
+                    "BadCertServer",
+                    "OCSPStaplingServer",
+                    "GenerateOCSPResponse"]
+        for fname in binaries:
+            local = os.path.join(self.localBin, fname)
+            if os.path.isfile(local):
+                print >> sys.stderr, "Pushing %s.." % fname
+                remoteFile = remoteJoin(self.remoteBinDir, fname)
+                self.device.pushFile(local, remoteFile)
+            else:
+                print >> sys.stderr, "*** Expected binary %s not found in %s!" % (fname, self.localBin)
 
         local = os.path.join(self.localBin, "components/httpd.js")
         remoteFile = remoteJoin(self.remoteComponentsDir, "httpd.js")
         self.device.pushFile(local, remoteFile)
 
         local = os.path.join(self.localBin, "components/httpd.manifest")
         remoteFile = remoteJoin(self.remoteComponentsDir, "httpd.manifest")
         self.device.pushFile(local, remoteFile)