effective_test_bot 1.5.7 → 1.5.9
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
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d7de769d60d59f161b3606b64719f254251dea7834310e440be28ea831263fa5
|
4
|
+
data.tar.gz: 1979f907166f5a0b445e1498b50bd4476700db1f737b0dea7b92a6dad2277d76
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: '069bb7337b7bb695e4b98c849dc2a939dfe44e082a34ef9259b1b2b2ab50053f9b2fbb98b4190ed04ffc8d718c771c35396488753f02bee94f3e72d4d23d49b8'
|
7
|
+
data.tar.gz: 762721642757acfdae3953a6de328a306fb798d445e03fcd76a4004fb02f28e67b771392ccf4646948f4d2ea8e1da7a9cbcba2204a24695057e1f2cb68eb6b9e
|
@@ -206,7 +206,7 @@ module EffectiveTestBotAssertions
|
|
206
206
|
assert errors.blank?, message || "(no_assigns_errors) Unexpected @#{key} rails validation errors:\n#{errors}"
|
207
207
|
else
|
208
208
|
assigns.each do |key, value|
|
209
|
-
errors = value['errors'] if value.respond_to?(:[])
|
209
|
+
errors = (value['errors'] rescue false) if value.respond_to?(:[])
|
210
210
|
assert errors.blank?, message || "(no_assigns_errors) Unexpected @#{key} rails validation errors:\n#{errors}"
|
211
211
|
end
|
212
212
|
end
|
@@ -123,6 +123,29 @@ module EffectiveTestBotFormHelper
|
|
123
123
|
true
|
124
124
|
end
|
125
125
|
|
126
|
+
def submit_deluxe_checkout(success_content: nil)
|
127
|
+
deluxe_checkout_iframe = find('iframe[id=dppjssdk]')
|
128
|
+
assert deluxe_checkout_iframe.present?, 'unable to find deluxe checkout iframe'
|
129
|
+
|
130
|
+
before_path = page.current_path
|
131
|
+
|
132
|
+
within_frame(deluxe_checkout_iframe) do
|
133
|
+
find('input[id=ccNum]').set("4242424242424242")
|
134
|
+
find('input[id=ccExpry]').set("12#{Time.zone.now.year - 1999}")
|
135
|
+
find('input[id=ccCvv]').set("123")
|
136
|
+
find_submit.click
|
137
|
+
end
|
138
|
+
|
139
|
+
# This is a blocking selector that will wait until the page has changed url
|
140
|
+
assert_no_current_path(before_path.to_s, wait: Capybara.default_max_wait_time * 10)
|
141
|
+
|
142
|
+
if success_content
|
143
|
+
assert page.has_content?(success_content, wait: Capybara.default_max_wait_time * 10), "#{success_content} not found"
|
144
|
+
end
|
145
|
+
|
146
|
+
true
|
147
|
+
end
|
148
|
+
|
126
149
|
def clear_form
|
127
150
|
all('input,select,textarea', wait: false).each do |field|
|
128
151
|
if effective_select_input?(field)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: effective_test_bot
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.5.
|
4
|
+
version: 1.5.9
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Code and Effect
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-05-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|