typoed_email_validator: add new ending to the typo list

This commit is contained in:
Georg Gadinger 2022-04-10 09:55:05 +02:00
parent fdd8bf7962
commit 6f2c2654a1
2 changed files with 2 additions and 0 deletions

View File

@ -17,6 +17,7 @@ class TypoedEmailValidator < ActiveModel::EachValidator
gmaill.com
gmali.com
hotmaill.com
iclould.com
icluod.com
].map { "@#{_1}" }
].freeze

View File

@ -85,6 +85,7 @@ RSpec.describe User, type: :model do
include_examples "invalid email", "fritz.fantom@gmali.com"
include_examples "invalid email", "fritz.fantom@hotmailcom"
include_examples "invalid email", "fritz.fantom@hotmaill.com"
include_examples "invalid email", "fritz.fantom@iclould.com"
include_examples "invalid email", "fritz.fantom@icluod.com"
# no TLD
include_examples "invalid email", "fritz.fantom@gmail"