blob: be18242d57f56cc5ca4efdd0e584e96556ffce09 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
package testutil
// MultilineDocBlock returns a realistic multi-line documentation block.
func MultilineDocBlock() string {
return "// add adds two numbers\n// returns their sum"
}
// MultilineChatReply returns a multi-line assistant reply for chat tests.
func MultilineChatReply() string {
return "Hello, world!\nThis is a multi-line reply."
}
// MultilineFunctionSuggestion returns a more realistic multi-line function body suggestion.
func MultilineFunctionSuggestion() string {
return "(ctx context.Context, input string) (*CustData, error) {\n // TODO: implement\n return &CustData{}, nil\n}"
}
// MarkdownCodeFence returns a fenced markdown snippet used in post-processing tests.
func MarkdownCodeFence() string {
return "```go\nname := value\n```"
}
// MalformedJSON returns a deliberately malformed JSON string.
func MalformedJSON() string {
return "{\"choices\":[{\"delta\":{\"content\":\"oops\"}}]"
}
|