Backed out changeset 14e0a18e9ee0 (bug 1279259) for breaking Autophone tests.
authorRyan VanderMeulen <ryanvm@gmail.com>
Thu, 26 Jan 2017 19:21:36 -0500
changeset 368950 560f5defe1af6334b77e179620a9907c7e693d9f
parent 368949 530cf03bbb79009e3685234db16af440509ff7ef
child 368951 e475fdfb17d48d7b5fe1073d0e99127b8da68769
push id1369
push userjlorenzo@mozilla.com
push dateMon, 27 Feb 2017 14:59:41 +0000
treeherdermozilla-release@d75a1dba431f [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs1279259
milestone52.0
backs out14e0a18e9ee0b799076902e010a1603c33ea1263
Backed out changeset 14e0a18e9ee0 (bug 1279259) for breaking Autophone tests.
testing/mochitest/mochitest_options.py
testing/mochitest/runtests.py
testing/tools/websocketprocessbridge/websocketprocessbridge.py
--- a/testing/mochitest/mochitest_options.py
+++ b/testing/mochitest/mochitest_options.py
@@ -535,21 +535,16 @@ class MochitestArguments(ArgumentContain
           }],
         [["--cleanup-crashes"],
          {"action": "store_true",
           "dest": "cleanupCrashes",
           "default": False,
           "help": "Delete pending crash reports before running tests.",
           "suppress": True,
           }],
-        [["--websocket-process-bridge-port"],
-         {"default": "8191",
-          "dest": "websocket_process_bridge_port",
-          "help": "Port for websocket/process bridge. Default 8191.",
-          }],
     ]
 
     defaults = {
         # Bug 1065098 - The geckomediaplugin process fails to produce a leak
         # log for some reason.
         'ignoreMissingLeaks': ["geckomediaplugin"],
         'extensionsToExclude': ['specialpowers'],
         # Set server information on the args object
--- a/testing/mochitest/runtests.py
+++ b/testing/mochitest/runtests.py
@@ -1081,19 +1081,17 @@ class MochitestDesktop(object):
 
     def startWebsocketProcessBridge(self, options):
         """Create a websocket server that can launch various processes that
         JS needs (eg; ICE server for webrtc testing)
         """
 
         command = [sys.executable,
                    os.path.join("websocketprocessbridge",
-                                "websocketprocessbridge.py"),
-                   "--port",
-                   options.websocket_process_bridge_port]
+                                "websocketprocessbridge.py")]
         self.websocketProcessBridge = mozprocess.ProcessHandler(command,
                                                                 cwd=SCRIPT_DIR)
         self.websocketProcessBridge.run()
         self.log.info("runtests.py | websocket/process bridge pid: %d"
                       % self.websocketProcessBridge.pid)
 
         # ensure the server is up, wait for at most ten seconds
         for i in range(1, 100):
--- a/testing/tools/websocketprocessbridge/websocketprocessbridge.py
+++ b/testing/tools/websocketprocessbridge/websocketprocessbridge.py
@@ -3,17 +3,16 @@
 # License, v. 2.0. If a copy of the MPL was not distributed with this
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 from twisted.internet import protocol, reactor
 from twisted.internet.task import LoopingCall
 import txws
 import psutil
 
-import argparse
 import sys
 import os
 
 # maps a command issued via websocket to running an executable with args
 commands = {
     'iceserver' : [sys.executable,
                    "-u",
                    os.path.join("iceserver", "iceserver.py")]
@@ -85,22 +84,17 @@ parent_process = psutil.Process(os.getpi
 
 def check_parent():
     """ Checks if parent process is still alive, and exits if not """
     if not parent_process.is_running():
         print("websocket/process bridge exiting because parent process is gone")
         reactor.stop()
 
 if __name__ == "__main__":
-    parser = argparse.ArgumentParser(description='Starts websocket/process bridge.')
-    parser.add_argument("--port", type=str, dest="port", default="8191",
-                    help="Port for websocket/process bridge. Default 8191.")
-    args = parser.parse_args()
-
     parent_checker = LoopingCall(check_parent)
     parent_checker.start(1)
 
     bridgeFactory = ProcessSocketBridgeFactory()
-    reactor.listenTCP(int(args.port), txws.WebSocketFactory(bridgeFactory))
-    print("websocket/process bridge listening on port %s" % args.port)
+    reactor.listenTCP(8191, txws.WebSocketFactory(bridgeFactory))
+    print("websocket/process bridge listening on port 8191")
     reactor.run()