1
0
mirror of https://github.com/astaxie/beego.git synced 2025-07-07 07:10:19 +00:00

renamed functions for clarity

This commit is contained in:
Eyitayo Ogunbiyi
2020-07-07 14:54:21 +01:00
parent 8d1a9bc92e
commit 5a4a082af0
2 changed files with 13 additions and 13 deletions

View File

@ -97,7 +97,7 @@ func oldMap() M {
return m
}
func TestExecJSON(t *testing.T) {
func TestWriteJSON(t *testing.T) {
t.Log("Testing the adding of JSON to the response")
w := httptest.NewRecorder()
@ -105,7 +105,7 @@ func TestExecJSON(t *testing.T) {
res, _ := json.Marshal(originalBody)
execJSON(w, res)
writeJSON(w, res)
decodedBody := []int{}
err := json.NewDecoder(w.Body).Decode(&decodedBody)