Humanize web research replies
CI / test (push) Failing after 1m9s
CI / test (pull_request) Failing after 1m5s

This commit is contained in:
m
2026-08-25 13:32:50 +03:00
parent c0208de111
commit 0595f857af
2 changed files with 29 additions and 2 deletions
+7
View File
@@ -15,6 +15,13 @@ import (
interactiondomain "git.cin.su/m/Assistant/modules/interaction/domain"
)
func TestHumanResearchExcerptRemovesSearchResultHeading(t *testing.T) {
got := humanResearchExcerpt("погода в Санкт-Петербурге", "Погода в Санкт-Петербурге — Прогноз погоды — Сейчас пасмурно, температура +14°")
if got != "Сейчас пасмурно, температура +14°" || strings.Contains(got, "Прогноз погоды") {
t.Fatalf("human research excerpt = %q", got)
}
}
func TestBearerTokenRequiresBearerScheme(t *testing.T) {
request := httptest.NewRequest("GET", "/", nil)
request.Header.Set("Authorization", "Basic value")