π₯ custom emoji
On GitHub.com, people predominantly use `:octocat:` and `:shipit:`, but other custom emoji not as much. These two most used custom emoji also happen to be specific to the GitHub brand, so it makes more sense that we add them as custom emoji in the app itself rather than shipping them with the gemoji library.
120
db/emoji.json
|
@ -20612,124 +20612,4 @@
|
|||
, "unicode_version": "11.0"
|
||||
, "ios_version": "12.1"
|
||||
}
|
||||
, {
|
||||
"aliases": [
|
||||
"basecamp"
|
||||
]
|
||||
, "tags": [
|
||||
]
|
||||
}
|
||||
, {
|
||||
"aliases": [
|
||||
"basecampy"
|
||||
]
|
||||
, "tags": [
|
||||
]
|
||||
}
|
||||
, {
|
||||
"aliases": [
|
||||
"bowtie"
|
||||
]
|
||||
, "tags": [
|
||||
]
|
||||
}
|
||||
, {
|
||||
"aliases": [
|
||||
"feelsgood"
|
||||
]
|
||||
, "tags": [
|
||||
]
|
||||
}
|
||||
, {
|
||||
"aliases": [
|
||||
"finnadie"
|
||||
]
|
||||
, "tags": [
|
||||
]
|
||||
}
|
||||
, {
|
||||
"aliases": [
|
||||
"goberserk"
|
||||
]
|
||||
, "tags": [
|
||||
]
|
||||
}
|
||||
, {
|
||||
"aliases": [
|
||||
"godmode"
|
||||
]
|
||||
, "tags": [
|
||||
]
|
||||
}
|
||||
, {
|
||||
"aliases": [
|
||||
"hurtrealbad"
|
||||
]
|
||||
, "tags": [
|
||||
]
|
||||
}
|
||||
, {
|
||||
"aliases": [
|
||||
"neckbeard"
|
||||
]
|
||||
, "tags": [
|
||||
]
|
||||
}
|
||||
, {
|
||||
"aliases": [
|
||||
"octocat"
|
||||
]
|
||||
, "tags": [
|
||||
]
|
||||
}
|
||||
, {
|
||||
"aliases": [
|
||||
"rage1"
|
||||
]
|
||||
, "tags": [
|
||||
]
|
||||
}
|
||||
, {
|
||||
"aliases": [
|
||||
"rage2"
|
||||
]
|
||||
, "tags": [
|
||||
]
|
||||
}
|
||||
, {
|
||||
"aliases": [
|
||||
"rage3"
|
||||
]
|
||||
, "tags": [
|
||||
]
|
||||
}
|
||||
, {
|
||||
"aliases": [
|
||||
"rage4"
|
||||
]
|
||||
, "tags": [
|
||||
]
|
||||
}
|
||||
, {
|
||||
"aliases": [
|
||||
"shipit"
|
||||
, "squirrel"
|
||||
]
|
||||
, "tags": [
|
||||
]
|
||||
}
|
||||
, {
|
||||
"aliases": [
|
||||
"suspect"
|
||||
]
|
||||
, "tags": [
|
||||
]
|
||||
}
|
||||
, {
|
||||
"aliases": [
|
||||
"trollface"
|
||||
]
|
||||
, "tags": [
|
||||
]
|
||||
}
|
||||
]
|
||||
|
|
ΠΠ²ΠΎΠΈΡΠ½ΡΠ΅ Π΄Π°Π½Π½ΡΠ΅
images/basecamp.png
ΠΠΎ Π¨ΠΈΡΠΈΠ½Π°: | ΠΡΡΠΎΡΠ°: | Π Π°Π·ΠΌΠ΅Ρ: 898 B |
ΠΠ²ΠΎΠΈΡΠ½ΡΠ΅ Π΄Π°Π½Π½ΡΠ΅
images/basecampy.png
ΠΠΎ Π¨ΠΈΡΠΈΠ½Π°: | ΠΡΡΠΎΡΠ°: | Π Π°Π·ΠΌΠ΅Ρ: 2.9 KiB |
ΠΠ²ΠΎΠΈΡΠ½ΡΠ΅ Π΄Π°Π½Π½ΡΠ΅
images/bowtie.png
ΠΠΎ Π¨ΠΈΡΠΈΠ½Π°: | ΠΡΡΠΎΡΠ°: | Π Π°Π·ΠΌΠ΅Ρ: 2.7 KiB |
ΠΠ²ΠΎΠΈΡΠ½ΡΠ΅ Π΄Π°Π½Π½ΡΠ΅
images/feelsgood.png
ΠΠΎ Π¨ΠΈΡΠΈΠ½Π°: | ΠΡΡΠΎΡΠ°: | Π Π°Π·ΠΌΠ΅Ρ: 1.1 KiB |
ΠΠ²ΠΎΠΈΡΠ½ΡΠ΅ Π΄Π°Π½Π½ΡΠ΅
images/finnadie.png
ΠΠΎ Π¨ΠΈΡΠΈΠ½Π°: | ΠΡΡΠΎΡΠ°: | Π Π°Π·ΠΌΠ΅Ρ: 1.1 KiB |
ΠΠ²ΠΎΠΈΡΠ½ΡΠ΅ Π΄Π°Π½Π½ΡΠ΅
images/goberserk.png
ΠΠΎ Π¨ΠΈΡΠΈΠ½Π°: | ΠΡΡΠΎΡΠ°: | Π Π°Π·ΠΌΠ΅Ρ: 1.2 KiB |
ΠΠ²ΠΎΠΈΡΠ½ΡΠ΅ Π΄Π°Π½Π½ΡΠ΅
images/godmode.png
ΠΠΎ Π¨ΠΈΡΠΈΠ½Π°: | ΠΡΡΠΎΡΠ°: | Π Π°Π·ΠΌΠ΅Ρ: 1.0 KiB |
ΠΠ²ΠΎΠΈΡΠ½ΡΠ΅ Π΄Π°Π½Π½ΡΠ΅
images/hurtrealbad.png
ΠΠΎ Π¨ΠΈΡΠΈΠ½Π°: | ΠΡΡΠΎΡΠ°: | Π Π°Π·ΠΌΠ΅Ρ: 1.3 KiB |
ΠΠ²ΠΎΠΈΡΠ½ΡΠ΅ Π΄Π°Π½Π½ΡΠ΅
images/neckbeard.png
ΠΠΎ Π¨ΠΈΡΠΈΠ½Π°: | ΠΡΡΠΎΡΠ°: | Π Π°Π·ΠΌΠ΅Ρ: 3.1 KiB |
ΠΠ²ΠΎΠΈΡΠ½ΡΠ΅ Π΄Π°Π½Π½ΡΠ΅
images/octocat.png
ΠΠΎ Π¨ΠΈΡΠΈΠ½Π°: | ΠΡΡΠΎΡΠ°: | Π Π°Π·ΠΌΠ΅Ρ: 2.4 KiB |
ΠΠ²ΠΎΠΈΡΠ½ΡΠ΅ Π΄Π°Π½Π½ΡΠ΅
images/rage1.png
ΠΠΎ Π¨ΠΈΡΠΈΠ½Π°: | ΠΡΡΠΎΡΠ°: | Π Π°Π·ΠΌΠ΅Ρ: 1.0 KiB |
ΠΠ²ΠΎΠΈΡΠ½ΡΠ΅ Π΄Π°Π½Π½ΡΠ΅
images/rage2.png
ΠΠΎ Π¨ΠΈΡΠΈΠ½Π°: | ΠΡΡΠΎΡΠ°: | Π Π°Π·ΠΌΠ΅Ρ: 1.0 KiB |
ΠΠ²ΠΎΠΈΡΠ½ΡΠ΅ Π΄Π°Π½Π½ΡΠ΅
images/rage3.png
ΠΠΎ Π¨ΠΈΡΠΈΠ½Π°: | ΠΡΡΠΎΡΠ°: | Π Π°Π·ΠΌΠ΅Ρ: 1.1 KiB |
ΠΠ²ΠΎΠΈΡΠ½ΡΠ΅ Π΄Π°Π½Π½ΡΠ΅
images/rage4.png
ΠΠΎ Π¨ΠΈΡΠΈΠ½Π°: | ΠΡΡΠΎΡΠ°: | Π Π°Π·ΠΌΠ΅Ρ: 1.2 KiB |
ΠΠ²ΠΎΠΈΡΠ½ΡΠ΅ Π΄Π°Π½Π½ΡΠ΅
images/shipit.png
ΠΠΎ Π¨ΠΈΡΠΈΠ½Π°: | ΠΡΡΠΎΡΠ°: | Π Π°Π·ΠΌΠ΅Ρ: 4.5 KiB |
ΠΠ²ΠΎΠΈΡΠ½ΡΠ΅ Π΄Π°Π½Π½ΡΠ΅
images/suspect.png
ΠΠΎ Π¨ΠΈΡΠΈΠ½Π°: | ΠΡΡΠΎΡΠ°: | Π Π°Π·ΠΌΠ΅Ρ: 1004 B |
ΠΠ²ΠΎΠΈΡΠ½ΡΠ΅ Π΄Π°Π½Π½ΡΠ΅
images/trollface.png
ΠΠΎ Π¨ΠΈΡΠΈΠ½Π°: | ΠΡΡΠΎΡΠ°: | Π Π°Π·ΠΌΠ΅Ρ: 2.7 KiB |
|
@ -8,7 +8,7 @@ class EmojiTest < TestCase
|
|||
end
|
||||
|
||||
test "unicodes set contains the unicodes" do
|
||||
min_size = Emoji.all.reject(&:custom?).size
|
||||
min_size = Emoji.all.size
|
||||
count = Emoji.all.map(&:unicode_aliases).flatten.size
|
||||
assert count > min_size, "there were too few unicode mappings: #{count}"
|
||||
end
|
||||
|
@ -112,7 +112,7 @@ class EmojiTest < TestCase
|
|||
end
|
||||
|
||||
test "emoji have category" do
|
||||
missing = Emoji.all.select { |e| !e.custom? && e.category.to_s.empty? }
|
||||
missing = Emoji.all.select { |e| e.category.to_s.empty? }
|
||||
assert_equal [], missing.map(&:name), "some emoji don't have a category"
|
||||
|
||||
emoji = Emoji.find_by_alias('family_man_woman_girl')
|
||||
|
@ -120,7 +120,7 @@ class EmojiTest < TestCase
|
|||
end
|
||||
|
||||
test "emoji have description" do
|
||||
missing = Emoji.all.select { |e| !e.custom? && e.description.to_s.empty? }
|
||||
missing = Emoji.all.select { |e| e.description.to_s.empty? }
|
||||
assert_equal [], missing.map(&:name), "some emoji don't have a description"
|
||||
|
||||
emoji = Emoji.find_by_alias('family_man_woman_girl')
|
||||
|
@ -133,27 +133,16 @@ class EmojiTest < TestCase
|
|||
end
|
||||
|
||||
test "emoji have iOS version" do
|
||||
missing = Emoji.all.select { |e| !e.custom? && e.ios_version.to_s.empty? }
|
||||
missing = Emoji.all.select { |e| e.ios_version.to_s.empty? }
|
||||
assert_equal [], missing.map(&:name), "some emoji don't have an iOS version"
|
||||
|
||||
emoji = Emoji.find_by_alias('family_man_woman_girl')
|
||||
assert_equal '8.3', emoji.ios_version
|
||||
end
|
||||
|
||||
test "custom emojis" do
|
||||
test "no custom emojis" do
|
||||
custom = Emoji.all.select(&:custom?)
|
||||
assert custom.size > 0
|
||||
|
||||
custom.each do |emoji|
|
||||
assert_nil emoji.raw
|
||||
assert_equal [], emoji.unicode_aliases
|
||||
end
|
||||
end
|
||||
|
||||
test "custom emoji names" do
|
||||
custom_names = Emoji.all.select(&:custom?).map(&:name)
|
||||
assert custom_names.include?("shipit")
|
||||
assert !custom_names.include?("+1")
|
||||
assert 0, custom.size
|
||||
end
|
||||
|
||||
test "create" do
|
||||
|
|