diff --git a/internal/server/web_server_e2e_test.go b/internal/server/web_server_e2e_test.go index 1c59d16f..fa484438 100644 --- a/internal/server/web_server_e2e_test.go +++ b/internal/server/web_server_e2e_test.go @@ -334,6 +334,7 @@ func executeRequest( result := recorder.Result() resultBody, _ := io.ReadAll(result.Body) + defer result.Body.Close() responseBody, err := jsonrpc.DecodeResponseBody(resultBody) diff --git a/internal/server/web_server_test.go b/internal/server/web_server_test.go index 53666d1b..6fa215a3 100644 --- a/internal/server/web_server_test.go +++ b/internal/server/web_server_test.go @@ -41,6 +41,7 @@ func TestHandleJSONRPCRequest_Success(t *testing.T) { result := recorder.Result() resultBody, _ := io.ReadAll(result.Body) + defer result.Body.Close() jsonRPCResponse, _ := jsonrpc.DecodeResponseBody(resultBody)