add initial benchmarks
Enes Çakır enes@cakir.web.tr
Wed, 19 Feb 2020 00:14:55 +0300
1 files changed,
24 insertions(+),
0 deletions(-)
jump to
M
emoji_test.go
→
emoji_test.go
@@ -105,3 +105,27 @@ t.Fatalf("test case %v fail: %v", i+1, err)
} } } + +func BenchmarkEmoji(b *testing.B) { + for n := 0; n < b.N; n++ { + _ = WavingHand.String() + } +} + +func BenchmarkEmojiWithTone(b *testing.B) { + for n := 0; n < b.N; n++ { + _ = WavingHand.Tone(Medium).String() + } +} + +func BenchmarkEmojiWithToneTwo(b *testing.B) { + for n := 0; n < b.N; n++ { + _ = WomanAndManHoldingHandsWithTwoTone.Tone(Medium, Dark).String() + } +} + +func BenchmarkCountryFlag(b *testing.B) { + for n := 0; n < b.N; n++ { + _, _ = CountryFlag("tr") + } +}