Generalise email address

This commit is contained in:
Luke Rollans
2019-12-17 13:47:40 +08:00
parent 9fb079c097
commit 0d95c5ae8b

View File

@@ -34,14 +34,14 @@ class PasswordTest < Devise::IntegrationTest
end
test 'reset password should send to user record email and avoid case mapping collisions' do
create_user(email: 'luke@github.com')
create_user(email: 'user@github.com')
request_forgot_password do
fill_in 'email', with: 'luke@gıthub.com'
fill_in 'email', with: 'user@gıthub.com'
end
mail = ActionMailer::Base.deliveries.last
assert_equal ['luke@github.com'], mail.to
assert_equal ['user@github.com'], mail.to
end
test 'reset password with email of different case should succeed when email is in the list of case insensitive keys' do