We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6125e6b commit 1f235c8Copy full SHA for 1f235c8
staging/src/k8s.io/apiserver/pkg/server/filters/goaway_test.go
@@ -342,6 +342,7 @@ func TestClientReceivedGOAWAY(t *testing.T) {
342
343
for _, tc := range cases {
344
t.Run(tc.name, func(t *testing.T) {
345
+ var mu sync.Mutex
346
// localAddr indicates how many TCP connection set up
347
localAddr := make([]string, 0)
348
@@ -350,7 +351,10 @@ func TestClientReceivedGOAWAY(t *testing.T) {
350
351
if err != nil {
352
t.Fatalf("unexpect connection err: %v", err)
353
}
354
+
355
+ mu.Lock()
356
localAddr = append(localAddr, conn.LocalAddr().String())
357
+ mu.Unlock()
358
return
359
})
360
0 commit comments