diff --git a/tests/main_test.go b/tests/main_test.go index 6a30856..0a951e9 100644 --- a/tests/main_test.go +++ b/tests/main_test.go @@ -49,7 +49,12 @@ func TestProcess(t *testing.T) { if err != nil { require.NoError(t, err) } - defer resp.Body.Close() + defer func(Body io.ReadCloser) { + err := Body.Close() + if err != nil { + panic(err) + } + }(resp.Body) require.Equal(t, http.StatusOK, resp.StatusCode) body, err := io.ReadAll(resp.Body)