Files
multica/server/internal/service/trivial_done_test.go
fr00st cc9fbd3db0 Fix stale Done replies on comment follow-ups (#2495)
* fix: avoid stale done replies on comment follow-ups

* fix: avoid inlining runtime brief for Hermes ACP

* fix: address comment follow-up review feedback
2026-05-14 12:00:04 +08:00

33 lines
794 B
Go

package service
import "testing"
func TestIsTrivialDoneOutput(t *testing.T) {
t.Parallel()
tests := []struct {
name string
in string
want bool
}{
{"plain english", "done", true},
{"english punctuation", " Done. ", true},
{"russian", "Готово!", true},
{"russian feminine", "готова…", true},
{"russian done", "Сделано", true},
{"chinese", "完成!", true},
{"japanese", "完了。", true},
{"not only marker", "done, see PR", false},
{"not acknowledgement", "好的", false},
{"real answer", "I fixed the issue", false},
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
if got := isTrivialDoneOutput(tt.in); got != tt.want {
t.Fatalf("isTrivialDoneOutput(%q) = %v, want %v", tt.in, got, tt.want)
}
})
}
}