From 0f95b2788d72cea2b328197c01967921b69953e0 Mon Sep 17 00:00:00 2001 From: Jim Evans Date: Tue, 28 Sep 2021 19:45:40 -0400 Subject: [PATCH] [dotnet] Add --websocket-port command line argument for geckodriver --- dotnet/src/webdriver/Firefox/FirefoxDriverService.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/dotnet/src/webdriver/Firefox/FirefoxDriverService.cs b/dotnet/src/webdriver/Firefox/FirefoxDriverService.cs index 43b950bed6889..d023c546a4671 100644 --- a/dotnet/src/webdriver/Firefox/FirefoxDriverService.cs +++ b/dotnet/src/webdriver/Firefox/FirefoxDriverService.cs @@ -195,6 +195,8 @@ protected override string CommandLineArguments argsBuilder.Append(" --jsdebugger"); } + argsBuilder.Append(string.Format(CultureInfo.InvariantCulture, " --websocket-port {0}", PortUtilities.FindFreePort())); + return argsBuilder.ToString().Trim(); } }