Squashed 'backend/goldmark/' content from commit 379bf24
git-subtree-dir: backend/goldmark git-subtree-split: 379bf24a47e6ef07f34d7536aead86d8792ac300
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
package text
|
||||
|
||||
import (
|
||||
"regexp"
|
||||
"testing"
|
||||
)
|
||||
|
||||
func TestFindSubMatchReader(t *testing.T) {
|
||||
s := "微笑"
|
||||
r := NewReader([]byte(":" + s + ":"))
|
||||
reg := regexp.MustCompile(`:(\p{L}+):`)
|
||||
match := r.FindSubMatch(reg)
|
||||
if len(match) != 2 || string(match[1]) != s {
|
||||
t.Fatal("no match cjk")
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user