solidus_frontend 1.3.2 → 1.4.0.beta1

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of solidus_frontend might be problematic. Click here for more details.

Files changed (31) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +3 -10
  3. data/app/assets/javascripts/spree/frontend/checkout/coupon-code.js.coffee +34 -0
  4. data/app/assets/javascripts/spree/frontend/checkout/payment.js.coffee +0 -36
  5. data/app/assets/javascripts/spree/frontend/checkout.js.coffee +5 -4
  6. data/app/assets/stylesheets/spree/frontend/screen.css.scss +1 -1
  7. data/app/controllers/spree/checkout_controller.rb +3 -3
  8. data/app/controllers/spree/orders_controller.rb +9 -4
  9. data/app/controllers/spree/products_controller.rb +6 -1
  10. data/app/controllers/spree/store_controller.rb +1 -1
  11. data/app/views/spree/checkout/_payment.html.erb +6 -0
  12. data/app/views/spree/layouts/spree_application.html.erb +1 -1
  13. data/config/routes.rb +2 -7
  14. data/solidus_frontend.gemspec +1 -1
  15. data/spec/controllers/controller_extension_spec.rb +5 -5
  16. data/spec/controllers/controller_helpers_spec.rb +1 -1
  17. data/spec/controllers/spree/checkout_controller_spec.rb +50 -95
  18. data/spec/controllers/spree/checkout_controller_with_views_spec.rb +1 -1
  19. data/spec/controllers/spree/content_controller_spec.rb +1 -1
  20. data/spec/controllers/spree/current_order_tracking_spec.rb +3 -3
  21. data/spec/controllers/spree/home_controller_spec.rb +3 -3
  22. data/spec/controllers/spree/orders_controller_ability_spec.rb +12 -12
  23. data/spec/controllers/spree/orders_controller_spec.rb +9 -9
  24. data/spec/controllers/spree/orders_controller_transitions_spec.rb +1 -1
  25. data/spec/controllers/spree/products_controller_spec.rb +4 -4
  26. data/spec/controllers/spree/taxons_controller_spec.rb +1 -1
  27. data/spec/features/checkout_spec.rb +10 -11
  28. data/spec/features/checkout_unshippable_spec.rb +1 -1
  29. data/spec/features/products_spec.rb +15 -0
  30. data/spec/spec_helper.rb +1 -1
  31. metadata +12 -11
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ec0a60cd964cb481ad0404e8c0a18c1469c997dc
4
- data.tar.gz: 366cef2fc5b46bf08d246a2c0aad1fbfdbab0c42
3
+ metadata.gz: 111fd307fe43d1f1a14dbb8b4fed5f1213f01042
4
+ data.tar.gz: 8764df5f034dc79a7d17c6280e341289a470a602
5
5
  SHA512:
6
- metadata.gz: f5a0bcc818038753a5715a8d196ba1b4a4555d8314c111b454bc13fa82a30dbd7ccd9ee9b2dc76b6c905ed94f4b11f454745734f2d64e1882f251834b88f0ce7
7
- data.tar.gz: e4c70d0029b2f0b740d35b9635c539ba6ace1164d4326edd989c34ae2de5fa03041eab83d61eb287031b42bf0639b27d354b9b9db14b1be5fe40b67f9fc301e0
6
+ metadata.gz: a0598c73595c2e08fc1ff92f7916f2cb4c4e54adbb534536367b42b0ceb14e1db3781918a29a45b437c74ec1dcc82ae66962bf1fc5881c8dbf676380ff98a55f
7
+ data.tar.gz: 64841adb0db0a35c7dbb8e868472da68c153ccc7d3c2d3cdfc9aede5f35be91a939ef330fb4c0f9b6cc1f7746ecf0e7200c6617e533a5d23e1bccd019f99c6af
data/README.md CHANGED
@@ -1,11 +1,9 @@
1
- Core
2
- ====
1
+ # solidus\_frontend
3
2
 
4
- Core e-commerce functionality for the Spree project
3
+ Frontend contains controllers and views implementing a storefront and cart for Solidus.
5
4
 
6
5
 
7
- Testing
8
- -------
6
+ ## Testing
9
7
 
10
8
  Create the test site
11
9
 
@@ -14,8 +12,3 @@ Create the test site
14
12
  Run the tests
15
13
 
16
14
  bundle exec rake spec
17
-
18
- Run the coverage. After the rake task open coverage/index.html
19
-
20
- bundle exec rake rcov
21
-
@@ -0,0 +1,34 @@
1
+ Spree.onCouponCodeApply = (e) ->
2
+ couponCodeField = $('#order_coupon_code')
3
+ couponCode = $.trim(couponCodeField.val())
4
+ return if couponCode == ''
5
+
6
+ couponStatus = $("#coupon_status")
7
+ successClass = 'success'
8
+ errorClass = 'alert'
9
+ url = Spree.url(Spree.routes.apply_coupon_code(Spree.current_order_id),
10
+ {
11
+ order_token: Spree.current_order_token,
12
+ coupon_code: couponCode
13
+ }
14
+ )
15
+
16
+ couponStatus.removeClass([successClass,errorClass].join(" "));
17
+
18
+ req = Spree.ajax
19
+ method: "PUT",
20
+ url: url
21
+
22
+ req.done (data) ->
23
+ window.location.reload();
24
+ couponCodeField.val('')
25
+ couponStatus.addClass(successClass).html("Coupon code applied successfully.")
26
+
27
+ req.fail (xhr) ->
28
+ # handler = JSON.parse(xhr.responseText)
29
+ handler = xhr.responseJSON
30
+ couponStatus.addClass(errorClass).html(handler["error"])
31
+
32
+ Spree.ready ($) ->
33
+ $('#coupon-code-apply-button').click (e) ->
34
+ Spree.onCouponCodeApply(e)
@@ -40,40 +40,4 @@ Spree.ready ($) ->
40
40
  # i.e. if user enters invalid data
41
41
  ($ 'input[type="radio"]:checked').click()
42
42
 
43
- $('#checkout_form_payment').submit ->
44
- # Coupon code application may take a number of seconds.
45
- # Informing the user that this is happening is a good way to indicate some progress to them.
46
- # In addition to this, if the coupon code FAILS then they don't lose their just-entered payment data.
47
- coupon_code_field = $('#order_coupon_code')
48
- coupon_code = $.trim(coupon_code_field.val())
49
- if (coupon_code != '')
50
- if $('#coupon_status').length == 0
51
- coupon_status = $("<div id='coupon_status'></div>")
52
- coupon_code_field.parent().append(coupon_status)
53
- else
54
- coupon_status = $("#coupon_status")
55
-
56
- url = Spree.url(Spree.routes.apply_coupon_code(Spree.current_order_id),
57
- {
58
- order_token: Spree.current_order_token,
59
- coupon_code: coupon_code
60
- }
61
- )
62
-
63
- coupon_status.removeClass();
64
- Spree.ajax({
65
- async: false,
66
- method: "PUT",
67
- url: url,
68
- success: (data) ->
69
- coupon_code_field.val('')
70
- coupon_status.addClass("success").html("Coupon code applied successfully.")
71
- return true
72
- error: (xhr) ->
73
- handler = JSON.parse(xhr.responseText)
74
- coupon_status.addClass("error").html(handler["error"])
75
- $('.continue').attr('disabled', false)
76
- return false
77
- })
78
-
79
43
  Spree.onPayment()
@@ -1,7 +1,8 @@
1
- //= require jquery.payment
2
- //= require_self
3
- //= require spree/frontend/checkout/address
4
- //= require spree/frontend/checkout/payment
1
+ #= require jquery.payment
2
+ #= require_self
3
+ #= require spree/frontend/checkout/address
4
+ #= require spree/frontend/checkout/payment
5
+ #= require spree/frontend/checkout/coupon-code
5
6
 
6
7
  Spree.disableSaveOnClick = ->
7
8
  ($ 'form.edit_order').submit ->
@@ -920,7 +920,7 @@ p[data-hook="use_billing"] {
920
920
  &.success {
921
921
  color: $c_green;
922
922
  }
923
- &.error {
923
+ &.error, &.alert {
924
924
  color: $c_red;
925
925
  }
926
926
  }
@@ -4,9 +4,9 @@ module Spree
4
4
  # checkout which has nothing to do with updating an order that this approach
5
5
  # is warranted.
6
6
  class CheckoutController < Spree::StoreController
7
- before_filter :load_order
8
- around_filter :lock_order
9
- before_filter :set_state_if_present
7
+ before_action :load_order
8
+ around_action :lock_order
9
+ before_action :set_state_if_present
10
10
 
11
11
  before_action :ensure_order_not_completed
12
12
  before_action :ensure_checkout_allowed
@@ -6,11 +6,11 @@ module Spree
6
6
 
7
7
  respond_to :html
8
8
 
9
- before_filter :assign_order, only: :update
9
+ before_action :assign_order, only: :update
10
10
  # note: do not lock the #edit action because that's where we redirect when we fail to acquire a lock
11
- around_filter :lock_order, only: :update
12
- before_filter :apply_coupon_code, only: :update
13
- skip_before_filter :verify_authenticity_token, only: [:populate]
11
+ around_action :lock_order, only: :update
12
+ before_action :apply_coupon_code, only: :update
13
+ skip_before_action :verify_authenticity_token, only: [:populate]
14
14
 
15
15
  def show
16
16
  @order = Order.find_by_number!(params[:id])
@@ -66,6 +66,11 @@ module Spree
66
66
  end
67
67
  end
68
68
 
69
+ def populate_redirect
70
+ flash[:error] = Spree.t(:populate_get_error)
71
+ redirect_to('/cart')
72
+ end
73
+
69
74
  def empty
70
75
  if @order = current_order
71
76
  @order.empty!
@@ -15,7 +15,12 @@ module Spree
15
15
  end
16
16
 
17
17
  def show
18
- @variants = @product.variants_including_master.with_prices(current_pricing_options).includes([:option_values, :images])
18
+ @variants = @product.
19
+ variants_including_master.
20
+ display_includes.
21
+ with_prices(current_pricing_options).
22
+ includes([:option_values, :images])
23
+
19
24
  @product_properties = @product.product_properties.includes(:property)
20
25
  @taxon = Spree::Taxon.find(params[:taxon_id]) if params[:taxon_id]
21
26
  end
@@ -11,7 +11,7 @@ module Spree
11
11
 
12
12
  def cart_link
13
13
  render partial: 'spree/shared/link_to_cart'
14
- fresh_when(simple_current_order)
14
+ fresh_when(simple_current_order, template: 'spree/shared/_link_to_cart')
15
15
  end
16
16
 
17
17
  private
@@ -59,7 +59,13 @@
59
59
  <p class='field' data-hook='coupon_code'>
60
60
  <%= form.label :coupon_code %><br />
61
61
  <%= form.text_field :coupon_code %>
62
+ <button type="button" class="button" id="coupon-code-apply-button">
63
+ <%= Spree.t(:apply_code) %>
64
+ </button>
65
+
62
66
  </p>
67
+ <div id='coupon_status'></div>
68
+
63
69
  </div>
64
70
  </fieldset>
65
71
 
@@ -15,7 +15,7 @@
15
15
 
16
16
  <div id="wrapper" class="row" data-hook>
17
17
 
18
- <%= breadcrumbs(@taxon) %>
18
+ <%= taxon_breadcrumbs(@taxon) %>
19
19
 
20
20
  <%= render :partial => 'spree/shared/sidebar' if content_for? :sidebar %>
21
21
 
data/config/routes.rb CHANGED
@@ -1,4 +1,4 @@
1
- Spree::Core::Engine.add_routes do
1
+ Spree::Core::Engine.routes.draw do
2
2
  root to: 'home#index'
3
3
 
4
4
  resources :products, only: [:index, :show]
@@ -10,12 +10,7 @@ Spree::Core::Engine.add_routes do
10
10
  get '/checkout/:state', to: 'checkout#edit', as: :checkout_state
11
11
  get '/checkout', to: 'checkout#edit', as: :checkout
12
12
 
13
- populate_redirect = redirect do |_params, request|
14
- request.flash[:error] = Spree.t(:populate_get_error)
15
- request.referer || '/cart'
16
- end
17
-
18
- get '/orders/populate', to: populate_redirect
13
+ get '/orders/populate', to: 'orders#populate_redirect'
19
14
  get '/orders/:id/token/:token' => 'orders#show', :as => :token_order
20
15
 
21
16
  resources :orders, except: [:index, :new, :create, :destroy] do
@@ -21,7 +21,7 @@ Gem::Specification.new do |s|
21
21
  s.add_dependency 'solidus_api', s.version
22
22
  s.add_dependency 'solidus_core', s.version
23
23
 
24
- s.add_dependency 'canonical-rails', '~> 0.0.4'
24
+ s.add_dependency 'canonical-rails', '~> 0.1.1'
25
25
  s.add_dependency 'jquery-rails'
26
26
  s.add_dependency 'sass-rails'
27
27
  s.add_dependency 'coffee-rails'
@@ -49,7 +49,7 @@ describe Spree::CustomController, type: :controller do
49
49
 
50
50
  describe "GET" do
51
51
  it "has value success" do
52
- spree_get :index
52
+ get :index
53
53
  expect(response).to be_success
54
54
  expect(response.body).to match(/success!!!/)
55
55
  end
@@ -66,7 +66,7 @@ describe Spree::CustomController, type: :controller do
66
66
 
67
67
  describe "GET" do
68
68
  it "has value success" do
69
- spree_get :index
69
+ get :index
70
70
  expect(response).to be_success
71
71
  expect(response.body).to match(/success!!!/)
72
72
  end
@@ -83,7 +83,7 @@ describe Spree::CustomController, type: :controller do
83
83
 
84
84
  describe "GET" do
85
85
  it "has value success" do
86
- spree_get :index
86
+ get :index
87
87
  expect(response).to be_redirect
88
88
  end
89
89
  end
@@ -100,7 +100,7 @@ describe Spree::CustomController, type: :controller do
100
100
 
101
101
  describe "POST" do
102
102
  it "has value success" do
103
- spree_post :create
103
+ post :create
104
104
  expect(response).to be_success
105
105
  expect(response.body).to match(/success!/)
106
106
  end
@@ -116,7 +116,7 @@ describe Spree::CustomController, type: :controller do
116
116
 
117
117
  describe "POST" do
118
118
  it "should not effect the wrong controller" do
119
- spree_get :index
119
+ get :index
120
120
  expect(response.body).to match(/neutral/)
121
121
  end
122
122
  end
@@ -18,7 +18,7 @@ describe Spree::ProductsController, type: :controller do
18
18
  # Regression test for https://github.com/spree/spree/issues/1184
19
19
  it "sets the default locale based off Spree::Frontend::Config[:locale]" do
20
20
  expect(I18n.locale).to eq(:en)
21
- spree_get :index
21
+ get :index
22
22
  expect(I18n.locale).to eq(:de)
23
23
  end
24
24
  end
@@ -20,31 +20,31 @@ describe Spree::CheckoutController, type: :controller do
20
20
  it 'should check if the user is authorized for :edit' do
21
21
  expect(controller).to receive(:authorize!).with(:edit, order, token)
22
22
  request.cookie_jar.signed[:guest_token] = token
23
- spree_get :edit, { state: 'address' }
23
+ get :edit, { state: 'address' }
24
24
  end
25
25
 
26
26
  it "should redirect to the cart path unless checkout_allowed?" do
27
27
  allow(order).to receive_messages checkout_allowed?: false
28
- spree_get :edit, { state: "delivery" }
28
+ get :edit, { state: "delivery" }
29
29
  expect(response).to redirect_to(spree.cart_path)
30
30
  end
31
31
 
32
32
  it "should redirect to the cart path if current_order is nil" do
33
33
  allow(controller).to receive(:current_order).and_return(nil)
34
- spree_get :edit, { state: "delivery" }
34
+ get :edit, { state: "delivery" }
35
35
  expect(response).to redirect_to(spree.cart_path)
36
36
  end
37
37
 
38
38
  it "should redirect to cart if order is completed" do
39
39
  allow(order).to receive_messages(completed?: true)
40
- spree_get :edit, { state: "address" }
40
+ get :edit, { state: "address" }
41
41
  expect(response).to redirect_to(spree.cart_path)
42
42
  end
43
43
 
44
44
  # Regression test for https://github.com/spree/spree/issues/2280
45
45
  it "should redirect to current step trying to access a future step" do
46
46
  order.update_column(:state, "address")
47
- spree_get :edit, { state: "delivery" }
47
+ get :edit, { state: "delivery" }
48
48
  expect(response).to redirect_to spree.checkout_state_path("address")
49
49
  end
50
50
 
@@ -58,7 +58,7 @@ describe Spree::CheckoutController, type: :controller do
58
58
  it "should associate the order with a user" do
59
59
  order.update_column :user_id, nil
60
60
  expect(order).to receive(:associate_user!).with(user)
61
- spree_get :edit, {}, order_id: 1
61
+ get :edit, {}, order_id: 1
62
62
  end
63
63
  end
64
64
  end
@@ -67,12 +67,12 @@ describe Spree::CheckoutController, type: :controller do
67
67
  it 'should check if the user is authorized for :edit' do
68
68
  expect(controller).to receive(:authorize!).with(:edit, order, token)
69
69
  request.cookie_jar.signed[:guest_token] = token
70
- spree_post :update, { state: 'address' }
70
+ post :update, { state: 'address' }
71
71
  end
72
72
 
73
73
  context "save successful" do
74
- def spree_post_address
75
- spree_post :update, {
74
+ def post_address
75
+ post :update, {
76
76
  state: "address",
77
77
  order: {
78
78
  bill_address_attributes: address_params,
@@ -81,9 +81,9 @@ describe Spree::CheckoutController, type: :controller do
81
81
  }
82
82
  end
83
83
 
84
- let!(:payment_method) { create(:payment_method) }
85
84
  before do
86
85
  # Must have *a* shipping method and a payment method so updating from address works
86
+ allow(order).to receive_messages available_payment_methods: [stub_model(Spree::PaymentMethod)]
87
87
  allow(order).to receive_messages ensure_available_shipping_rates: true
88
88
  order.line_items << FactoryGirl.create(:line_item)
89
89
  end
@@ -95,24 +95,24 @@ describe Spree::CheckoutController, type: :controller do
95
95
  end
96
96
 
97
97
  it "should assign order" do
98
- spree_post :update, { state: "address" }
98
+ post :update, { state: "address" }
99
99
  expect(assigns[:order]).not_to be_nil
100
100
  end
101
101
 
102
102
  it "should advance the state" do
103
- spree_post_address
103
+ post_address
104
104
  expect(order.reload.state).to eq("delivery")
105
105
  end
106
106
 
107
107
  it "should redirect the next state" do
108
- spree_post_address
108
+ post_address
109
109
  expect(response).to redirect_to spree.checkout_state_path("delivery")
110
110
  end
111
111
 
112
112
  context "current_user respond to save address method" do
113
113
  it "calls persist order address on user" do
114
114
  expect(user).to receive(:persist_order_address)
115
- spree_post :update, {
115
+ post :update, {
116
116
  state: "address",
117
117
  order: {
118
118
  bill_address_attributes: address_params,
@@ -125,7 +125,7 @@ describe Spree::CheckoutController, type: :controller do
125
125
 
126
126
  context "current_user doesnt respond to persist_order_address" do
127
127
  it "doesnt raise any error" do
128
- spree_post :update, {
128
+ post :update, {
129
129
  state: "address",
130
130
  order: {
131
131
  bill_address_attributes: address_params,
@@ -144,25 +144,27 @@ describe Spree::CheckoutController, type: :controller do
144
144
  end
145
145
 
146
146
  context "with a billing and shipping address" do
147
- before do
148
- @expected_bill_address_id = order.bill_address.id
149
- @expected_ship_address_id = order.ship_address.id
150
-
151
- spree_post :update, {
152
- state: "address",
153
- order: {
154
- bill_address_attributes: order.bill_address.attributes.except("created_at", "updated_at"),
155
- ship_address_attributes: order.ship_address.attributes.except("created_at", "updated_at"),
156
- use_billing: false
157
- }
147
+ subject do
148
+ post :update, {
149
+ state: "address",
150
+ order: {
151
+ bill_address_attributes: order.bill_address.attributes.except("created_at", "updated_at").compact,
152
+ ship_address_attributes: order.ship_address.attributes.except("created_at", "updated_at").compact,
153
+ use_billing: false
154
+ }
158
155
  }
156
+ end
159
157
 
160
- order.reload
158
+ it "doesn't change bill address" do
159
+ expect {
160
+ subject
161
+ }.not_to change { order.reload.ship_address.id }
161
162
  end
162
163
 
163
- it "unchanged address data does not change Address instances" do
164
- expect(order.bill_address.id).to eq(@expected_bill_address_id)
165
- expect(order.ship_address.id).to eq(@expected_ship_address_id)
164
+ it "doesn't change ship address" do
165
+ expect {
166
+ subject
167
+ }.not_to change { order.reload.bill_address.id }
166
168
  end
167
169
  end
168
170
  end
@@ -208,7 +210,7 @@ describe Spree::CheckoutController, type: :controller do
208
210
  end
209
211
 
210
212
  it 'sets the payment amount' do
211
- spree_post :update, params
213
+ post :update, params
212
214
  order.reload
213
215
  expect(order.state).to eq('new_step')
214
216
  expect(order.payments.size).to eq(1)
@@ -216,53 +218,6 @@ describe Spree::CheckoutController, type: :controller do
216
218
  end
217
219
  end
218
220
 
219
- context "when in the payment state" do
220
- let(:order) { create(:order_with_line_items) }
221
- let(:payment_method) { create(:credit_card_payment_method) }
222
-
223
- let(:params) do
224
- {
225
- state: 'payment',
226
- order: {
227
- payments_attributes: [
228
- {
229
- payment_method_id: payment_method.id.to_s,
230
- source_attributes: attributes_for(:credit_card)
231
- }
232
- ]
233
- }
234
- }
235
- end
236
-
237
- before do
238
- order.update_attributes! user: user
239
- 3.times { order.next! } # should put us in the payment state
240
- end
241
-
242
- context 'with a permitted payment method' do
243
- it 'sets the payment amount' do
244
- post :update, params
245
- order.reload
246
- expect(order.state).to eq('confirm')
247
- expect(order.payments.size).to eq(1)
248
- expect(order.payments.first.amount).to eq(order.total)
249
- end
250
- end
251
-
252
- context 'with an unpermitted payment method' do
253
- before { payment_method.update!(display_on: "back_end") }
254
-
255
- it 'sets the payment amount' do
256
- expect {
257
- post :update, params
258
- }.to raise_error(ActiveRecord::RecordNotFound)
259
-
260
- expect(order.state).to eq('payment')
261
- expect(order.payments).to be_empty
262
- end
263
- end
264
- end
265
-
266
221
  context "when in the confirm state" do
267
222
  before do
268
223
  order.update_attributes! user: user
@@ -276,17 +231,17 @@ describe Spree::CheckoutController, type: :controller do
276
231
 
277
232
  # This inadvertently is a regression test for https://github.com/spree/spree/issues/2694
278
233
  it "should redirect to the order view" do
279
- spree_post :update, { state: "confirm" }
234
+ post :update, { state: "confirm" }
280
235
  expect(response).to redirect_to spree.order_path(order)
281
236
  end
282
237
 
283
238
  it "should populate the flash message" do
284
- spree_post :update, { state: "confirm" }
239
+ post :update, { state: "confirm" }
285
240
  expect(flash.notice).to eq(Spree.t(:order_processed_successfully))
286
241
  end
287
242
 
288
243
  it "should remove completed order from current_order" do
289
- spree_post :update, { state: "confirm" }, { order_id: "foofah" }
244
+ post :update, { state: "confirm" }, { order_id: "foofah" }
290
245
  expect(assigns(:current_order)).to be_nil
291
246
  expect(assigns(:order)).to eql controller.current_order
292
247
  end
@@ -300,16 +255,16 @@ describe Spree::CheckoutController, type: :controller do
300
255
  end
301
256
 
302
257
  it "should not assign order" do
303
- spree_post :update, { state: "address", email: '' }
258
+ post :update, { state: "address", email: '' }
304
259
  expect(assigns[:order]).not_to be_nil
305
260
  end
306
261
 
307
262
  it "should not change the order state" do
308
- spree_post :update, { state: 'address' }
263
+ post :update, { state: 'address' }
309
264
  end
310
265
 
311
266
  it "should render the edit template" do
312
- spree_post :update, { state: 'address' }
267
+ post :update, { state: 'address' }
313
268
  expect(response).to render_template :edit
314
269
  end
315
270
  end
@@ -319,11 +274,11 @@ describe Spree::CheckoutController, type: :controller do
319
274
 
320
275
  it "should not change the state if order is completed" do
321
276
  expect(order).not_to receive(:update_attribute)
322
- spree_post :update, { state: "confirm" }
277
+ post :update, { state: "confirm" }
323
278
  end
324
279
 
325
280
  it "should redirect to the cart_path" do
326
- spree_post :update, { state: "confirm" }
281
+ post :update, { state: "confirm" }
327
282
  expect(response).to redirect_to spree.cart_path
328
283
  end
329
284
  end
@@ -332,7 +287,7 @@ describe Spree::CheckoutController, type: :controller do
332
287
  before do
333
288
  order.update_attributes! user: user
334
289
  allow(order).to receive(:next).and_raise(Spree::Core::GatewayError.new("Invalid something or other."))
335
- spree_post :update, { state: "address" }
290
+ post :update, { state: "address" }
336
291
  end
337
292
 
338
293
  it "should render the edit template and display exception message" do
@@ -363,7 +318,7 @@ describe Spree::CheckoutController, type: :controller do
363
318
  end
364
319
 
365
320
  it "due to the order having errors" do
366
- spree_put :update, state: order.state, order: {}
321
+ put :update, state: order.state, order: {}
367
322
  expect(flash[:error]).to eq("Base error\nAdjustments error")
368
323
  expect(response).to redirect_to(spree.checkout_state_path('address'))
369
324
  end
@@ -398,7 +353,7 @@ describe Spree::CheckoutController, type: :controller do
398
353
  expect(order.shipments.count).to eq(1)
399
354
  order.shipments.first.shipping_rates.delete_all
400
355
  order.update_attributes(state: 'confirm')
401
- spree_put :update, state: order.state, order: {}
356
+ put :update, state: order.state, order: {}
402
357
  expect(flash[:error]).to eq(Spree.t(:items_cannot_be_shipped))
403
358
  expect(response).to redirect_to(spree.checkout_state_path('confirm'))
404
359
  end
@@ -426,7 +381,7 @@ describe Spree::CheckoutController, type: :controller do
426
381
 
427
382
  it "fails to transition from payment to complete" do
428
383
  allow_any_instance_of(Spree::Payment).to receive(:process!).and_raise(Spree::Core::GatewayError.new(Spree.t(:payment_processing_failed)))
429
- spree_put :update, state: order.state, order: {}
384
+ put :update, state: order.state, order: {}
430
385
  expect(flash[:error]).to eq(Spree.t(:payment_processing_failed))
431
386
  end
432
387
  end
@@ -448,7 +403,7 @@ describe Spree::CheckoutController, type: :controller do
448
403
 
449
404
  context "and back orders are not allowed" do
450
405
  before do
451
- spree_post :update, { state: "payment" }
406
+ post :update, { state: "payment" }
452
407
  end
453
408
 
454
409
  it "should redirect to cart" do
@@ -470,12 +425,12 @@ describe Spree::CheckoutController, type: :controller do
470
425
 
471
426
  it "doesn't set shipping address on the order" do
472
427
  expect(order).to_not receive(:ship_address=)
473
- spree_post :update, state: order.state
428
+ post :update, state: order.state
474
429
  end
475
430
 
476
431
  it "doesn't remove unshippable items before payment" do
477
432
  expect {
478
- spree_post :update, { state: "payment" }
433
+ post :update, { state: "payment" }
479
434
  }.to_not change { order.line_items }
480
435
  end
481
436
  end
@@ -485,7 +440,7 @@ describe Spree::CheckoutController, type: :controller do
485
440
  allow(controller).to receive_messages check_authorization: true
486
441
 
487
442
  expect {
488
- spree_post :update, { state: "payment" }
489
- }.to change { order.line_items }
443
+ post :update, { state: "payment" }
444
+ }.to change { order.line_items.to_a.size }.from(1).to(0)
490
445
  end
491
446
  end
@@ -27,7 +27,7 @@ describe Spree::CheckoutController, type: :controller do
27
27
  end
28
28
 
29
29
  it "displays rate cost in correct currency" do
30
- spree_get :edit
30
+ get :edit
31
31
  html = Nokogiri::HTML(response.body)
32
32
  expect(html.css('.rate-cost').text).to eq "£10.00"
33
33
  end
@@ -1,7 +1,7 @@
1
1
  require 'spec_helper'
2
2
  describe Spree::ContentController, type: :controller do
3
3
  it "should display CVV page" do
4
- spree_get :cvv
4
+ get :cvv
5
5
  expect(response.response_code).to eq(200)
6
6
  end
7
7
  end
@@ -6,7 +6,7 @@ describe 'current order tracking', type: :controller do
6
6
 
7
7
  controller(Spree::StoreController) do
8
8
  def index
9
- render nothing: true
9
+ head :ok
10
10
  end
11
11
  end
12
12
 
@@ -24,7 +24,7 @@ describe 'current order tracking', type: :controller do
24
24
 
25
25
  it "doesn't create a new order out of the blue" do
26
26
  expect {
27
- spree_get :index
27
+ get :index
28
28
  }.not_to change { Spree::Order.count }
29
29
  end
30
30
  end
@@ -38,7 +38,7 @@ describe Spree::OrdersController, type: :controller do
38
38
  describe Spree::OrdersController do
39
39
  it "doesn't create a new order out of the blue" do
40
40
  expect {
41
- spree_get :edit
41
+ get :edit
42
42
  }.not_to change { Spree::Order.count }
43
43
  end
44
44
  end
@@ -5,13 +5,13 @@ describe Spree::HomeController, type: :controller do
5
5
  user = mock_model(Spree.user_class, last_incomplete_spree_order: nil, spree_api_key: 'fake')
6
6
  allow(controller).to receive_messages try_spree_current_user: user
7
7
  expect_any_instance_of(Spree::Config.searcher_class).to receive(:current_user=).with(user)
8
- spree_get :index
8
+ get :index
9
9
  expect(response.status).to eq(200)
10
10
  end
11
11
 
12
12
  context "layout" do
13
13
  it "renders default layout" do
14
- spree_get :index
14
+ get :index
15
15
  expect(response).to render_template(layout: 'spree/layouts/spree_application')
16
16
  end
17
17
 
@@ -19,7 +19,7 @@ describe Spree::HomeController, type: :controller do
19
19
  before { Spree::Config.layout = 'layouts/application' }
20
20
 
21
21
  it "renders specified layout" do
22
- spree_get :index
22
+ get :index
23
23
  expect(response).to render_template(layout: 'layouts/application')
24
24
  end
25
25
  end
@@ -25,22 +25,22 @@ module Spree
25
25
  context '#populate' do
26
26
  it 'should check if user is authorized for :edit' do
27
27
  expect(controller).to receive(:authorize!).with(:edit, order, token)
28
- spree_post :populate, token: token
28
+ post :populate, token: token
29
29
  end
30
30
  it "should check against the specified order" do
31
31
  expect(controller).to receive(:authorize!).with(:edit, specified_order, token)
32
- spree_post :populate, id: specified_order.number, token: token
32
+ post :populate, id: specified_order.number, token: token
33
33
  end
34
34
  end
35
35
 
36
36
  context '#edit' do
37
37
  it 'should check if user is authorized for :edit' do
38
38
  expect(controller).to receive(:authorize!).with(:edit, order, token)
39
- spree_get :edit, token: token
39
+ get :edit, token: token
40
40
  end
41
41
  it "should check against the specified order" do
42
42
  expect(controller).to receive(:authorize!).with(:edit, specified_order, token)
43
- spree_get :edit, id: specified_order.number, token: token
43
+ get :edit, id: specified_order.number, token: token
44
44
  end
45
45
  end
46
46
 
@@ -48,30 +48,30 @@ module Spree
48
48
  it 'should check if user is authorized for :edit' do
49
49
  allow(order).to receive :update_attributes
50
50
  expect(controller).to receive(:authorize!).with(:edit, order, token)
51
- spree_post :update, order: { email: "foo@bar.com" }, token: token
51
+ post :update, order: { email: "foo@bar.com" }, token: token
52
52
  end
53
53
  it "should check against the specified order" do
54
54
  allow(order).to receive :update_attributes
55
55
  expect(controller).to receive(:authorize!).with(:edit, specified_order, token)
56
- spree_post :update, order: { email: "foo@bar.com" }, id: specified_order.number, token: token
56
+ post :update, order: { email: "foo@bar.com" }, id: specified_order.number, token: token
57
57
  end
58
58
  end
59
59
 
60
60
  context '#empty' do
61
61
  it 'should check if user is authorized for :edit' do
62
62
  expect(controller).to receive(:authorize!).with(:edit, order, token)
63
- spree_post :empty, token: token
63
+ post :empty, token: token
64
64
  end
65
65
  it "should check against the specified order" do
66
66
  expect(controller).to receive(:authorize!).with(:edit, specified_order, token)
67
- spree_post :empty, id: specified_order.number, token: token
67
+ post :empty, id: specified_order.number, token: token
68
68
  end
69
69
  end
70
70
 
71
71
  context "#show" do
72
72
  it "should check against the specified order" do
73
73
  expect(controller).to receive(:authorize!).with(:edit, specified_order, token)
74
- spree_get :show, id: specified_order.number, token: token
74
+ get :show, id: specified_order.number, token: token
75
75
  end
76
76
  end
77
77
  end
@@ -83,19 +83,19 @@ module Spree
83
83
  context 'when token parameter present' do
84
84
  it 'always ooverride existing token when passing a new one' do
85
85
  cookies.signed[:guest_token] = "soo wrong"
86
- spree_get :show, { id: 'R123', token: order.guest_token }
86
+ get :show, { id: 'R123', token: order.guest_token }
87
87
  expect(cookies.signed[:guest_token]).to eq(order.guest_token)
88
88
  end
89
89
 
90
90
  it 'should store as guest_token in session' do
91
- spree_get :show, { id: 'R123', token: order.guest_token }
91
+ get :show, { id: 'R123', token: order.guest_token }
92
92
  expect(cookies.signed[:guest_token]).to eq(order.guest_token)
93
93
  end
94
94
  end
95
95
 
96
96
  context 'when no token present' do
97
97
  it 'should respond with 404' do
98
- spree_get :show, { id: 'R123' }
98
+ get :show, { id: 'R123' }
99
99
  expect(response.code).to eq('404')
100
100
  end
101
101
  end
@@ -16,7 +16,7 @@ describe Spree::OrdersController, type: :controller do
16
16
 
17
17
  context "#populate" do
18
18
  it "should create a new order when none specified" do
19
- spree_post :populate, {}, {}
19
+ post :populate, {}, {}
20
20
  expect(cookies.signed[:guest_token]).not_to be_blank
21
21
  expect(Spree::Order.find_by_guest_token(cookies.signed[:guest_token])).to be_persisted
22
22
  end
@@ -24,7 +24,7 @@ describe Spree::OrdersController, type: :controller do
24
24
  context "with Variant" do
25
25
  it "should handle population" do
26
26
  expect do
27
- spree_post :populate, variant_id: variant.id, quantity: 5
27
+ post :populate, variant_id: variant.id, quantity: 5
28
28
  end.to change { user.orders.count }.by(1)
29
29
  order = user.orders.last
30
30
  expect(response).to redirect_to spree.cart_path
@@ -44,7 +44,7 @@ describe Spree::OrdersController, type: :controller do
44
44
  and_return(["Order population failed"])
45
45
  )
46
46
 
47
- spree_post :populate, variant_id: variant.id, quantity: 5
47
+ post :populate, variant_id: variant.id, quantity: 5
48
48
 
49
49
  expect(response).to redirect_to(spree.root_path)
50
50
  expect(flash[:error]).to eq("Order population failed")
@@ -53,7 +53,7 @@ describe Spree::OrdersController, type: :controller do
53
53
  it "shows an error when quantity is invalid" do
54
54
  request.env["HTTP_REFERER"] = spree.root_path
55
55
 
56
- spree_post(
56
+ post(
57
57
  :populate,
58
58
  variant_id: variant.id, quantity: -1
59
59
  )
@@ -76,13 +76,13 @@ describe Spree::OrdersController, type: :controller do
76
76
  it "should render the edit view (on failure)" do
77
77
  # email validation is only after address state
78
78
  order.update_column(:state, "delivery")
79
- spree_put :update, { order: { email: "" } }, { order_id: order.id }
79
+ put :update, { order: { email: "" } }, { order_id: order.id }
80
80
  expect(response).to render_template :edit
81
81
  end
82
82
 
83
83
  it "should redirect to cart path (on success)" do
84
84
  allow(order).to receive(:update_attributes).and_return true
85
- spree_put :update, {}, { order_id: 1 }
85
+ put :update, {}, { order_id: 1 }
86
86
  expect(response).to redirect_to(spree.cart_path)
87
87
  end
88
88
  end
@@ -96,7 +96,7 @@ describe Spree::OrdersController, type: :controller do
96
96
  it "should destroy line items in the current order" do
97
97
  allow(controller).to receive(:current_order).and_return(order)
98
98
  expect(order).to receive(:empty!)
99
- spree_put :empty
99
+ put :empty
100
100
  expect(response).to redirect_to(spree.cart_path)
101
101
  end
102
102
  end
@@ -109,7 +109,7 @@ describe Spree::OrdersController, type: :controller do
109
109
  end
110
110
 
111
111
  it "cannot update a blank order" do
112
- spree_put :update, order: { email: "foo" }
112
+ put :update, order: { email: "foo" }
113
113
  expect(flash[:error]).to eq(Spree.t(:order_not_found))
114
114
  expect(response).to redirect_to(spree.root_path)
115
115
  end
@@ -128,7 +128,7 @@ describe Spree::OrdersController, type: :controller do
128
128
 
129
129
  it "removes line items on update" do
130
130
  expect(order.line_items.count).to eq 1
131
- spree_put :update, order: { line_items_attributes: { "0" => { id: line_item.id, quantity: 0 } } }
131
+ put :update, order: { line_items_attributes: { "0" => { id: line_item.id, quantity: 0 } } }
132
132
  expect(order.reload.line_items.count).to eq 0
133
133
  end
134
134
  end
@@ -23,7 +23,7 @@ module Spree
23
23
  it "correctly calls the transition callback" do
24
24
  expect(order.did_transition).to be_nil
25
25
  order.line_items << FactoryGirl.create(:line_item)
26
- spree_put :update, { checkout: "checkout" }, { order_id: 1 }
26
+ put :update, { checkout: "checkout" }, { order_id: 1 }
27
27
  expect(order.did_transition).to be true
28
28
  end
29
29
  end
@@ -6,12 +6,12 @@ describe Spree::ProductsController, type: :controller do
6
6
  # Regression test for https://github.com/spree/spree/issues/1390
7
7
  it "allows admins to view non-active products" do
8
8
  allow(controller).to receive_messages spree_current_user: mock_model(Spree.user_class, has_spree_role?: true, last_incomplete_spree_order: nil, spree_api_key: 'fake')
9
- spree_get :show, id: product.to_param
9
+ get :show, id: product.to_param
10
10
  expect(response.status).to eq(200)
11
11
  end
12
12
 
13
13
  it "cannot view non-active products" do
14
- spree_get :show, id: product.to_param
14
+ get :show, id: product.to_param
15
15
  expect(response.status).to eq(404)
16
16
  end
17
17
 
@@ -19,7 +19,7 @@ describe Spree::ProductsController, type: :controller do
19
19
  user = mock_model(Spree.user_class, last_incomplete_spree_order: nil, spree_api_key: 'fake')
20
20
  allow(controller).to receive_messages spree_current_user: user
21
21
  expect_any_instance_of(Spree::Config.searcher_class).to receive(:current_user=).with(user)
22
- spree_get :index
22
+ get :index
23
23
  expect(response.status).to eq(200)
24
24
  end
25
25
 
@@ -30,6 +30,6 @@ describe Spree::ProductsController, type: :controller do
30
30
  request.env['HTTP_REFERER'] = "not|a$url"
31
31
 
32
32
  # Previously a URI::InvalidURIError exception was being thrown
33
- spree_get :show, id: product.to_param
33
+ get :show, id: product.to_param
34
34
  end
35
35
  end
@@ -6,7 +6,7 @@ describe Spree::TaxonsController, type: :controller do
6
6
  user = mock_model(Spree.user_class, last_incomplete_spree_order: nil, spree_api_key: 'fake')
7
7
  allow(controller).to receive_messages spree_current_user: user
8
8
  expect_any_instance_of(Spree::Config.searcher_class).to receive(:current_user=).with(user)
9
- spree_get :show, id: taxon.permalink
9
+ get :show, id: taxon.permalink
10
10
  expect(response.status).to eq(200)
11
11
  end
12
12
  end
@@ -77,9 +77,9 @@ describe "Checkout", type: :feature, inaccessible: true do
77
77
 
78
78
  # Regression test for https://github.com/spree/spree/issues/2694 and https://github.com/spree/spree/issues/4117
79
79
  context "doesn't allow bad credit card numbers" do
80
- let!(:payment_method) { create(:credit_card_payment_method) }
81
80
  before(:each) do
82
81
  order = OrderWalkthrough.up_to(:delivery)
82
+ allow(order).to receive_messages(available_payment_methods: [create(:credit_card_payment_method)])
83
83
 
84
84
  user = create(:user)
85
85
  order.user = user
@@ -180,8 +180,7 @@ describe "Checkout", type: :feature, inaccessible: true do
180
180
  end
181
181
 
182
182
  context "user has payment sources", js: true do
183
- before { Spree::PaymentMethod.all.each(&:really_destroy!) }
184
- let!(:bogus) { create(:credit_card_payment_method) }
183
+ let(:bogus) { create(:credit_card_payment_method) }
185
184
  let(:user) { create(:user) }
186
185
 
187
186
  let!(:credit_card) do
@@ -190,6 +189,7 @@ describe "Checkout", type: :feature, inaccessible: true do
190
189
 
191
190
  before do
192
191
  order = OrderWalkthrough.up_to(:delivery)
192
+ allow(order).to receive_messages(available_payment_methods: [bogus])
193
193
 
194
194
  allow_any_instance_of(Spree::CheckoutController).to receive_messages(current_order: order)
195
195
  allow_any_instance_of(Spree::CheckoutController).to receive_messages(try_spree_current_user: user)
@@ -317,7 +317,7 @@ describe "Checkout", type: :feature, inaccessible: true do
317
317
  end
318
318
  end
319
319
 
320
- context "in coupon promotion, submits coupon along with payment", js: true do
320
+ context "Coupon promotions", js: true do
321
321
  let!(:promotion) { create(:promotion, name: "Huhuhu", code: "huhu") }
322
322
  let!(:calculator) { Spree::Calculator::FlatPercentItemTotal.create(preferred_flat_percent: "10") }
323
323
  let!(:action) { Spree::Promotion::Actions::CreateItemAdjustments.create(calculator: calculator) }
@@ -336,20 +336,19 @@ describe "Checkout", type: :feature, inaccessible: true do
336
336
  expect(page).to have_current_path(spree.checkout_state_path("payment"))
337
337
  end
338
338
 
339
- it "makes sure payment reflects order total with discounts" do
339
+ it "applies them & refreshes the page on user clicking the Apply Code button" do
340
340
  fill_in "Coupon Code", with: promotion.codes.first.value
341
- click_on "Save and Continue"
341
+ click_on "Apply Code"
342
342
 
343
343
  expect(page).to have_content(promotion.name)
344
- expect(Spree::Payment.first.amount.to_f).to eq Spree::Order.last.total.to_f
344
+ expect(page).to have_content("-$2.00")
345
345
  end
346
346
 
347
- context "invalid coupon" do
348
- it "doesnt create a payment record" do
347
+ context "with invalid coupon" do
348
+ it "doesnt apply the promotion" do
349
349
  fill_in "Coupon Code", with: 'invalid'
350
- click_on "Save and Continue"
350
+ click_on "Apply Code"
351
351
 
352
- expect(Spree::Payment.count).to eq 0
353
352
  expect(page).to have_content(Spree.t(:coupon_code_not_found))
354
353
  end
355
354
  end
@@ -9,7 +9,7 @@ describe "checkout with unshippable items", type: :feature, inaccessible: true d
9
9
  order.reload
10
10
  line_item = order.line_items.last
11
11
  stock_item = stock_location.stock_item(line_item.variant)
12
- stock_item.adjust_count_on_hand(-999)
12
+ stock_item.adjust_count_on_hand(0)
13
13
  stock_item.backorderable = false
14
14
  stock_item.save!
15
15
 
@@ -20,6 +20,21 @@ describe "Visiting Products", type: :feature, inaccessible: true do
20
20
  expect(page).to have_content("Shopping Cart")
21
21
  end
22
22
 
23
+ # Regression spec for Spree [PR#7442](https://github.com/spree/spree/pull/7442)
24
+ context "when generating product links" do
25
+ let(:product) { Spree::Product.available.first }
26
+
27
+ it "should not use the *_url helper to generate the product links" do
28
+ visit spree.root_path
29
+ expect(page).not_to have_xpath(".//a[@href='#{spree.product_url(product, host: current_host)}']")
30
+ end
31
+
32
+ it "should use *_path helper to generate the product links" do
33
+ visit spree.root_path
34
+ expect(page).to have_xpath(".//a[@href='#{spree.product_path(product)}']")
35
+ end
36
+ end
37
+
23
38
  describe 'meta tags and title' do
24
39
  let(:jersey) { Spree::Product.find_by_name('Ruby on Rails Baseball Jersey') }
25
40
  let(:metas) { { meta_description: 'Brand new Ruby on Rails Jersey', meta_title: 'Ruby on Rails Baseball Jersey Buy High Quality Geek Apparel', meta_keywords: 'ror, jersey, ruby' } }
data/spec/spec_helper.rb CHANGED
@@ -48,7 +48,7 @@ require 'spree/testing_support/caching'
48
48
  require 'paperclip/matchers'
49
49
 
50
50
  require 'capybara-screenshot/rspec'
51
- Capybara.save_and_open_page_path = ENV['CIRCLE_ARTIFACTS'] if ENV['CIRCLE_ARTIFACTS']
51
+ Capybara.save_path = ENV['CIRCLE_ARTIFACTS'] if ENV['CIRCLE_ARTIFACTS']
52
52
 
53
53
  if ENV['WEBDRIVER'] == 'accessible'
54
54
  require 'capybara/accessible'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: solidus_frontend
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.3.2
4
+ version: 1.4.0.beta1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Solidus Team
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-12-12 00:00:00.000000000 Z
11
+ date: 2016-08-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: solidus_api
@@ -16,42 +16,42 @@ dependencies:
16
16
  requirements:
17
17
  - - '='
18
18
  - !ruby/object:Gem::Version
19
- version: 1.3.2
19
+ version: 1.4.0.beta1
20
20
  type: :runtime
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: 1.3.2
26
+ version: 1.4.0.beta1
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: solidus_core
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - '='
32
32
  - !ruby/object:Gem::Version
33
- version: 1.3.2
33
+ version: 1.4.0.beta1
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - '='
39
39
  - !ruby/object:Gem::Version
40
- version: 1.3.2
40
+ version: 1.4.0.beta1
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: canonical-rails
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
45
  - - "~>"
46
46
  - !ruby/object:Gem::Version
47
- version: 0.0.4
47
+ version: 0.1.1
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
- version: 0.0.4
54
+ version: 0.1.1
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: jquery-rails
57
57
  requirement: !ruby/object:Gem::Requirement
@@ -165,6 +165,7 @@ files:
165
165
  - app/assets/javascripts/spree/frontend/cart.js.coffee
166
166
  - app/assets/javascripts/spree/frontend/checkout.js.coffee
167
167
  - app/assets/javascripts/spree/frontend/checkout/address.js.coffee
168
+ - app/assets/javascripts/spree/frontend/checkout/coupon-code.js.coffee
168
169
  - app/assets/javascripts/spree/frontend/checkout/payment.js.coffee
169
170
  - app/assets/javascripts/spree/frontend/product.js.coffee
170
171
  - app/assets/stylesheets/spree/frontend.css
@@ -339,13 +340,13 @@ required_ruby_version: !ruby/object:Gem::Requirement
339
340
  version: 2.1.0
340
341
  required_rubygems_version: !ruby/object:Gem::Requirement
341
342
  requirements:
342
- - - ">="
343
+ - - ">"
343
344
  - !ruby/object:Gem::Version
344
- version: '0'
345
+ version: 1.3.1
345
346
  requirements:
346
347
  - none
347
348
  rubyforge_project: solidus_frontend
348
- rubygems_version: 2.6.11
349
+ rubygems_version: 2.5.1
349
350
  signing_key:
350
351
  specification_version: 4
351
352
  summary: Cart and storefront for the Solidus e-commerce project.