negarmoji 0.1.5 → 0.1.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/db/negarmoji.json +8 -1902
- data/lib/negarmoji/version.rb +1 -1
- data/test/emoji_test.rb +0 -24
- metadata +2 -2
data/lib/negarmoji/version.rb
CHANGED
data/test/emoji_test.rb
CHANGED
@@ -74,30 +74,6 @@ class EmojiTest < TestCase
|
|
74
74
|
assert_equal [], duplicates, "some negarmoji aliases have duplicates"
|
75
75
|
end
|
76
76
|
|
77
|
-
test "missing or incorrect unicodes" do
|
78
|
-
emoji_map, = EmojiTestParser.parse(File.expand_path("../vendor/unicode-emoji-test.txt", __dir__))
|
79
|
-
source_unicode_emoji = emoji_map.values
|
80
|
-
supported_sequences = Emoji.all.flat_map(&:unicode_aliases)
|
81
|
-
text_glyphs = Emoji.const_get(:TEXT_GLYPHS)
|
82
|
-
|
83
|
-
missing = 0
|
84
|
-
message = "Missing or incorrect unicodes:\n"
|
85
|
-
source_unicode_emoji.each do |emoji|
|
86
|
-
emoji[:sequences].each do |raw|
|
87
|
-
next if text_glyphs.include?(raw) || Emoji.find_by_unicode(raw)
|
88
|
-
|
89
|
-
message << format("%s (%s)", Emoji::Character.hex_inspect(raw), emoji[:description])
|
90
|
-
if (found = Emoji.find_by_unicode(raw.gsub("\u{fe0f}", "")))
|
91
|
-
message << format(" - could be %s (:%s:)", found.hex_inspect, found.name)
|
92
|
-
end
|
93
|
-
message << "\n"
|
94
|
-
missing += 1
|
95
|
-
end
|
96
|
-
end
|
97
|
-
|
98
|
-
assert_equal 0, missing, message
|
99
|
-
end
|
100
|
-
|
101
77
|
test "negarmoji have category" do
|
102
78
|
missing = Emoji.all.select { |e| e.category.to_s.empty? }
|
103
79
|
assert_equal [], missing.map(&:name), "some negarmoji don't have a category"
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: negarmoji
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mohammad Mahdi Baghbani Pourvahid
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-01-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|