diff --git a/packages/server/lib/browsers/firefox-util.ts b/packages/server/lib/browsers/firefox-util.ts index 3f83d990965e..158981fbda0d 100644 --- a/packages/server/lib/browsers/firefox-util.ts +++ b/packages/server/lib/browsers/firefox-util.ts @@ -57,21 +57,20 @@ async function navigateToUrlClassic (url: string) { export default { async setup ({ automation, + onError, url, - foxdriverPort, remotePort, webdriverClient: wdInstance, }: { automation: Automation + onError?: (err: Error) => void url: string - foxdriverPort: number remotePort: number webdriverClient: WebDriverClient }): Promise { // set the WebDriver classic instance instantiated from geckodriver webdriverClient = wdInstance - const [, browserCriClient] = await Promise.all([ - this.setupFoxdriver(foxdriverPort), + const [browserCriClient] = await Promise.all([ setupCDP(remotePort, automation, onError), ]) diff --git a/packages/server/lib/browsers/firefox.ts b/packages/server/lib/browsers/firefox.ts index 2b4793681b8b..48d53f6c450c 100644 --- a/packages/server/lib/browsers/firefox.ts +++ b/packages/server/lib/browsers/firefox.ts @@ -449,13 +449,13 @@ export async function open (browser: Browser, url: string, options: BrowserLaunc const [ marionettePort, webDriverBiDiPort, - ] = await Promise.all([getPort(), getPort(), getPort()]) + ] = await Promise.all([getPort(), getPort()]) defaultLaunchOptions.preferences['marionette.port'] = marionettePort // NOTE: we get the BiDi port and set it inside of geckodriver, but BiDi is not currently enabled (see remote.active-protocols above). // this is so the BiDi websocket port does not get set to 0, which is the default for the geckodriver package. - debug('available ports: %o', { foxdriverPort, marionettePort, webDriverBiDiPort }) + debug('available ports: %o', { marionettePort, webDriverBiDiPort }) const profileDir = utils.getProfileDir(browser, options.isTextTerminal) @@ -686,7 +686,7 @@ export async function open (browser: Browser, url: string, options: BrowserLaunc })) debug('setting up firefox utils') - browserCriClient = await firefoxUtil.setup({ automation, url, foxdriverPort, webdriverClient, remotePort: cdpPort, onError: options.onError }) + browserCriClient = await firefoxUtil.setup({ automation, url, webdriverClient, remotePort: cdpPort, onError: options.onError }) await utils.executeAfterBrowserLaunch(browser, { webSocketDebuggerUrl: browserCriClient.getWebSocketDebuggerUrl(),