spec/support/utilities.rb
# Signs in an admin or a NPO
Signs in an admin or a NPO
Signs in an admin or a NPO
def sign_in(user)
  visit Rails.application.routes.url_helpers.send("new_#{user.class.name.underscore}_session_path")
  fill_in "Email", with: user.email
  fill_in "Password", with: user.password
  click_button "Log in"
end
def sign_in ( user ) visit Rails . application . routes . url_helpers . send ( "new_#{user.class.name.underscore}_session_path" ) fill_in "Email" , with : user . email fill_in "Password" , with : user . password click_button "Log in" end
Signs in an admin or a NPO
Signs in an admin or a NPO
user
<not_specific>