Skip to content

Commit

Permalink
[rb] Return and deprecate DriverFinder.path
Browse files Browse the repository at this point in the history
This was accidentally removed in #13386.
Fixes #13876.
Related to rails/rails#51658.
  • Loading branch information
p0deje committed Apr 25, 2024
1 parent 0d2b8d1 commit 5148e83
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions rb/lib/selenium/webdriver/common/driver_finder.rb
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,11 @@
module Selenium
module WebDriver
class DriverFinder
def self.path(options, service)
WebDriver.logger.deprecate('DriverFinder.path', 'DriverFinder.new.driver_path')
new(options, service).driver_path
end

def initialize(options, service)
@options = options
@service = service
Expand All @@ -41,9 +46,9 @@ def browser_path?

def paths
@paths ||= begin
path = @service.class.driver_path
path = @service.driver_path
path = path.call if path.is_a?(Proc)
exe = @service.class::EXECUTABLE
exe = @service::EXECUTABLE
if path
WebDriver.logger.debug("Skipping Selenium Manager; path to #{exe} specified in service class: #{path}")
Platform.assert_executable(path)
Expand Down

0 comments on commit 5148e83

Please sign in to comment.