We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 936bf0e commit 7c4ba79Copy full SHA for 7c4ba79
templates/go/api_test.mustache
@@ -41,7 +41,12 @@ func Test_{{packageName}}_{{classname}}Service(t *testing.T) {
41
{{/returnFormat}}
42
{{^returnFormat}}
43
{{#returnType}}
44
+ {{#returnTypeIsPrimitive}}
45
+ var data {{{.}}}
46
+ {{/returnTypeIsPrimitive}}
47
+ {{^returnTypeIsPrimitive}}
48
data := {{{.}}}{}
49
50
w.Header().Add("Content-Type", "application/json")
51
json.NewEncoder(w).Encode(data)
52
{{/returnType}}
0 commit comments