fix merge

This commit is contained in:
Ryan Manuel
2024-10-18 14:08:52 -05:00
parent e1df8c084f
commit ce67a9eaf5
2 changed files with 6 additions and 7 deletions
+3 -4
View File
@@ -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<BrowserCriClient> {
// 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),
])
+3 -3
View File
@@ -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(),