Skip to content

Commit

Permalink
don't set remote-debugging-port for chrome
Browse files Browse the repository at this point in the history
  • Loading branch information
ashbythorpe committed Dec 14, 2024
1 parent 61f8d0c commit c79ca82
Showing 1 changed file with 4 additions and 21 deletions.
25 changes: 4 additions & 21 deletions R/session.R
Original file line number Diff line number Diff line change
Expand Up @@ -408,27 +408,10 @@ get_driver <- function(browser, options, driver) {
server$read_error()
}

if (inherits(options$client_options, "selenium_client_options")) {
options$capabilities <- if (is.null(options$capabilities) && browser == "chrome") {
list(`goog:chromeOptions` = list(
args = list(
"remote-debugging-port=9222"
)
))
} else {
options$capabilities
}

client <- skip_error_if_testing(
create_selenium_client_internal(browser, options$client_options),
message = "Selenium client failed to start."
)
} else {
client <- skip_error_if_testing(
create_rselenium_client_internal(browser, options$client_options),
message = "RSelenium client failed to start."
)
}
client <- skip_error_if_testing(
create_selenium_client_internal(browser, options$client_options),
message = "Selenium client failed to start."
)

cache <- inherits(options$server_options, "selenium_server_options") &&
!has_default_selenium_object()
Expand Down

0 comments on commit c79ca82

Please sign in to comment.