Fix test again

This commit is contained in:
2025-03-27 19:49:57 +01:00
parent dc8da8ab63
commit d9f54a8354
2 changed files with 50 additions and 50 deletions

View File

@@ -101,21 +101,21 @@ func TestIndexExplosions_ShouldNotPanic(t *testing.T) {
}
p := &processor.RegexProcessor{}
actual, mods, matches, err := p.ProcessContent(string(given), `LightComponent!anyrange="(!num)"`, "*4")
result, mods, matches, err := p.ProcessContent(string(given), `(?-s)LightComponent!anyrange="(!num)"`, "*4")
if err != nil {
t.Fatalf("Error processing content: %v", err)
}
if matches != 1 {
t.Errorf("Expected 1 match, got %d", matches)
if matches != 45 {
t.Errorf("Expected 45 match, got %d", matches)
}
if mods != 1 {
t.Errorf("Expected 1 modification, got %d", mods)
if mods != 45 {
t.Errorf("Expected 45 modification, got %d", mods)
}
if string(actual) != string(expected) {
t.Errorf("expected %s, got %s", expected, actual)
if string(result) != string(expected) {
t.Errorf("expected %s, got %s", expected, result)
}
}