MCPcopy Create free account
hub / github.com/aurora-develop/aurora / TestFixLoneBackslashesRegex

Function TestFixLoneBackslashesRegex

internal/toolcall/parser_test.go:182–189  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

180}
181
182func TestFixLoneBackslashesRegex(t *testing.T) {
183 // \d 不是合法 JSON 转义 → 修正
184 in := `{"pattern":"\d+"}`
185 out := fixLoneBackslashes(in)
186 if !strings.Contains(out, `\\d+`) {
187 t.Fatalf("output = %q", out)
188 }
189}
190
191func TestRobustJSONRepairsWindowsPath(t *testing.T) {
192 // Go json 接受 \f 解析为 form-feed 字符(0x0C),所以最终 path 会损失 "f" 字母

Callers

nothing calls this directly

Calls 1

fixLoneBackslashesFunction · 0.85

Tested by

no test coverage detected