mirror of
https://github.com/sipeed/picoclaw.git
synced 2026-06-12 18:08:54 +00:00
451db2f5d8
* feat(channels): unify tool feedback animation across discord telegram and feishu * fix(tool-feedback): unify fallback and single-message delivery * fix(channels): finalize tool feedback in place * fix ci * feat: improve tool feedback * fix review blockers in pico token cache and tool feedback fix(provider): preserve function thought signatures fix(feishu): recover tool feedback after edit fallback * * delete dead code * fix(pico): clean up tool feedback progress state * fix ci * fix(web): preserve tool feedback line breaks in chat * fix(channels): preserve tool feedback progress state fix(pico): preserve context usage when finalizing tool feedback chore: record branch review pass fix: preserve tool feedback finalization state fix(web): handle pico history update fallback * fix ci
25 lines
644 B
Go
25 lines
644 B
Go
package providers
|
|
|
|
import "testing"
|
|
|
|
func TestNormalizeToolCall_PreservesExtraContentGoogleThoughtSignature(t *testing.T) {
|
|
tc := NormalizeToolCall(ToolCall{
|
|
ID: "call_1",
|
|
Name: "search",
|
|
Arguments: map[string]any{"q": "pico"},
|
|
ExtraContent: &ExtraContent{
|
|
Google: &GoogleExtra{ThoughtSignature: "sig-1"},
|
|
},
|
|
})
|
|
|
|
if tc.ThoughtSignature != "sig-1" {
|
|
t.Fatalf("ThoughtSignature = %q, want sig-1", tc.ThoughtSignature)
|
|
}
|
|
if tc.Function == nil {
|
|
t.Fatal("Function is nil")
|
|
}
|
|
if tc.Function.ThoughtSignature != "sig-1" {
|
|
t.Fatalf("Function.ThoughtSignature = %q, want sig-1", tc.Function.ThoughtSignature)
|
|
}
|
|
}
|