(t *testing.T)
| 325 | } |
| 326 | |
| 327 | func TestStdlibCompat_FindIndex(t *testing.T) { |
| 328 | for _, test := range findTests { |
| 329 | t.Run(test.String(), func(t *testing.T) { |
| 330 | stdRe := regexp.MustCompile(test.pat) |
| 331 | cgRe := MustCompile(test.pat) |
| 332 | |
| 333 | stdResult := stdRe.FindStringIndex(test.text) |
| 334 | cgResult := cgRe.FindStringIndex(test.text) |
| 335 | |
| 336 | if !reflect.DeepEqual(stdResult, cgResult) { |
| 337 | t.Errorf("FindStringIndex(%q, %q):\n stdlib: %v\n coregex: %v", |
| 338 | test.pat, test.text, stdResult, cgResult) |
| 339 | } |
| 340 | }) |
| 341 | } |
| 342 | } |
| 343 | |
| 344 | func TestStdlibCompat_FindStringIndex(t *testing.T) { |
| 345 | for _, test := range findTests { |
nothing calls this directly
no test coverage detected