File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -105,7 +105,7 @@ RSpec/BeforeAfterAll:
105105
106106# Offense count: 5
107107# This cop supports safe autocorrection (--autocorrect).
108- RSpec/ Capybara/CurrentPathExpectation :
108+ Capybara/CurrentPathExpectation :
109109 Exclude :
110110 - ' spec/features/admin/sign_in_spec.rb'
111111 - ' spec/features/sign_in_spec.rb'
@@ -221,7 +221,6 @@ RSpec/InstanceVariable:
221221 - ' spec/controllers/spree/admin/user_passwords_controller_spec.rb'
222222 - ' spec/controllers/spree/user_passwords_controller_spec.rb'
223223 - ' spec/controllers/spree/user_registrations_controller_spec.rb'
224- - ' spec/controllers/spree/user_sessions_controller_spec.rb'
225224 - ' spec/features/admin/sign_in_spec.rb'
226225 - ' spec/features/checkout_spec.rb'
227226 - ' spec/features/sign_in_spec.rb'
Original file line number Diff line number Diff line change 33RSpec . describe Spree ::Admin ::UserSessionsController , type : :controller do
44 let ( :user ) { create ( :user , password : 'secret' ) }
55
6- before { @request . env [ 'devise.mapping' ] = Devise . mappings [ :spree_user ] }
6+ before { @request . env [ 'devise.mapping' ] = Devise . mappings [ :spree_user ] } # rubocop:disable RSpec/InstanceVariable
77
88 it "redirects to the admin root after signing in with no stored location" do
99 get :new
1010
11- post ( :create ,
12- params : {
13- spree_user : {
14- email : user . email ,
15- password : 'secret'
16- } ,
17- }
18- )
11+ post ( :create , params : {
12+ spree_user : {
13+ email : user . email ,
14+ password : 'secret'
15+ } ,
16+ } )
1917
2018 expect ( response ) . to redirect_to spree . admin_path
2119 end
Original file line number Diff line number Diff line change 33RSpec . describe Spree ::UserSessionsController , type : :controller do
44 let ( :user ) { create ( :user ) }
55
6- before { @request . env [ 'devise.mapping' ] = Devise . mappings [ :spree_user ] }
6+ before { @request . env [ 'devise.mapping' ] = Devise . mappings [ :spree_user ] } # rubocop:disable RSpec/InstanceVariable
77
88 context "#create" do
99 let ( :format ) { :html }
1010 let ( :password ) { 'secret' }
1111
1212 subject do
13- post ( :create ,
14- params : {
15- spree_user : {
16- email : user . email ,
17- password : password
18- } ,
19- format : format
20- }
21- )
13+ post ( :create , params : {
14+ spree_user : {
15+ email : user . email ,
16+ password : password
17+ } ,
18+ format : format
19+ } )
2220 end
2321
2422 context "when using correct login information" do
You can’t perform that action at this time.
0 commit comments