Added tests

master
Aadhavan Srinivasan 2 months ago
parent b327143fa2
commit b1e2d7147e

@ -23,7 +23,7 @@ var reTests = []struct {
{"((abc)|(def))*", "abcdef", []matchIndex{{0, 6}}}, {"((abc)|(def))*", "abcdef", []matchIndex{{0, 6}}},
{"(abc)*|(def)*", "abcdef", []matchIndex{{0, 3}, {3, 3}, {3, 6}, {6, 6}}}, {"(abc)*|(def)*", "abcdef", []matchIndex{{0, 3}, {3, 3}, {3, 6}, {6, 6}}},
{"b*a*a", "bba", []matchIndex{{0, 3}}}, {"b*a*a", "bba", []matchIndex{{0, 3}}},
{"(ab)+", "ababddd", []matchIndex{{0, 2}, {2, 4}}}, {"(ab)+", "abcabddd", []matchIndex{{0, 2}, {3, 5}}},
} }
func TestFindAllMatches(t *testing.T) { func TestFindAllMatches(t *testing.T) {

Loading…
Cancel
Save