mirror of
https://github.com/mattermost/mattermost.git
synced 2025-02-25 18:55:24 -06:00
* Add POST /emoji/search and GET /emoji/autocomplete API endpoints * Add constant to be clearer
20 lines
420 B
Go
20 lines
420 B
Go
// Copyright (c) 2018-present Mattermost, Inc. All Rights Reserved.
|
|
// See License.txt for license information.
|
|
|
|
package model
|
|
|
|
import (
|
|
"strings"
|
|
"testing"
|
|
)
|
|
|
|
func TestEmojiSearchJson(t *testing.T) {
|
|
emojiSearch := EmojiSearch{Term: NewId()}
|
|
json := emojiSearch.ToJson()
|
|
remojiSearch := EmojiSearchFromJson(strings.NewReader(json))
|
|
|
|
if emojiSearch.Term != remojiSearch.Term {
|
|
t.Fatal("Terms do not match")
|
|
}
|
|
}
|