Publish Claude Code Binaries / Stage and publish binaries (push) Canceled after 0s
Publish Tutti App Runtime / Build darwin-arm64 (push) Canceled after 0s
Publish Tutti App Runtime / Build darwin-amd64 (push) Canceled after 0s
Publish Tutti App Runtime / Build linux-amd64 (push) Canceled after 0s
Publish Tutti App Runtime / Build windows-amd64 (push) Canceled after 0s
Sync Tutti Agent Skills / sync (push) Canceled after 0s
Windows Agent Adapters / Test Windows agent adapters (push) Canceled after 0s
Windows Daemon Adapters / Test Windows daemon adapters (push) Canceled after 0s
Publish Tutti App Runtime / Publish runtime catalog (push) Canceled after 0s
35 lines
1.0 KiB
Go
35 lines
1.0 KiB
Go
package api
|
|
|
|
import (
|
|
"testing"
|
|
|
|
"github.com/tutti-os/tutti/packages/agent/store-sqlite/canonical"
|
|
)
|
|
|
|
func TestGeneratedAgentCapabilitiesProjectsActiveTurnGuidance(t *testing.T) {
|
|
t.Parallel()
|
|
|
|
capabilities := generatedAgentCapabilities([]string{"activeTurnGuidance"})
|
|
if !capabilities.ActiveTurnGuidance {
|
|
t.Fatal("activeTurnGuidance = false, want true")
|
|
}
|
|
if capabilities.Interrupt {
|
|
t.Fatal("interrupt = true, want capability fields projected independently")
|
|
}
|
|
}
|
|
|
|
func TestGeneratedAgentSessionCapabilitiesPreservesUnknownSnapshot(t *testing.T) {
|
|
t.Parallel()
|
|
|
|
if capabilities := generatedAgentSessionCapabilities(nil); capabilities != nil {
|
|
t.Fatalf("unknown capabilities = %#v, want nil", capabilities)
|
|
}
|
|
reportedEmpty := generatedAgentSessionCapabilities(canonical.NewCapabilitySnapshot(nil))
|
|
if reportedEmpty == nil {
|
|
t.Fatal("reported empty capabilities = nil")
|
|
}
|
|
if reportedEmpty.GoalPause || reportedEmpty.Interrupt {
|
|
t.Fatalf("reported empty capabilities = %#v, want closed false record", reportedEmpty)
|
|
}
|
|
}
|