We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f3e7368 commit d3b0783Copy full SHA for d3b0783
1 file changed
tests/utils/utils.go
@@ -54,6 +54,7 @@ func Append(slice []string, data string) []string {
54
55
func GetRandomPort() string {
56
l, _ := net.Listen("tcp", "127.0.0.1:0") // listen on localhost
57
+ defer l.Close()
58
port := l.Addr()
59
return strings.Split(port.String(), ":")[1]
60
}
0 commit comments