webdriver 0.15.0 → 0.19.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.ruby-version +1 -1
- data/Gemfile.lock +42 -44
- data/bin/console +1 -0
- data/lib/webdriver/client.rb +2 -2
- data/lib/webdriver/connection.rb +9 -1
- data/lib/webdriver/errors.rb +8 -0
- data/lib/webdriver/version.rb +1 -1
- data/webdriver.gemspec +1 -1
- metadata +5 -5
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: d4c89cbaa01804fd96acb76e4ff81fced9130944e8bac4b4dc3326ae96a3d9c0
|
|
4
|
+
data.tar.gz: 9b3dc3b5d4f5fbe4d7d19ba1f3fc2e78f5652b8439d3bceb72a245bbf0b11191
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: acd193961fae95c177cae4d51ecd786fa550eed87c3c5d7875394a0dcdbdd68d3bb97f3e7e3b00f4aebd2150af6bcf02995c19bdc685bf9ada768c7db9b5601d
|
|
7
|
+
data.tar.gz: ccc44f6df0eb131812b297a8eee289b41f36a438747de14d8478a6c74e7dceebbba44a0c7c7609581dcae881101753b320ffce4a462d73ea6f7f736e6ae08675
|
data/.ruby-version
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
3.0.2
|
data/Gemfile.lock
CHANGED
|
@@ -1,26 +1,26 @@
|
|
|
1
1
|
PATH
|
|
2
2
|
remote: .
|
|
3
3
|
specs:
|
|
4
|
-
webdriver (0.
|
|
4
|
+
webdriver (0.19.0)
|
|
5
5
|
|
|
6
6
|
GEM
|
|
7
7
|
remote: https://rubygems.org/
|
|
8
8
|
specs:
|
|
9
|
-
binding_of_caller (0.
|
|
9
|
+
binding_of_caller (1.0.0)
|
|
10
10
|
debug_inspector (>= 0.0.1)
|
|
11
|
-
byebug (11.
|
|
12
|
-
coderay (1.1.
|
|
13
|
-
debug_inspector (
|
|
14
|
-
diff-lcs (1.
|
|
15
|
-
ffi (1.
|
|
16
|
-
formatador (0.
|
|
17
|
-
guard (2.
|
|
11
|
+
byebug (11.1.3)
|
|
12
|
+
coderay (1.1.3)
|
|
13
|
+
debug_inspector (1.1.0)
|
|
14
|
+
diff-lcs (1.4.4)
|
|
15
|
+
ffi (1.15.3)
|
|
16
|
+
formatador (0.3.0)
|
|
17
|
+
guard (2.18.0)
|
|
18
18
|
formatador (>= 0.2.4)
|
|
19
19
|
listen (>= 2.7, < 4.0)
|
|
20
20
|
lumberjack (>= 1.0.12, < 2.0)
|
|
21
21
|
nenv (~> 0.1)
|
|
22
22
|
notiffany (~> 0.0)
|
|
23
|
-
pry (>= 0.
|
|
23
|
+
pry (>= 0.13.0)
|
|
24
24
|
shellany (~> 0.0)
|
|
25
25
|
thor (>= 0.18.1)
|
|
26
26
|
guard-compat (1.2.1)
|
|
@@ -29,54 +29,52 @@ GEM
|
|
|
29
29
|
guard-compat (~> 1.1)
|
|
30
30
|
rspec (>= 2.99.0, < 4.0)
|
|
31
31
|
interception (0.5)
|
|
32
|
-
listen (3.
|
|
33
|
-
rb-fsevent (~> 0.
|
|
34
|
-
rb-inotify (~> 0.9, >= 0.9.
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
method_source (0.9.2)
|
|
32
|
+
listen (3.7.0)
|
|
33
|
+
rb-fsevent (~> 0.10, >= 0.10.3)
|
|
34
|
+
rb-inotify (~> 0.9, >= 0.9.10)
|
|
35
|
+
lumberjack (1.2.8)
|
|
36
|
+
method_source (1.0.0)
|
|
38
37
|
nenv (0.3.0)
|
|
39
|
-
notiffany (0.1.
|
|
38
|
+
notiffany (0.1.3)
|
|
40
39
|
nenv (~> 0.1)
|
|
41
40
|
shellany (~> 0.0)
|
|
42
|
-
pry (0.
|
|
43
|
-
coderay (~> 1.1
|
|
44
|
-
method_source (~>
|
|
45
|
-
pry-byebug (3.
|
|
41
|
+
pry (0.13.1)
|
|
42
|
+
coderay (~> 1.1)
|
|
43
|
+
method_source (~> 1.0)
|
|
44
|
+
pry-byebug (3.9.0)
|
|
46
45
|
byebug (~> 11.0)
|
|
47
|
-
pry (~> 0.
|
|
48
|
-
pry-rescue (1.5.
|
|
46
|
+
pry (~> 0.13.0)
|
|
47
|
+
pry-rescue (1.5.2)
|
|
49
48
|
interception (>= 0.5)
|
|
50
49
|
pry (>= 0.12.0)
|
|
51
|
-
pry-stack_explorer (0.
|
|
52
|
-
binding_of_caller (
|
|
53
|
-
pry (
|
|
50
|
+
pry-stack_explorer (0.6.1)
|
|
51
|
+
binding_of_caller (~> 1.0)
|
|
52
|
+
pry (~> 0.13)
|
|
54
53
|
rake (10.5.0)
|
|
55
|
-
rb-fsevent (0.
|
|
56
|
-
rb-inotify (0.10.
|
|
54
|
+
rb-fsevent (0.11.0)
|
|
55
|
+
rb-inotify (0.10.1)
|
|
57
56
|
ffi (~> 1.0)
|
|
58
|
-
rspec (3.
|
|
59
|
-
rspec-core (~> 3.
|
|
60
|
-
rspec-expectations (~> 3.
|
|
61
|
-
rspec-mocks (~> 3.
|
|
62
|
-
rspec-core (3.
|
|
63
|
-
rspec-support (~> 3.
|
|
64
|
-
rspec-expectations (3.
|
|
57
|
+
rspec (3.10.0)
|
|
58
|
+
rspec-core (~> 3.10.0)
|
|
59
|
+
rspec-expectations (~> 3.10.0)
|
|
60
|
+
rspec-mocks (~> 3.10.0)
|
|
61
|
+
rspec-core (3.10.1)
|
|
62
|
+
rspec-support (~> 3.10.0)
|
|
63
|
+
rspec-expectations (3.10.1)
|
|
65
64
|
diff-lcs (>= 1.2.0, < 2.0)
|
|
66
|
-
rspec-support (~> 3.
|
|
67
|
-
rspec-mocks (3.
|
|
65
|
+
rspec-support (~> 3.10.0)
|
|
66
|
+
rspec-mocks (3.10.2)
|
|
68
67
|
diff-lcs (>= 1.2.0, < 2.0)
|
|
69
|
-
rspec-support (~> 3.
|
|
70
|
-
rspec-support (3.
|
|
71
|
-
ruby_dep (1.5.0)
|
|
68
|
+
rspec-support (~> 3.10.0)
|
|
69
|
+
rspec-support (3.10.2)
|
|
72
70
|
shellany (0.0.1)
|
|
73
|
-
thor (
|
|
71
|
+
thor (1.1.0)
|
|
74
72
|
|
|
75
73
|
PLATFORMS
|
|
76
|
-
|
|
74
|
+
x86_64-darwin-20
|
|
77
75
|
|
|
78
76
|
DEPENDENCIES
|
|
79
|
-
bundler (~>
|
|
77
|
+
bundler (~> 2.2)
|
|
80
78
|
guard
|
|
81
79
|
guard-rspec
|
|
82
80
|
pry-byebug
|
|
@@ -87,4 +85,4 @@ DEPENDENCIES
|
|
|
87
85
|
webdriver!
|
|
88
86
|
|
|
89
87
|
BUNDLED WITH
|
|
90
|
-
|
|
88
|
+
2.2.26
|
data/bin/console
CHANGED
data/lib/webdriver/client.rb
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
module Webdriver
|
|
2
2
|
class Client
|
|
3
|
-
def initialize(endpoint, desired_capabilities={})
|
|
3
|
+
def initialize(endpoint, desired_capabilities={}, opts={})
|
|
4
4
|
uri = URI(endpoint)
|
|
5
|
-
@connection = Webdriver::Connection.new endpoint
|
|
5
|
+
@connection = Webdriver::Connection.new endpoint, **opts
|
|
6
6
|
@desired_capabilities = desired_capabilities
|
|
7
7
|
end
|
|
8
8
|
|
data/lib/webdriver/connection.rb
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
module Webdriver
|
|
2
2
|
class Connection
|
|
3
|
-
def initialize
|
|
3
|
+
def initialize(endpoint, open_timeout: 3, read_timeout: 5, write_timeout: 5)
|
|
4
4
|
uri = URI(endpoint)
|
|
5
5
|
@http = Net::HTTP.new uri.hostname, uri.port
|
|
6
6
|
@http.open_timeout = open_timeout
|
|
@@ -68,6 +68,14 @@ module Webdriver
|
|
|
68
68
|
raise Webdriver::ElementNotInteractableError.new path
|
|
69
69
|
when 13
|
|
70
70
|
raise Webdriver::UnknownErrorUnhandledInspectorError.new value.dig("message")
|
|
71
|
+
when 17
|
|
72
|
+
raise Webdriver::JavascriptError.new value.dig("message")
|
|
73
|
+
when 23
|
|
74
|
+
raise Webdriver::NoSuchWindow.new value.dig("message")
|
|
75
|
+
when 26
|
|
76
|
+
raise Webdriver::UnexpectedAlertOpen.new value.dig("message")
|
|
77
|
+
when 27
|
|
78
|
+
raise Webdriver::NoSuchAlert.new value.dig("message")
|
|
71
79
|
when 28
|
|
72
80
|
raise Webdriver::ScriptTimeout.new value.dig("message")
|
|
73
81
|
when 1..nil
|
data/lib/webdriver/errors.rb
CHANGED
|
@@ -9,6 +9,14 @@ module Webdriver
|
|
|
9
9
|
class ElementNotInteractableError < StandardError; end
|
|
10
10
|
# 13
|
|
11
11
|
class UnknownErrorUnhandledInspectorError < StandardError; end
|
|
12
|
+
# 17
|
|
13
|
+
class JavascriptError < StandardError; end
|
|
14
|
+
# 23
|
|
15
|
+
class NoSuchWindow < StandardError; end
|
|
16
|
+
# 26
|
|
17
|
+
class UnexpectedAlertOpen < StandardError; end
|
|
18
|
+
# 27
|
|
19
|
+
class NoSuchAlert < StandardError; end
|
|
12
20
|
# 28
|
|
13
21
|
class ScriptTimeout < StandardError; end
|
|
14
22
|
end
|
data/lib/webdriver/version.rb
CHANGED
data/webdriver.gemspec
CHANGED
|
@@ -23,7 +23,7 @@ Gem::Specification.new do |spec|
|
|
|
23
23
|
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
|
24
24
|
spec.require_paths = ["lib"]
|
|
25
25
|
|
|
26
|
-
spec.add_development_dependency "bundler", "~>
|
|
26
|
+
spec.add_development_dependency "bundler", "~> 2.2"
|
|
27
27
|
spec.add_development_dependency "rake", "~> 10.0"
|
|
28
28
|
spec.add_development_dependency "rspec", "~> 3.0"
|
|
29
29
|
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: webdriver
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.19.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Matti Paksula
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date:
|
|
11
|
+
date: 2021-09-01 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: bundler
|
|
@@ -16,14 +16,14 @@ dependencies:
|
|
|
16
16
|
requirements:
|
|
17
17
|
- - "~>"
|
|
18
18
|
- !ruby/object:Gem::Version
|
|
19
|
-
version: '
|
|
19
|
+
version: '2.2'
|
|
20
20
|
type: :development
|
|
21
21
|
prerelease: false
|
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
|
23
23
|
requirements:
|
|
24
24
|
- - "~>"
|
|
25
25
|
- !ruby/object:Gem::Version
|
|
26
|
-
version: '
|
|
26
|
+
version: '2.2'
|
|
27
27
|
- !ruby/object:Gem::Dependency
|
|
28
28
|
name: rake
|
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -182,7 +182,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
182
182
|
- !ruby/object:Gem::Version
|
|
183
183
|
version: '0'
|
|
184
184
|
requirements: []
|
|
185
|
-
rubygems_version: 3.
|
|
185
|
+
rubygems_version: 3.2.22
|
|
186
186
|
signing_key:
|
|
187
187
|
specification_version: 4
|
|
188
188
|
summary: webdriver
|