FIX: do not treat :: as a valid emoji

This commit is contained in:
Joffrey JAFFEUX
2018-03-05 15:35:24 +01:00
parent 057fa049e6
commit ce1994beea
2 changed files with 5 additions and 1 deletions

View File

@ -17,6 +17,10 @@ describe MaxEmojisValidator do
record.title = '🧐 Lots of emojis here 🎃 :joy: :sunglasses:'
validate
expect(record.errors[:title][0]).to eq(I18n.t("errors.messages.max_emojis", max_emojis_count: 3))
record.title = ':joy: :blush: :smile: is not only about emojis: Happyness::start()'
validate
expect(record.valid?).to be true
end
end