Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,10 @@
# under the License.

require 'rack'
begin
require 'rackup'
rescue LoadError
end

module Selenium
module WebDriver
Expand Down Expand Up @@ -76,7 +80,7 @@ def handler

handler = handlers.find { |h| load_handler h }
constant = handler == 'webrick' ? 'WEBrick' : handler.capitalize
Rack::Handler.const_get constant
(defined?(Rackup) ? Rackup : Rack)::Handler.const_get(constant)
end

def load_handler(handler)
Expand All @@ -100,7 +104,7 @@ class TestApp
BASIC_AUTH_CREDENTIALS = %w[test test].freeze

def initialize(file_root)
@static = Rack::File.new(file_root)
@static = Rack::Files.new(file_root)
end

def call(env)
Expand Down
Loading