pkg/http/server_test.go: Add gleak to find goroutine leaks

Signed-off-by: Josef Johansson <josef86@gmail.com>
This commit is contained in:
Josef Johansson
2024-03-26 12:30:41 +01:00
committed by Josef Johansson
parent 3b11a51a70
commit bb6aba4a00
+3
View File
@@ -12,6 +12,7 @@ import (
. "github.com/onsi/ginkgo"
. "github.com/onsi/ginkgo/extensions/table"
. "github.com/onsi/gomega"
. "github.com/onsi/gomega/gleak"
)
const hello = "Hello World!"
@@ -559,6 +560,8 @@ var _ = Describe("Server", func() {
AfterEach(func() {
cancel()
Eventually(Goroutines).ShouldNot(HaveLeaked())
})
Context("with an ipv4 http server", func() {