P0 fixes: - ModelError.Is(): use exact matching instead of substring contains() - shouldClearStickySession: add context param for cancellation/tracing P1 fixes: - TODO stubs: return 501 Not Implemented errors - validateInstanceSignature: deduplicate to shared validateCodeSignature() - Error messages: standardize to English only - http.go: remove pseudo if-else with duplicate branches
15 lines
326 B
Go
15 lines
326 B
Go
package service
|
|
|
|
import (
|
|
"strings"
|
|
"testing"
|
|
|
|
"github.com/stretchr/testify/require"
|
|
)
|
|
|
|
func TestSanitizeOpenCodeText_RewritesCanonicalSentence(t *testing.T) {
|
|
in := "You are OpenCode, the best coding agent on the planet."
|
|
got := sanitizeSystemText(in)
|
|
require.Equal(t, strings.TrimSpace(claudeCodeSystemPrompt), got)
|
|
}
|