1
0
mirror of https://github.com/fumiama/NanoBot.git synced 2026-06-06 03:00:24 +08:00
Files
NanoBot/helper_test.go
2023-10-13 00:45:21 +09:00

23 lines
630 B
Go

package nano
import "testing"
func TestUnderlineToCamel(t *testing.T) {
x := UnderlineToCamel("GUILD_CREATE")
if x != "GuildCreate" {
t.Fatal("expected GuildCreate but got", x)
}
x = UnderlineToCamel("GUILD_MEMBER_UPDATE")
if x != "GuildMemberUpdate" {
t.Fatal("expected GuildMemberUpdate but got", x)
}
x = UnderlineToCamel("OPEN_FORUM_THREAD_CREATE")
if x != "OpenForumThreadCreate" {
t.Fatal("expected OpenForumThreadCreate but got", x)
}
x = UnderlineToCamel("AUDIO_OR_LIVE_CHANNEL_MEMBER_ENTER")
if x != "AudioOrLiveChannelMemberEnter" {
t.Fatal("expected AudioOrLiveChannelMemberEnter but got", x)
}
}