automation_helpers 6.0 → 7.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/lib/automation_helpers/drivers/v4/browserstack.rb +1 -1
- data/lib/automation_helpers/drivers/v4/capabilities.rb +1 -2
- data/lib/automation_helpers/patches/{capybara.rb → capybara_safari.rb} +9 -1
- data/lib/automation_helpers/patches/capybara_window.rb +38 -0
- data/lib/automation_helpers/patches.rb +2 -1
- data/lib/automation_helpers/version.rb +1 -1
- metadata +10 -9
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: de65c70c0d33f66469440532cf8a4d49840e8b4e48cc653dca9fc2d20280c9ee
|
|
4
|
+
data.tar.gz: b79dfae24f4df076559ddb46270b32ef2ab5168f3e12b1f3565a060d5673fc3a
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 0febf6c2eaba22e6bda884a435388e57967aea3f8556f68a7f445be96a1a9534ee980cf4e80fc0731694185e716f9734c714b9d6747f31e516ae2236446e196e
|
|
7
|
+
data.tar.gz: eda61bc6fb061175fa91d996661748143fa0ae962257b1bc9ead36827e0a469b75285bf77257c48e8f69e1779c01dee0776276acac51496e464f9a9b2cca0557
|
|
@@ -61,8 +61,7 @@ module AutomationHelpers
|
|
|
61
61
|
'browserName' => 'internet explorer',
|
|
62
62
|
'bstack:options' => {
|
|
63
63
|
'ie' => {
|
|
64
|
-
# This
|
|
65
|
-
# It is confirmed to be compliant with V4 selenium jars e.t.c.
|
|
64
|
+
# This appears to be the last maintained version and we will remove IE support in V8 of helpers
|
|
66
65
|
'driver' => '4.16.0.0',
|
|
67
66
|
'arch' => 'x32'
|
|
68
67
|
}
|
|
@@ -5,7 +5,7 @@ module AutomationHelpers
|
|
|
5
5
|
#
|
|
6
6
|
# Fix the issue where the `#text` method doesn't normalize whitespace (Only the matchers do)
|
|
7
7
|
#
|
|
8
|
-
class
|
|
8
|
+
class CapybaraSafari < Base
|
|
9
9
|
private
|
|
10
10
|
|
|
11
11
|
def description
|
|
@@ -19,6 +19,14 @@ module AutomationHelpers
|
|
|
19
19
|
def perform
|
|
20
20
|
::Capybara::Node::Element.prepend SafariTextPatch
|
|
21
21
|
end
|
|
22
|
+
|
|
23
|
+
def deprecate?
|
|
24
|
+
true
|
|
25
|
+
end
|
|
26
|
+
|
|
27
|
+
def prevent_usage_date
|
|
28
|
+
Time.new(2027, 3, 30)
|
|
29
|
+
end
|
|
22
30
|
end
|
|
23
31
|
|
|
24
32
|
#
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module AutomationHelpers
|
|
4
|
+
module Patches
|
|
5
|
+
#
|
|
6
|
+
# Fix the issue where you cannot close the first window in the handle array with `#close_window`
|
|
7
|
+
#
|
|
8
|
+
class CapybaraWindow < Base
|
|
9
|
+
private
|
|
10
|
+
|
|
11
|
+
def description
|
|
12
|
+
<<~DESCRIPTION
|
|
13
|
+
The method `#close_window` in Capybara::Selenium::Driver (Base), does not permit closing of the first window in the handle array
|
|
14
|
+
|
|
15
|
+
This was introduced over a decade ago and given the propensity for new windows to be opened in the course of testing,
|
|
16
|
+
this is a significant issue for users of Capybara and Selenium.
|
|
17
|
+
|
|
18
|
+
See https://github.com/teamcapybara/capybara/issues/2834 for more details.
|
|
19
|
+
DESCRIPTION
|
|
20
|
+
end
|
|
21
|
+
|
|
22
|
+
def perform
|
|
23
|
+
::Capybara::Selenium::Driver.prepend WindowPatch
|
|
24
|
+
end
|
|
25
|
+
end
|
|
26
|
+
|
|
27
|
+
#
|
|
28
|
+
# @api private
|
|
29
|
+
#
|
|
30
|
+
module WindowPatch
|
|
31
|
+
def close_window(handle)
|
|
32
|
+
within_given_window(handle) do
|
|
33
|
+
browser.close
|
|
34
|
+
end
|
|
35
|
+
end
|
|
36
|
+
end
|
|
37
|
+
end
|
|
38
|
+
end
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
3
|
require 'automation_helpers/patches/base'
|
|
4
|
-
require 'automation_helpers/patches/
|
|
4
|
+
require 'automation_helpers/patches/capybara_safari'
|
|
5
|
+
require 'automation_helpers/patches/capybara_window'
|
|
5
6
|
require 'automation_helpers/patches/selenium_logger'
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: automation_helpers
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: '
|
|
4
|
+
version: '7.0'
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Luke Hill
|
|
@@ -9,7 +9,7 @@ authors:
|
|
|
9
9
|
autorequire:
|
|
10
10
|
bindir: bin
|
|
11
11
|
cert_chain: []
|
|
12
|
-
date: 2026-
|
|
12
|
+
date: 2026-03-06 00:00:00.000000000 Z
|
|
13
13
|
dependencies:
|
|
14
14
|
- !ruby/object:Gem::Dependency
|
|
15
15
|
name: capybara
|
|
@@ -85,14 +85,14 @@ dependencies:
|
|
|
85
85
|
requirements:
|
|
86
86
|
- - "~>"
|
|
87
87
|
- !ruby/object:Gem::Version
|
|
88
|
-
version: 1.
|
|
88
|
+
version: 1.85.1
|
|
89
89
|
type: :development
|
|
90
90
|
prerelease: false
|
|
91
91
|
version_requirements: !ruby/object:Gem::Requirement
|
|
92
92
|
requirements:
|
|
93
93
|
- - "~>"
|
|
94
94
|
- !ruby/object:Gem::Version
|
|
95
|
-
version: 1.
|
|
95
|
+
version: 1.85.1
|
|
96
96
|
- !ruby/object:Gem::Dependency
|
|
97
97
|
name: rubocop-performance
|
|
98
98
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -113,14 +113,14 @@ dependencies:
|
|
|
113
113
|
requirements:
|
|
114
114
|
- - "~>"
|
|
115
115
|
- !ruby/object:Gem::Version
|
|
116
|
-
version: 3.
|
|
116
|
+
version: 3.9.0
|
|
117
117
|
type: :development
|
|
118
118
|
prerelease: false
|
|
119
119
|
version_requirements: !ruby/object:Gem::Requirement
|
|
120
120
|
requirements:
|
|
121
121
|
- - "~>"
|
|
122
122
|
- !ruby/object:Gem::Version
|
|
123
|
-
version: 3.
|
|
123
|
+
version: 3.9.0
|
|
124
124
|
- !ruby/object:Gem::Dependency
|
|
125
125
|
name: selenium-webdriver
|
|
126
126
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -165,7 +165,8 @@ files:
|
|
|
165
165
|
- lib/automation_helpers/extensions/string.rb
|
|
166
166
|
- lib/automation_helpers/patches.rb
|
|
167
167
|
- lib/automation_helpers/patches/base.rb
|
|
168
|
-
- lib/automation_helpers/patches/
|
|
168
|
+
- lib/automation_helpers/patches/capybara_safari.rb
|
|
169
|
+
- lib/automation_helpers/patches/capybara_window.rb
|
|
169
170
|
- lib/automation_helpers/patches/selenium_logger.rb
|
|
170
171
|
- lib/automation_helpers/version.rb
|
|
171
172
|
homepage: https://www.github.com/site-prism/automation_helpers
|
|
@@ -183,14 +184,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
183
184
|
requirements:
|
|
184
185
|
- - ">="
|
|
185
186
|
- !ruby/object:Gem::Version
|
|
186
|
-
version: '3.
|
|
187
|
+
version: '3.3'
|
|
187
188
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
188
189
|
requirements:
|
|
189
190
|
- - ">="
|
|
190
191
|
- !ruby/object:Gem::Version
|
|
191
192
|
version: 3.2.8
|
|
192
193
|
requirements: []
|
|
193
|
-
rubygems_version: 3.
|
|
194
|
+
rubygems_version: 3.5.22
|
|
194
195
|
signing_key:
|
|
195
196
|
specification_version: 4
|
|
196
197
|
summary: Automation Helpers - Avoid writing the most common things in Ruby Automation
|