mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-02-13 23:37:47 +00:00
Fix rubocop issue Layout/ArgumentAlignment
This commit is contained in:
@@ -6,15 +6,6 @@
|
||||
# Note that changes in the inspected code, or installation of new
|
||||
# versions of RuboCop, may require this file to be generated again.
|
||||
|
||||
# Offense count: 3
|
||||
# Cop supports --auto-correct.
|
||||
# Configuration parameters: EnforcedStyle, IndentationWidth.
|
||||
# SupportedStyles: with_first_argument, with_fixed_indentation
|
||||
Layout/ArgumentAlignment:
|
||||
Exclude:
|
||||
- 'spec/models/spree/address_spec.rb'
|
||||
- 'spec/models/spree/order/checkout_spec.rb'
|
||||
|
||||
# Offense count: 1
|
||||
# Cop supports --auto-correct.
|
||||
# Configuration parameters: EnforcedStyleAlignWith.
|
||||
|
||||
@@ -7,18 +7,18 @@ describe Spree::Address do
|
||||
it "creates a copy of the address with the exception of the id, updated_at and created_at attributes" do
|
||||
state = build_stubbed(:state)
|
||||
original = build_stubbed(:address,
|
||||
address1: 'address1',
|
||||
address2: 'address2',
|
||||
alternative_phone: 'alternative_phone',
|
||||
city: 'city',
|
||||
country: state.country,
|
||||
firstname: 'firstname',
|
||||
lastname: 'lastname',
|
||||
company: 'company',
|
||||
phone: 'phone',
|
||||
state_id: state.id,
|
||||
state_name: state.name,
|
||||
zipcode: 'zip_code')
|
||||
address1: 'address1',
|
||||
address2: 'address2',
|
||||
alternative_phone: 'alternative_phone',
|
||||
city: 'city',
|
||||
country: state.country,
|
||||
firstname: 'firstname',
|
||||
lastname: 'lastname',
|
||||
company: 'company',
|
||||
phone: 'phone',
|
||||
state_id: state.id,
|
||||
state_name: state.name,
|
||||
zipcode: 'zip_code')
|
||||
|
||||
cloned = original.clone
|
||||
|
||||
|
||||
@@ -60,7 +60,7 @@ describe Spree::Order::Checkout do
|
||||
it "cannot transition to address without any line items" do
|
||||
expect(order.line_items).to be_blank
|
||||
expect(lambda { order.next! }).to raise_error(StateMachine::InvalidTransition,
|
||||
/#{Spree.t(:there_are_no_items_for_this_order)}/)
|
||||
/#{Spree.t(:there_are_no_items_for_this_order)}/)
|
||||
end
|
||||
|
||||
context "from address" do
|
||||
@@ -83,7 +83,7 @@ describe Spree::Order::Checkout do
|
||||
specify do
|
||||
transition = lambda { order.next! }
|
||||
expect(transition).to raise_error(StateMachine::InvalidTransition,
|
||||
/#{Spree.t(:items_cannot_be_shipped)}/)
|
||||
/#{Spree.t(:items_cannot_be_shipped)}/)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user