effective_test_bot 1.3.10 → 1.3.12

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 1ce08c69a8ac37db1190f5f1ba8f7b8a9cbb525c16cc5dd9dd7302a076148547
4
- data.tar.gz: 7a727c1788d1bef09437de7780bf8baac81b726a31e4d932b688fa8fc3ca5b4f
3
+ metadata.gz: 168ba420f05b70c4da7680017805d1c558cdb0eaf34c3785b0c4ecd97ff257e7
4
+ data.tar.gz: e018ed74f5f1f594d54797b567bd9c9d95a582a7a5a84a466546ffb34b4818ab
5
5
  SHA512:
6
- metadata.gz: 3451c2c4acd57b920936fdaaf2e882d6135277ddc98c17d540d66055ade93cf34d919d420f812162c7a65f0fc80f097961ec44d59fcd3933c182d18ab067dafc
7
- data.tar.gz: b571d464032586c65db12c6eb699d46f58158ed11aab8c3ab05a6ecf18d71f41714c520cdca7eb977511b2f82aa371c78859ec9a49ca694eea64ccc327bf31ef
6
+ metadata.gz: 4651bc832a47bdf0ed291fcddeb9bbfa04bdaff053c54ba9cc8ef6bf2903ccfd125751f04a30e481e5b69ae7ae14a3b4613e9006994120d71e134c6cab207097
7
+ data.tar.gz: eccb4965b8d3a3e01a15bdd174815265e0a127948ceb6dc0aa7869500be5262eb6003bc7697759ef6d02d0352c85ca7b3dd2355a688c861540996c26f072d5ac
@@ -1,3 +1,3 @@
1
1
  module EffectiveTestBot
2
- VERSION = '1.3.10'.freeze
2
+ VERSION = '1.3.12'.freeze
3
3
  end
@@ -38,7 +38,7 @@ module EffectiveTestBotFormHelper
38
38
  assert_no_assigns_errors unless test_bot_skip?(:no_assigns_errors)
39
39
 
40
40
  # This is a blocking selector that will wait until the page has changed url
41
- assert_no_current_path(before_path)
41
+ assert_no_current_path(before_path.to_s)
42
42
 
43
43
  assert_no_exceptions unless test_bot_skip?(:exceptions)
44
44
  assert_authorization unless test_bot_skip?(:authorization)
@@ -152,7 +152,8 @@ module EffectiveTestBotFormHelper
152
152
 
153
153
  if label.present?
154
154
  submit = (find("input[type='submit'][value='#{label}'],button[type='submit'][value='#{label}']", match: :first) rescue nil)
155
- submit ||= find(:link_or_button, label, match: :first)
155
+ submit ||= (find(:link_or_button, label, match: :first) rescue nil)
156
+ submit ||= all('a', text: label).first
156
157
 
157
158
  if last
158
159
  submit = all("input[type='submit'][value='#{label}'],button[type='submit'][value='#{label}']").last
@@ -105,7 +105,8 @@ module EffectiveTestBotTestHelper
105
105
  end
106
106
 
107
107
  def assigns(key = nil)
108
- assigns = (page.evaluate_script('window.effective_test_bot.assigns') rescue nil) || {}
108
+ assigns = (page.evaluate_script('window.effective_test_bot.assigns') rescue nil)
109
+ assigns = {} unless assigns.kind_of?(Hash)
109
110
  key ? assigns[key.to_s] : assigns
110
111
  end
111
112
 
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.3.10
4
+ version: 1.3.12
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: 2022-09-19 00:00:00.000000000 Z
11
+ date: 2022-09-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails