spree_core 3.7.3 → 3.7.4

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: d659f0992a4f2aa8af409c5cbd50f1e824b39bae09cc69a107990abf4e557120
4
- data.tar.gz: 41babfa431effea64e542e2698f6ed74054e489e5f5075e2841590fd76857b7a
3
+ metadata.gz: 774c90c77ecce68c19e7a9c8b719acfc3b538dc28b0105197e3dfc8e70305f39
4
+ data.tar.gz: 8e7af8eefc7e78e2c2c8493c141e3bfe55a3c21cf1029e85dcb10dedab01ef1d
5
5
  SHA512:
6
- metadata.gz: 0ca1f7d8862e25123578e339dab67e71259a9572ebb3edb28e7c4e720b5d2f4e34b2accf904aa6cf59468aeb2137cbb38268f22517d4d58efd01d4051b753022
7
- data.tar.gz: bf207628a2fbff24f23e7bacf6f357a0b3efc95075e19ec95671a5b667a34fc314c91895e6b8e84f9ab2ed025e18c6314cae77a224e0acf7a759a0fa161a3f72
6
+ metadata.gz: 33067deb1eb41c1fdb4c53349128a38d08d3b63d583d34c045ff7f568c0770172ad57289a0b443575d5eb3a4768c03b0a409160d7f8fb7cb781088a20e4d17d6
7
+ data.tar.gz: e72e7b98758615bc60e750a8e713cdd5290f6a037fd56919b24790ea3d91f21a67cf9ad15af20f78418c2e79ee9092dc884bc03d8cd9cc98087d7bc2dde5cde6
@@ -1,5 +1,5 @@
1
1
  module Spree
2
2
  def self.version
3
- '3.7.3'
3
+ '3.7.4'
4
4
  end
5
5
  end
@@ -9,7 +9,10 @@ else
9
9
  Capybara.register_driver :chrome do |app|
10
10
  Capybara::Selenium::Driver.new app,
11
11
  browser: :chrome,
12
- options: Selenium::WebDriver::Chrome::Options.new(args: %w[disable-popup-blocking headless disable-gpu window-size=1920,1080])
12
+ options: Selenium::WebDriver::Chrome::Options.new(
13
+ args: %w[disable-popup-blocking headless disable-gpu window-size=1920,1080],
14
+ log_level: :error
15
+ )
13
16
  end
14
17
  Capybara.javascript_driver = :chrome
15
18
 
@@ -134,7 +134,7 @@ module CapybaraExt
134
134
 
135
135
  def spree_accept_alert
136
136
  yield
137
- rescue Selenium::WebDriver::Error::UnhandledAlertError
137
+ rescue Selenium::WebDriver::Error::UnhandledAlertError, Selenium::WebDriver::Error::NoSuchAlertError
138
138
  Selenium::WebDriver::Wait.new(timeout: 5)
139
139
  .until { page.driver.browser.switch_to.alert }
140
140
  .accept
@@ -143,6 +143,22 @@ module CapybaraExt
143
143
  def disable_html5_validation
144
144
  page.execute_script('for(var f=document.forms,i=f.length;i--;)f[i].setAttribute("novalidate",i)')
145
145
  end
146
+
147
+ def handle_js_confirm(accept = true)
148
+ page.evaluate_script 'window.original_confirm_function = window.confirm'
149
+ page.evaluate_script "window.confirm = function(msg) { return #{accept}; }"
150
+ yield
151
+ ensure
152
+ page.evaluate_script 'window.confirm = window.original_confirm_function'
153
+ end
154
+ end
155
+
156
+ def wait_for(options = {})
157
+ default_options = { error: nil, seconds: 5 }.merge(options)
158
+
159
+ Selenium::WebDriver::Wait.new(timeout: default_options[:seconds]).until { yield }
160
+ rescue Selenium::WebDriver::Error::TimeOutError
161
+ default_options[:error].nil? ? false : raise(default_options[:error])
146
162
  end
147
163
 
148
164
  def wait_for(options = {})
data/spree_core.gemspec CHANGED
@@ -43,7 +43,7 @@ Gem::Specification.new do |s|
43
43
  s.add_dependency 'stringex'
44
44
  s.add_dependency 'twitter_cldr', '~> 4.3'
45
45
  s.add_dependency 'sprockets-rails'
46
- s.add_dependency 'mini_magick', '~> 4.8.0'
46
+ s.add_dependency 'mini_magick', '~> 4.9.4'
47
47
 
48
48
  s.add_development_dependency 'email_spec', '~> 1.6'
49
49
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: spree_core
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.7.3
4
+ version: 3.7.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sean Schofield
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-05-15 00:00:00.000000000 Z
11
+ date: 2019-08-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activemerchant
@@ -344,14 +344,14 @@ dependencies:
344
344
  requirements:
345
345
  - - "~>"
346
346
  - !ruby/object:Gem::Version
347
- version: 4.8.0
347
+ version: 4.9.4
348
348
  type: :runtime
349
349
  prerelease: false
350
350
  version_requirements: !ruby/object:Gem::Requirement
351
351
  requirements:
352
352
  - - "~>"
353
353
  - !ruby/object:Gem::Version
354
- version: 4.8.0
354
+ version: 4.9.4
355
355
  - !ruby/object:Gem::Dependency
356
356
  name: email_spec
357
357
  requirement: !ruby/object:Gem::Requirement