From 945ba4166ad960d5c5a9a40250ae5f5252718ea5 Mon Sep 17 00:00:00 2001 From: Proddy Date: Tue, 5 Dec 2023 01:25:08 +0000 Subject: [PATCH] Improve EmoteExtractor test Improves the EmoteExtractor test to confirm the Index is as expected also --- TwitchLib.Client.Test/Parsing.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/TwitchLib.Client.Test/Parsing.cs b/TwitchLib.Client.Test/Parsing.cs index 4988a2e..e315322 100644 --- a/TwitchLib.Client.Test/Parsing.cs +++ b/TwitchLib.Client.Test/Parsing.cs @@ -25,9 +25,11 @@ public void Badges() [Fact] public void EmoteExtractorExtract() { - var emotes = EmoteExtractor.Extract("25:10-14", "One 😂 Two Kappa Three"); + var message = "One 😂 Two Kappa Three"; + var emotes = EmoteExtractor.Extract("25:10-14", message); Assert.True(emotes.Count == 1); Assert.True(emotes[0].Name == "Kappa"); + Assert.True(emotes[0].StartIndex == message.IndexOf("Kappa")); }