Added unicode tests

master
Aadhavan Srinivasan 1 month ago
parent c56d81a335
commit 1e0502c6aa

@ -109,6 +109,10 @@ var reTests = []struct {
{`\d{3,4}`, "ababab555", []MatchIndex{{6, 9}}}, {`\d{3,4}`, "ababab555", []MatchIndex{{6, 9}}},
{`\bpaint\b`, "paints", []MatchIndex{}}, {`\bpaint\b`, "paints", []MatchIndex{}},
{`\b\w{5}\b`, "paint", []MatchIndex{{0, 5}}}, {`\b\w{5}\b`, "paint", []MatchIndex{{0, 5}}},
// Unicode tests
{`.+`, "úïäö´«åæïëòöê»éãçâï«úïòíñ", []MatchIndex{{0, 25}}},
{`a.b`, "a²b", []MatchIndex{{0, 3}}},
} }
func TestFindAllMatches(t *testing.T) { func TestFindAllMatches(t *testing.T) {

Loading…
Cancel
Save