fixed bug in textstyleparser

* bold text wasn't correctly parsed

see #382
This commit is contained in:
Bernhard B
2023-09-08 19:54:05 +02:00
parent c6d065980f
commit a5cbb4c725
2 changed files with 9 additions and 1 deletions

View File

@@ -32,3 +32,9 @@ func TestBoldAndItalicMessage(t *testing.T) {
expectMessageEqual(t, message, "This is a bold and italic message")
expectFormatStringsEqual(t, signalCliFormatStrings, []string{"10:4:BOLD", "19:6:ITALIC"})
}
func TestTwoBoldFormattedStrings(t *testing.T) {
message, signalCliFormatStrings := ParseMarkdownMessage("This is a **bold** and another **bold** message")
expectMessageEqual(t, message, "This is a bold and another bold message")
expectFormatStringsEqual(t, signalCliFormatStrings, []string{"10:4:BOLD", "27:4:BOLD"})
}