(e *echo.Echo, path, body string)
| 33 | } |
| 34 | |
| 35 | func postJSON(e *echo.Echo, path, body string) *httptest.ResponseRecorder { |
| 36 | req := httptest.NewRequest(http.MethodPost, path, strings.NewReader(body)) |
| 37 | req.Header.Set("Content-Type", "application/json") |
| 38 | rec := httptest.NewRecorder() |
| 39 | e.ServeHTTP(rec, req) |
| 40 | return rec |
| 41 | } |
| 42 | |
| 43 | var _ = Describe("SetModelAndConfig middleware", func() { |
| 44 | var ( |