diff --git a/app/controllers/auth/passwords_controller.rb b/app/controllers/auth/passwords_controller.rb index 317c4aa29..6c05debb5 100644 --- a/app/controllers/auth/passwords_controller.rb +++ b/app/controllers/auth/passwords_controller.rb @@ -11,7 +11,6 @@ class Auth::PasswordsController < Devise::PasswordsController resource.errors.add :email, "Enter an email address in the correct format, like name@example.com" render "devise/passwords/new", status: :unprocessable_entity else - flash[:notice] = "Reset password instructions have been sent to #{@email}" render "devise/confirmations/reset" end end diff --git a/spec/features/user_spec.rb b/spec/features/user_spec.rb index 7b8351013..f14cd43fd 100644 --- a/spec/features/user_spec.rb +++ b/spec/features/user_spec.rb @@ -72,13 +72,6 @@ RSpec.describe "User Features" do fill_in("user[email]", with: user.email) expect { click_button("Send email") }.to change { ActionMailer::Base.deliveries.count }.by(1) end - - it " is shown the password reset confirmation page and successful flash message shows" do - visit("/users/password/new") - fill_in("user[email]", with: user.email) - click_button("Send email") - expect(page).to have_css ".govuk-notification-banner.govuk-notification-banner--success" - end end context "If user not logged in" do