selenium-webdriver 4.5.0 → 4.6.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGES +14 -1
- data/bin/linux/selenium-manager +0 -0
- data/bin/macos/selenium-manager +0 -0
- data/bin/windows/selenium-manager.exe +0 -0
- data/lib/selenium/webdriver/chrome/service.rb +1 -1
- data/lib/selenium/webdriver/common/selenium_manager.rb +86 -0
- data/lib/selenium/webdriver/common/service.rb +7 -3
- data/lib/selenium/webdriver/common.rb +1 -0
- data/lib/selenium/webdriver/support/select.rb +1 -4
- data/lib/selenium/webdriver/version.rb +1 -1
- data/selenium-webdriver.gemspec +4 -1
- metadata +7 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e26709ed8eff25ea2f42b168dcfd31e5442cdf339e31dce86d185aefa69696fb
|
4
|
+
data.tar.gz: b3abfb660496c0abe31e37a9974009aed303c9f2adf34a97b87d3d407140cd4b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7c47931633f1892c3021fa1f97cc57fabed2633255a6eb18afe7bc1ac72742272bca354b677902f4afa38a6cc0b51126c895a58c391b25458ec722233729136a
|
7
|
+
data.tar.gz: 2960736aba4dd64aa5b98444f0ca6d7478c7a9d8a4bc5c5a44d7579acf62f4971d50c109c8d5769fea53aebe11c574291a232f5042ec33213eb5d21761252db0
|
data/CHANGES
CHANGED
@@ -1,4 +1,17 @@
|
|
1
|
-
4.
|
1
|
+
4.6.0 (2022-11-04)
|
2
|
+
=========================
|
3
|
+
BiDi:
|
4
|
+
* Released selenium-devtools 0.107.0 (supports CDP v85, v105, v106, v107)
|
5
|
+
|
6
|
+
Ruby:
|
7
|
+
* firefox scroll by amount is only failing on mac
|
8
|
+
* add initial support for selenium manager
|
9
|
+
* Revert "[rb] do not allow Select class to work with disabled selects"
|
10
|
+
* Make sure selenium-manager is packed into gem
|
11
|
+
* Fix platform list in #scroll_by guard
|
12
|
+
|
13
|
+
|
14
|
+
4.5.0 (2022-09-28)
|
2
15
|
=========================
|
3
16
|
|
4
17
|
BiDi:
|
Binary file
|
Binary file
|
Binary file
|
@@ -26,7 +26,7 @@ module Selenium
|
|
26
26
|
MISSING_TEXT = <<~ERROR
|
27
27
|
Unable to find chromedriver. Please download the server from
|
28
28
|
https://chromedriver.storage.googleapis.com/index.html and place it somewhere on your PATH.
|
29
|
-
More info at https://
|
29
|
+
More info at https://www.selenium.dev/documentation/webdriver/getting_started/install_drivers/?language=ruby.
|
30
30
|
ERROR
|
31
31
|
SHUTDOWN_SUPPORTED = true
|
32
32
|
|
@@ -0,0 +1,86 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Licensed to the Software Freedom Conservancy (SFC) under one
|
4
|
+
# or more contributor license agreements. See the NOTICE file
|
5
|
+
# distributed with this work for additional information
|
6
|
+
# regarding copyright ownership. The SFC licenses this file
|
7
|
+
# to you under the Apache License, Version 2.0 (the
|
8
|
+
# "License"); you may not use this file except in compliance
|
9
|
+
# with the License. You may obtain a copy of the License at
|
10
|
+
#
|
11
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
12
|
+
#
|
13
|
+
# Unless required by applicable law or agreed to in writing,
|
14
|
+
# software distributed under the License is distributed on an
|
15
|
+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
16
|
+
# KIND, either express or implied. See the License for the
|
17
|
+
# specific language governing permissions and limitations
|
18
|
+
# under the License.
|
19
|
+
|
20
|
+
module Selenium
|
21
|
+
module WebDriver
|
22
|
+
#
|
23
|
+
# Wrapper for getting information from the Selenium Manager binaries.
|
24
|
+
# This implementation is still in beta, and may change.
|
25
|
+
# @api private
|
26
|
+
#
|
27
|
+
class SeleniumManager
|
28
|
+
BIN_PATH = "../../../../../bin"
|
29
|
+
|
30
|
+
class << self
|
31
|
+
# @param [String] driver_name which driver to use.
|
32
|
+
# @return [String] the path to the correct driver.
|
33
|
+
def driver_path(driver_name)
|
34
|
+
@driver_path ||= begin
|
35
|
+
unless %w[chromedriver geckodriver msedgedriver].include?(driver_name)
|
36
|
+
msg = "Unable to locate driver with name: #{driver_name}"
|
37
|
+
raise Error::WebDriverError, msg
|
38
|
+
end
|
39
|
+
|
40
|
+
location = run("#{binary} --driver #{driver_name}").split("\t").last.strip
|
41
|
+
WebDriver.logger.debug("Driver found at #{location}")
|
42
|
+
Platform.assert_executable location
|
43
|
+
|
44
|
+
location
|
45
|
+
end
|
46
|
+
end
|
47
|
+
|
48
|
+
private
|
49
|
+
|
50
|
+
# @return [String] the path to the correct selenium manager
|
51
|
+
def binary
|
52
|
+
@binary ||= begin
|
53
|
+
path = File.expand_path(BIN_PATH, __FILE__)
|
54
|
+
path << if Platform.windows?
|
55
|
+
'/windows/selenium-manager.exe'
|
56
|
+
elsif Platform.mac?
|
57
|
+
'/macos/selenium-manager'
|
58
|
+
elsif Platform.linux?
|
59
|
+
'/linux/selenium-manager'
|
60
|
+
end
|
61
|
+
location = File.expand_path(path, __FILE__)
|
62
|
+
unless location.is_a?(String) && File.exist?(location) && File.executable?(location)
|
63
|
+
raise Error::WebDriverError, "Unable to obtain Selenium Manager"
|
64
|
+
end
|
65
|
+
|
66
|
+
WebDriver.logger.debug("Selenium Manager found at #{location}")
|
67
|
+
location
|
68
|
+
end
|
69
|
+
end
|
70
|
+
|
71
|
+
def run(command)
|
72
|
+
WebDriver.logger.debug("Executing Process #{command}")
|
73
|
+
|
74
|
+
begin
|
75
|
+
result = `#{command}`
|
76
|
+
return result if result.match?(/^INFO\t/)
|
77
|
+
rescue StandardError => e
|
78
|
+
raise Error::WebDriverError, "Unsuccessful command executed: #{command}; #{e.message}"
|
79
|
+
end
|
80
|
+
|
81
|
+
raise Error::WebDriverError, "Unsuccessful command executed: #{command}"
|
82
|
+
end
|
83
|
+
end
|
84
|
+
end # SeleniumManager
|
85
|
+
end # WebDriver
|
86
|
+
end # Selenium
|
@@ -80,9 +80,7 @@ module Selenium
|
|
80
80
|
end
|
81
81
|
|
82
82
|
def launch
|
83
|
-
|
84
|
-
sm.start
|
85
|
-
sm
|
83
|
+
ServiceManager.new(self).tap(&:start)
|
86
84
|
end
|
87
85
|
|
88
86
|
def shutdown_supported
|
@@ -101,6 +99,12 @@ module Selenium
|
|
101
99
|
path = path.call if path.is_a?(Proc)
|
102
100
|
path ||= Platform.find_binary(self.class::EXECUTABLE)
|
103
101
|
|
102
|
+
begin
|
103
|
+
path ||= SeleniumManager.driver_path(self.class::EXECUTABLE)
|
104
|
+
rescue Error::WebDriverError => e
|
105
|
+
WebDriver.logger.debug("Unable obtain driver using Selenium Manager; #{e.message}")
|
106
|
+
end
|
107
|
+
|
104
108
|
raise Error::WebDriverError, self.class::MISSING_TEXT unless path
|
105
109
|
|
106
110
|
Platform.assert_executable path
|
@@ -22,6 +22,7 @@ require 'selenium/webdriver/common/platform'
|
|
22
22
|
require 'selenium/webdriver/common/proxy'
|
23
23
|
require 'selenium/webdriver/common/log_entry'
|
24
24
|
require 'selenium/webdriver/common/file_reaper'
|
25
|
+
require 'selenium/webdriver/common/selenium_manager'
|
25
26
|
require 'selenium/webdriver/common/service'
|
26
27
|
require 'selenium/webdriver/common/service_manager'
|
27
28
|
require 'selenium/webdriver/common/socket_lock'
|
@@ -26,11 +26,8 @@ module Selenium
|
|
26
26
|
#
|
27
27
|
|
28
28
|
def initialize(element)
|
29
|
-
unless element.enabled?
|
30
|
-
raise Error::UnsupportedOperationError, 'Select element is disabled and may not be used.'
|
31
|
-
end
|
32
|
-
|
33
29
|
tag_name = element.tag_name
|
30
|
+
|
34
31
|
raise ArgumentError, "unexpected tag name #{tag_name.inspect}" unless tag_name.casecmp('select').zero?
|
35
32
|
|
36
33
|
@element = element
|
data/selenium-webdriver.gemspec
CHANGED
@@ -41,8 +41,11 @@ Gem::Specification.new do |s|
|
|
41
41
|
'lib/selenium-webdriver.rb',
|
42
42
|
'lib/selenium/server.rb',
|
43
43
|
'lib/selenium/webdriver.rb'
|
44
|
-
]
|
44
|
+
]
|
45
|
+
s.files += Dir['bin/**/*']
|
46
|
+
s.files += Dir['lib/selenium/webdriver/**/*']
|
45
47
|
|
48
|
+
s.bindir = 'bin'
|
46
49
|
s.require_paths = ['lib']
|
47
50
|
|
48
51
|
s.add_runtime_dependency 'childprocess', ['>= 0.5', '< 5.0']
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: selenium-webdriver
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.
|
4
|
+
version: 4.6.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Alex Rodionov
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2022-
|
13
|
+
date: 2022-11-04 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: childprocess
|
@@ -271,6 +271,9 @@ files:
|
|
271
271
|
- LICENSE
|
272
272
|
- NOTICE
|
273
273
|
- README.md
|
274
|
+
- bin/linux/selenium-manager
|
275
|
+
- bin/macos/selenium-manager
|
276
|
+
- bin/windows/selenium-manager.exe
|
274
277
|
- lib/selenium-webdriver.rb
|
275
278
|
- lib/selenium/server.rb
|
276
279
|
- lib/selenium/webdriver.rb
|
@@ -351,6 +354,7 @@ files:
|
|
351
354
|
- lib/selenium/webdriver/common/profile_helper.rb
|
352
355
|
- lib/selenium/webdriver/common/proxy.rb
|
353
356
|
- lib/selenium/webdriver/common/search_context.rb
|
357
|
+
- lib/selenium/webdriver/common/selenium_manager.rb
|
354
358
|
- lib/selenium/webdriver/common/service.rb
|
355
359
|
- lib/selenium/webdriver/common/service_manager.rb
|
356
360
|
- lib/selenium/webdriver/common/shadow_root.rb
|
@@ -445,7 +449,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
445
449
|
- !ruby/object:Gem::Version
|
446
450
|
version: 1.3.1
|
447
451
|
requirements: []
|
448
|
-
rubygems_version: 3.0.3
|
452
|
+
rubygems_version: 3.0.3.1
|
449
453
|
signing_key:
|
450
454
|
specification_version: 4
|
451
455
|
summary: Selenium is a browser automation tool for automated testing of webapps and
|