Skip to content

Commit

Permalink
kubeconfigs: fix capture loop variable in closure
Browse files Browse the repository at this point in the history
  • Loading branch information
andfasano committed Oct 29, 2021
1 parent 309bbb4 commit 6ff33d2
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion test/extended/apiserver/kubeconfigs.go
Expand Up @@ -21,12 +21,13 @@ var _ = g.Describe("[Conformance][sig-api-machinery][Feature:APIServer] local ku
defer g.GinkgoRecover()
oc := exutil.NewCLI("apiserver")

for _, kubeconfig := range []string{
for _, kc := range []string{
"localhost.kubeconfig",
"lb-ext.kubeconfig",
"lb-int.kubeconfig",
"localhost-recovery.kubeconfig",
} {
kubeconfig := kc
g.It(fmt.Sprintf("%q should be present on all masters and work", kubeconfig), func() {
masterNodes, err := oc.AdminKubeClient().CoreV1().Nodes().List(context.Background(), metav1.ListOptions{
LabelSelector: `node-role.kubernetes.io/master`,
Expand Down

0 comments on commit 6ff33d2

Please sign in to comment.