Browse Source
# Context - We're currently using a custom fork of devise # Changes - Switch back to original devise gem - This gives us the benefit of being able to more easily upgrade when the time comes - Minor fixes to validation copy during password reset process which were not correctpull/1648/head
Phil Lee
2 years ago
committed by
GitHub
7 changed files with 34 additions and 21 deletions
@ -0,0 +1,15 @@
|
||||
require "rails_helper" |
||||
|
||||
RSpec.describe "User sign in" do |
||||
let(:user) { FactoryBot.create(:user) } |
||||
|
||||
context "when wrong credentials" do |
||||
it "shows correct error message" do |
||||
visit("/account/sign-in") |
||||
fill_in("user[email]", with: user.email) |
||||
fill_in("user[password]", with: "wrong_password") |
||||
click_button("Sign in") |
||||
expect(page).to have_content("Incorrect email or password") |
||||
end |
||||
end |
||||
end |
Loading…
Reference in new issue