diff --git a/agent/ui_endpoint_test.go b/agent/ui_endpoint_test.go index 98ce0038a5..0bffefc5d1 100644 --- a/agent/ui_endpoint_test.go +++ b/agent/ui_endpoint_test.go @@ -51,6 +51,7 @@ func TestUiIndex(t *testing.T) { if err != nil { t.Fatalf("err: %v", err) } + defer resp.Body.Close() // Verify the response if resp.StatusCode != 200 {