More emojis! Because why not?

This commit is contained in:
Storm Dragon committed 2026-10-29 00:39:04 -04:00
1 parent 21cecd1e71
commit 07354d6ede
9 files changed
+11247 -763

No files matched your search

+396 -5
View File
@@ -27,6 +27,8 @@ var categories = []struct {
{ID: "😭", Label: "Crying"},
{ID: "😈", Label: "Devil"},
{ID: "😵", Label: "Dizzy"},
{ID: "🦵", Label: "Leg"},
{ID: "🧑‍🚀", Label: "Astronaut"},
{ID: "🤯", Label: "Exploding head"},
{ID: "🤬", Label: "Face with symbols"},
{ID: "😀", Label: "Grinning"},
@@ -44,8 +46,72 @@ var categories = []struct {
{ID: "😱", Label: "Screaming"},
{ID: "😊", Label: "Smiling"},
{ID: "😏", Label: "Smirking"},
{ID: "🤩", Label: "Star-struck"},
{ID: "👍", Label: "Thumbs up"},
{ID: "😉", Label: "Winking"},
{ID: "🧑‍💻", Label: "Technologist"},
{ID: "🥳", Label: "Partying face"},
{ID: "🤔", Label: "Thinking face"},
{ID: "🫠", Label: "Melting face"},
{ID: "🥲", Label: "Smiling face with tear"},
{ID: "🤠", Label: "Cowboy hat face"},
{ID: "🥱", Label: "Yawning face"},
{ID: "🫡", Label: "Saluting face"},
{ID: "🤝", Label: "Handshake"},
{ID: "👏", Label: "Clapping hands"},
{ID: "🙌", Label: "Raising hands"},
{ID: "🫶", Label: "Heart hands"},
{ID: "👌", Label: "OK hand"},
{ID: "👎", Label: "Thumbs down"},
{ID: "💪", Label: "Flexed biceps"},
{ID: "🦶", Label: "Foot"},
{ID: "👶", Label: "Baby"},
{ID: "👽", Label: "Alien"},
{ID: "👼", Label: "Baby Angel"},
{ID: "👈", Label: "Backhand Index Pointing Left"},
{ID: "👉", Label: "Backhand Index Pointing Right"},
{ID: "🤙", Label: "Call Me Hand"},
{ID: "🤡", Label: "Clown Face"},
{ID: "🤞", Label: "Crossed Fingers"},
{ID: "🧝", Label: "Elf"},
{ID: "🧐", Label: "Face With Monocle"},
{ID: "😛", Label: "Face With Tongue"},
{ID: "🧚", Label: "Fairy"},
{ID: "🧞", Label: "Genie"},
{ID: "👻", Label: "Ghost"},
{ID: "👺", Label: "Goblin"},
{ID: "😃", Label: "Grinning Face With Big Eyes"},
{ID: "😄", Label: "Grinning Face With Smiling Eyes"},
{ID: "🤟", Label: "Love You Gesture"},
{ID: "🧙", Label: "Mage"},
{ID: "🧜", Label: "Merperson"},
{ID: "🤶", Label: "Mrs. Claus"},
{ID: "🤓", Label: "Nerd Face"},
{ID: "👹", Label: "Ogre"},
{ID: "🤌", Label: "Pinched Fingers"},
{ID: "🤏", Label: "Pinching Hand"},
{ID: "🤚", Label: "Raised Back Of Hand"},
{ID: "✋", Label: "Raised Hand"},
{ID: "🤖", Label: "Robot"},
{ID: "🙂", Label: "Slightly Smiling Face"},
{ID: "😇", Label: "Smiling Face With Halo"},
{ID: "🦸", Label: "Superhero"},
{ID: "🦹", Label: "Supervillain"},
{ID: "🙃", Label: "Upside Down Face"},
{ID: "🧛", Label: "Vampire"},
{ID: "🖖", Label: "Vulcan Salute"},
{ID: "👋", Label: "Waving Hand"},
{ID: "🤪", Label: "Zany Face"},
{ID: "🧟", Label: "Zombie"},
{ID: "🤭", Label: "Face With Hand Over Mouth"},
{ID: "👂", Label: "Ear"},
{ID: "👃", Label: "Nose"},
{ID: "👣", Label: "Footprints"},
{ID: "👀", Label: "Eyes"},
{ID: "🧠", Label: "Brain"},
{ID: "🦷", Label: "Tooth"},
{ID: "🦾", Label: "Mechanical Arm"},
{ID: "🦿", Label: "Mechanical Leg"},
}},
{"nature", "Nature", []interaction.Choice{
{ID: "🦋", Label: "Butterfly"},
@@ -59,6 +125,116 @@ var categories = []struct {
{ID: "🌻", Label: "Sunflower"},
{ID: "🌳", Label: "Tree"},
{ID: "🐺", Label: "Wolf"},
{ID: "🐝", Label: "Bee"},
{ID: "🐞", Label: "Lady beetle"},
{ID: "🐢", Label: "Turtle"},
{ID: "🐍", Label: "Snake"},
{ID: "🐙", Label: "Octopus"},
{ID: "🐬", Label: "Dolphin"},
{ID: "🐳", Label: "Spouting whale"},
{ID: "🐠", Label: "Tropical fish"},
{ID: "🦈", Label: "Shark"},
{ID: "🐘", Label: "Elephant"},
{ID: "🦒", Label: "Giraffe"},
{ID: "🦓", Label: "Zebra"},
{ID: "🦌", Label: "Deer"},
{ID: "🐴", Label: "Horse face"},
{ID: "🐮", Label: "Cow face"},
{ID: "🐷", Label: "Pig face"},
{ID: "🐭", Label: "Mouse face"},
{ID: "🐹", Label: "Hamster"},
{ID: "🦊", Label: "Fox"},
{ID: "🐻", Label: "Bear"},
{ID: "🦡", Label: "Badger"},
{ID: "🦇", Label: "Bat"},
{ID: "🦫", Label: "Beaver"},
{ID: "🐗", Label: "Boar"},
{ID: "🐪", Label: "Camel"},
{ID: "🐿️", Label: "Chipmunk"},
{ID: "🐄", Label: "Cow"},
{ID: "🐕", Label: "Dog"},
{ID: "🐑", Label: "Ewe"},
{ID: "🐐", Label: "Goat"},
{ID: "🦍", Label: "Gorilla"},
{ID: "🦮", Label: "Guide Dog"},
{ID: "🦔", Label: "Hedgehog"},
{ID: "🦛", Label: "Hippopotamus"},
{ID: "🦘", Label: "Kangaroo"},
{ID: "🐨", Label: "Koala"},
{ID: "🐆", Label: "Leopard"},
{ID: "🦁", Label: "Lion"},
{ID: "🦙", Label: "Llama"},
{ID: "🐵", Label: "Monkey Face"},
{ID: "🦧", Label: "Orangutan"},
{ID: "🦦", Label: "Otter"},
{ID: "🐂", Label: "Ox"},
{ID: "🐼", Label: "Panda"},
{ID: "🐾", Label: "Paw Prints"},
{ID: "🐩", Label: "Poodle"},
{ID: "🦝", Label: "Raccoon"},
{ID: "🐏", Label: "Ram"},
{ID: "🐀", Label: "Rat"},
{ID: "🦏", Label: "Rhinoceros"},
{ID: "🐕‍🦺", Label: "Service Dog"},
{ID: "🦨", Label: "Skunk"},
{ID: "🦥", Label: "Sloth"},
{ID: "🐯", Label: "Tiger Face"},
{ID: "🦄", Label: "Unicorn"},
{ID: "🐃", Label: "Water Buffalo"},
{ID: "🦢", Label: "Swan"},
{ID: "🦉", Label: "Owl"},
{ID: "🦚", Label: "Peacock"},
{ID: "🦜", Label: "Parrot"},
{ID: "🕊️", Label: "Dove"},
{ID: "🦅", Label: "Eagle"},
{ID: "🦆", Label: "Duck"},
{ID: "🐸", Label: "Frog"},
{ID: "🐊", Label: "Crocodile"},
{ID: "🦎", Label: "Lizard"},
{ID: "🐲", Label: "Dragon Face"},
{ID: "🐉", Label: "Dragon"},
{ID: "🐋", Label: "Whale"},
{ID: "🐟", Label: "Fish"},
{ID: "🐡", Label: "Blowfish"},
{ID: "🐌", Label: "Snail"},
{ID: "🐛", Label: "Bug"},
{ID: "🐜", Label: "Ant"},
{ID: "🪲", Label: "Beetle"},
{ID: "🦗", Label: "Cricket"},
{ID: "🦂", Label: "Scorpion"},
{ID: "🦟", Label: "Mosquito"},
{ID: "🦠", Label: "Microbe"},
{ID: "💐", Label: "Bouquet"},
{ID: "💮", Label: "White Flower"},
{ID: "🏵️", Label: "Rosette"},
{ID: "🥀", Label: "Wilted Flower"},
{ID: "🌺", Label: "Hibiscus"},
{ID: "🌼", Label: "Blossom"},
{ID: "🌷", Label: "Tulip"},
{ID: "🌱", Label: "Seedling"},
{ID: "🌲", Label: "Evergreen Tree"},
{ID: "🌴", Label: "Palm Tree"},
{ID: "🌵", Label: "Cactus"},
{ID: "🌾", Label: "Sheaf Of Rice"},
{ID: "🌿", Label: "Herb"},
{ID: "🍀", Label: "Four Leaf Clover"},
{ID: "🍁", Label: "Maple Leaf"},
{ID: "🍂", Label: "Fallen Leaf"},
{ID: "🍃", Label: "Leaf Fluttering In Wind"},
{ID: "🍄", Label: "Mushroom"},
{ID: "🌰", Label: "Chestnut"},
{ID: "🌑", Label: "New Moon"},
{ID: "🌔", Label: "Waxing Gibbous Moon"},
{ID: "🌕", Label: "Full Moon"},
{ID: "🌞", Label: "Sun With Face"},
{ID: "☁️", Label: "Cloud"},
{ID: "🌪️", Label: "Tornado"},
{ID: "🌬️", Label: "Wind Face"},
{ID: "☔", Label: "Umbrella With Rain Drops"},
{ID: "❄️", Label: "Snowflake"},
{ID: "☄️", Label: "Comet"},
{ID: "💧", Label: "Droplet"},
{ID: "🌊", Label: "Water Wave"},
}},
{"food", "Food", []interaction.Choice{
{ID: "🍎", Label: "Apple"},
@@ -71,30 +247,233 @@ var categories = []struct {
{ID: "🍕", Label: "Pizza"},
{ID: "🍓", Label: "Strawberry"},
{ID: "🌮", Label: "Taco"},
{ID: "🍐", Label: "Pear"},
{ID: "🍊", Label: "Tangerine"},
{ID: "🍋", Label: "Lemon"},
{ID: "🍌", Label: "Banana"},
{ID: "🍉", Label: "Watermelon"},
{ID: "🍇", Label: "Grapes"},
{ID: "🍒", Label: "Cherries"},
{ID: "🍑", Label: "Peach"},
{ID: "🥭", Label: "Mango"},
{ID: "🍍", Label: "Pineapple"},
{ID: "🥥", Label: "Coconut"},
{ID: "🥝", Label: "Kiwi fruit"},
{ID: "🍅", Label: "Tomato"},
{ID: "🥕", Label: "Carrot"},
{ID: "🌽", Label: "Corn"},
{ID: "🥔", Label: "Potato"},
{ID: "🍞", Label: "Bread"},
{ID: "🥐", Label: "Croissant"},
{ID: "🥞", Label: "Pancakes"},
{ID: "🧀", Label: "Cheese"},
{ID: "🥖", Label: "Baguette Bread"},
{ID: "🍱", Label: "Bento Box"},
{ID: "🫐", Label: "Blueberries"},
{ID: "🥦", Label: "Broccoli"},
{ID: "🧈", Label: "Butter"},
{ID: "🥫", Label: "Canned Food"},
{ID: "🍛", Label: "Curry Rice"},
{ID: "🍡", Label: "Dango"},
{ID: "🥟", Label: "Dumpling"},
{ID: "🍆", Label: "Eggplant"},
{ID: "🥠", Label: "Fortune Cookie"},
{ID: "🍤", Label: "Fried Shrimp"},
{ID: "🍏", Label: "Green Apple"},
{ID: "🥗", Label: "Green Salad"},
{ID: "🦞", Label: "Lobster"},
{ID: "🥮", Label: "Moon Cake"},
{ID: "🍢", Label: "Oden"},
{ID: "🦪", Label: "Oyster"},
{ID: "🍿", Label: "Popcorn"},
{ID: "🥨", Label: "Pretzel"},
{ID: "🍙", Label: "Rice Ball"},
{ID: "🍘", Label: "Rice Cracker"},
{ID: "🍠", Label: "Roasted Sweet Potato"},
{ID: "🧂", Label: "Salt"},
{ID: "🍝", Label: "Spaghetti"},
{ID: "🍜", Label: "Steaming Bowl"},
{ID: "🍣", Label: "Sushi"},
{ID: "🥡", Label: "Takeout Box"},
{ID: "🥯", Label: "Bagel"},
{ID: "🧇", Label: "Waffle"},
{ID: "🥘", Label: "Shallow Pan Of Food"},
{ID: "🫕", Label: "Fondue"},
{ID: "🍨", Label: "Ice Cream"},
{ID: "🍧", Label: "Shaved Ice"},
{ID: "🍪", Label: "Cookie"},
{ID: "🧁", Label: "Cupcake"},
{ID: "🥧", Label: "Pie"},
{ID: "🍫", Label: "Chocolate Bar"},
{ID: "🍬", Label: "Candy"},
{ID: "🍭", Label: "Lollipop"},
{ID: "🍮", Label: "Custard"},
{ID: "🍯", Label: "Honey Pot"},
{ID: "🍼", Label: "Baby Bottle"},
{ID: "🥛", Label: "Glass Of Milk"},
{ID: "🍶", Label: "Sake"},
{ID: "🍷", Label: "Wine Glass"},
{ID: "🍸", Label: "Cocktail Glass"},
{ID: "🍹", Label: "Tropical Drink"},
{ID: "🥂", Label: "Clinking Glasses"},
{ID: "🥃", Label: "Tumbler Glass"},
{ID: "🥤", Label: "Cup With Straw"},
}},
{"activity", "Activity", []interaction.Choice{
{ID: "⚽", Label: "Soccer ball"},
{ID: "🏀", Label: "Basketball"},
{ID: "🏈", Label: "American football"},
{ID: "⚾", Label: "Baseball"},
{ID: "🎾", Label: "Tennis ball"},
{ID: "🏐", Label: "Volleyball"},
{ID: "🥏", Label: "Flying disc"},
{ID: "🏉", Label: "Rugby football"},
{ID: "🎱", Label: "Pool 8 ball"},
{ID: "🏓", Label: "Table tennis"},
{ID: "🏸", Label: "Badminton"},
{ID: "🏒", Label: "Ice hockey"},
{ID: "🥅", Label: "Goal net"},
{ID: "🥍", Label: "Lacrosse"},
{ID: "🏏", Label: "Cricket game"},
{ID: "🛹", Label: "Skateboard"},
{ID: "🛷", Label: "Sled"},
{ID: "🏆", Label: "Trophy"},
{ID: "🎮", Label: "Video game"},
{ID: "🎯", Label: "Direct hit"},
{ID: "🥇", Label: "1st Place Medal"},
{ID: "🥈", Label: "2nd Place Medal"},
{ID: "🥉", Label: "3rd Place Medal"},
{ID: "🥌", Label: "Curling Stone"},
{ID: "🤿", Label: "Diving Mask"},
{ID: "🎣", Label: "Fishing Pole"},
{ID: "⛸️", Label: "Ice Skate"},
{ID: "🪁", Label: "Kite"},
{ID: "🏌️", Label: "Person Golfing"},
{ID: "🏄", Label: "Person Surfing"},
{ID: "🏊", Label: "Person Swimming"},
{ID: "🛼", Label: "Roller Skate"},
{ID: "🎽", Label: "Running Shirt"},
{ID: "⛷️", Label: "Skier"},
{ID: "🎿", Label: "Skis"},
{ID: "🏔️", Label: "Snow Capped Mountain"},
{ID: "🏂", Label: "Snowboarder"},
{ID: "🏅", Label: "Sports Medal"},
}},
{"travel", "Travel", []interaction.Choice{
{ID: "🚗", Label: "Automobile"},
{ID: "🚌", Label: "Bus"},
{ID: "🚕", Label: "Taxi"},
{ID: "🚓", Label: "Police car"},
{ID: "🚑", Label: "Ambulance"},
{ID: "🚒", Label: "Fire engine"},
{ID: "🚲", Label: "Bicycle"},
{ID: "🚀", Label: "Rocket"},
{ID: "✈️", Label: "Airplane"},
{ID: "⚓", Label: "Anchor"},
{ID: "🛫", Label: "Airplane Departure"},
{ID: "🛺", Label: "Auto Rickshaw"},
{ID: "🛶", Label: "Canoe"},
{ID: "🚧", Label: "Construction"},
{ID: "🚁", Label: "Helicopter"},
{ID: "🛴", Label: "Kick Scooter"},
{ID: "🚈", Label: "Light Rail"},
{ID: "🚐", Label: "Minibus"},
{ID: "🚝", Label: "Monorail"},
{ID: "🏍️", Label: "Motorcycle"},
{ID: "🚍", Label: "Oncoming Bus"},
{ID: "🛻", Label: "Pickup Truck"},
{ID: "🚃", Label: "Railway Car"},
{ID: "⛵", Label: "Sailboat"},
{ID: "🚢", Label: "Ship"},
{ID: "🛩️", Label: "Small Airplane"},
{ID: "🚤", Label: "Speedboat"},
{ID: "🚉", Label: "Station"},
{ID: "🚜", Label: "Tractor"},
{ID: "🚆", Label: "Train"},
{ID: "🚎", Label: "Trolleybus"},
}},
{"objects", "Objects", []interaction.Choice{
{ID: "⌚", Label: "Watch"},
{ID: "📱", Label: "Mobile phone"},
{ID: "💻", Label: "Laptop"},
{ID: "🖥️", Label: "Desktop computer"},
{ID: "🖨️", Label: "Printer"},
{ID: "⌨️", Label: "Keyboard"},
{ID: "🖱️", Label: "Computer mouse"},
{ID: "💾", Label: "Floppy disk"},
{ID: "💿", Label: "Optical disk"},
{ID: "🎥", Label: "Movie camera"},
{ID: "🧮", Label: "Abacus"},
{ID: "🪗", Label: "Accordion"},
{ID: "🪕", Label: "Banjo"},
{ID: "🔋", Label: "Battery"},
{ID: "📷", Label: "Camera"},
{ID: "📸", Label: "Camera With Flash"},
{ID: "🕯️", Label: "Candle"},
{ID: "🎬", Label: "Clapper Board"},
{ID: "🪔", Label: "Diya Lamp"},
{ID: "🥁", Label: "Drum"},
{ID: "📀", Label: "Dvd"},
{ID: "🔌", Label: "Electric Plug"},
{ID: "📽️", Label: "Film Projector"},
{ID: "🧯", Label: "Fire Extinguisher"},
{ID: "🔦", Label: "Flashlight"},
{ID: "🎸", Label: "Guitar"},
{ID: "🎧", Label: "Headphone"},
{ID: "💡", Label: "Light Bulb"},
{ID: "🪘", Label: "Long Drum"},
{ID: "🎤", Label: "Microphone"},
{ID: "🎹", Label: "Musical Keyboard"},
{ID: "🎼", Label: "Musical Score"},
{ID: "🛢️", Label: "Oil Drum"},
{ID: "📻", Label: "Radio"},
{ID: "🎷", Label: "Saxophone"},
{ID: "🛍️", Label: "Shopping Bags"},
{ID: "🛒", Label: "Shopping Cart"},
{ID: "☎️", Label: "Telephone"},
{ID: "📺", Label: "Television"},
{ID: "🎺", Label: "Trumpet"},
{ID: "📹", Label: "Video Camera"},
{ID: "🎻", Label: "Violin"},
{ID: "👓", Label: "Glasses"},
{ID: "🕶️", Label: "Sunglasses"},
{ID: "🥽", Label: "Goggles"},
{ID: "🥼", Label: "Lab Coat"},
{ID: "🦺", Label: "Safety Vest"},
{ID: "👔", Label: "Necktie"},
{ID: "👖", Label: "Jeans"},
{ID: "🧣", Label: "Scarf"},
{ID: "🧤", Label: "Gloves"},
{ID: "🧥", Label: "Coat"},
{ID: "🧦", Label: "Socks"},
{ID: "🥾", Label: "Hiking Boot"},
}},
{"holidays", "Holidays", []interaction.Choice{
{ID: "👾", Label: "Alien monster"},
{ID: "🦇", Label: "Bat"},
{ID: "🐈‍⬛", Label: "Black cat"},
{ID: "🐰", Label: "Bunny"},
{ID: "🎄", Label: "Christmas tree"},
{ID: "⚰️", Label: "Coffin"},
{ID: "🥚", Label: "Egg"},
{ID: "🎆", Label: "Fireworks"},
{ID: "👻", Label: "Ghost"},
{ID: "🎁", Label: "Gift"},
{ID: "🎃", Label: "Jack o'lantern"},
{ID: "🧙", Label: "Mage"},
{ID: "🎅", Label: "Santa"},
{ID: "☘️", Label: "Shamrock"},
{ID: "💀", Label: "Skull"},
{ID: "⛄", Label: "Snowman"},
{ID: "🕷", Label: "Spider"},
{ID: "🦃", Label: "Turkey"},
{ID: "🧛", Label: "Vampire"},
{ID: "🕸️", Label: "Web"},
{ID: "🧙‍♀️", Label: "Witch"},
{ID: "🧟", Label: "Zombie"},
{ID: "🧨", Label: "Firecracker"},
{ID: "🎊", Label: "Confetti ball"},
{ID: "🎈", Label: "Balloon"},
{ID: "🎀", Label: "Ribbon"},
{ID: "🪄", Label: "Magic wand"},
{ID: "🔮", Label: "Crystal ball"},
{ID: "🪅", Label: "Piñata"},
{ID: "🪦", Label: "Headstone"},
}},
{"symbols", "Symbols", []interaction.Choice{
{ID: "🦴", Label: "Bone"},
@@ -112,6 +491,18 @@ var categories = []struct {
{ID: "✨", Label: "Sparkles"},
{ID: "⭐", Label: "Star"},
{ID: "⚔️", Label: "Sword"},
{ID: "💔", Label: "Broken heart"},
{ID: "❤️‍🔥", Label: "Heart on fire"},
{ID: "❤️‍🩹", Label: "Mending heart"},
{ID: "💛", Label: "Yellow heart"},
{ID: "💚", Label: "Green heart"},
{ID: "💙", Label: "Blue heart"},
{ID: "💜", Label: "Purple heart"},
{ID: "🖤", Label: "Black heart"},
{ID: "🤎", Label: "Brown heart"},
{ID: "🤍", Label: "White heart"},
{ID: "🧡", Label: "Orange Heart"},
{ID: "🩷", Label: "Pink Heart"},
}},
{"flags", "Flags", []interaction.Choice{
{ID: "🇦🇷", Label: "Argentina"},
+64 -3
View File
@@ -5,10 +5,10 @@
package emoji
import (
"git.stormux.org/storm/fenrir/internal/i18n"
"strings"
"testing"
"git.stormux.org/storm/fenrir/internal/i18n"
"git.stormux.org/storm/fenrir/internal/interaction"
)
@@ -46,8 +46,10 @@ func TestCategorySelectionAndIndependentSearches(t *testing.T) {
t.Fatal(err)
}
other.Handle(interaction.Key{Name: "tab"})
if value, _, _ := Selection(other); value != "👾" {
t.Fatal("new session inherited previous search", value)
control, controlOK := other.Focused_control()
value, _, selectionOK := Selection(other)
if !controlOK || control.Text != "" || !selectionOK || value == "🇯🇵" {
t.Fatal("new session inherited previous search")
}
}
@@ -67,3 +69,62 @@ func TestBundledTranslationSearchPreservesEmoji(t *testing.T) {
t.Fatalf("localized search changed identity: %q %q %v", value, label, ok)
}
}
func TestExpandedCatalogCategoriesAndUniqueEmojiIDs(t *testing.T) {
expectedCategories := map[string]bool{
"activity": false,
"travel": false,
"objects": false,
}
emojiIDs := make(map[string]bool)
presentationIDs := make(map[string]string)
stripPresentation := strings.NewReplacer("\ufe0e", "", "\ufe0f", "")
for _, category := range categories {
if _, ok := expectedCategories[category.id]; ok {
expectedCategories[category.id] = true
}
if category.id == "" || category.label == "" || len(category.choices) == 0 {
t.Fatalf("invalid category %#v", category)
}
for _, choice := range category.choices {
if choice.ID == "" || choice.Label == "" {
t.Fatalf("invalid choice %#v", choice)
}
if emojiIDs[choice.ID] {
t.Fatalf("duplicate emoji ID %q", choice.ID)
}
emojiIDs[choice.ID] = true
// Text/emoji presentation selectors do not make a distinct emoji.
presentationID := stripPresentation.Replace(choice.ID)
if previous, ok := presentationIDs[presentationID]; ok {
t.Fatalf("presentation-equivalent emoji IDs %q and %q", previous, choice.ID)
}
presentationIDs[presentationID] = choice.ID
}
}
for id, found := range expectedCategories {
if !found {
t.Fatal("missing category", id)
}
}
if len(emojiIDs) != 500 {
t.Fatal("expanded catalog has the wrong size", len(emojiIDs))
}
if !emojiIDs["🐐"] {
t.Fatal("goat emoji missing")
}
}
func TestNewCategoryNavigation(t *testing.T) {
session, err := New_session()
if err != nil {
t.Fatal(err)
}
for range 4 {
session.Handle(interaction.Key{Name: "right"})
}
session.Handle(interaction.Key{Name: "tab"})
if value, label, ok := Selection(session); !ok || value != "⚽" || label != "Soccer ball" {
t.Fatalf("Activity navigation failed: %q %q %v", value, label, ok)
}
}
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff