Skip to content
This repository was archived by the owner on Mar 26, 2021. It is now read-only.

Commit 967d110

Browse files
committed
Fix gofmt and go vet errors
1 parent 1125931 commit 967d110

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

pkg/crinit/aggregated/aggregated.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -377,7 +377,7 @@ func createClusterRoleBindingObject(clientset client.Interface, name, subjectKin
377377
Labels: labels,
378378
},
379379
Subjects: []rbacv1.Subject{
380-
rbacv1.Subject{
380+
{
381381
Kind: subjectKind,
382382
Name: subjectName,
383383
Namespace: subjectNamespace,
@@ -407,7 +407,7 @@ func createExtensionAPIServerAuthenticationRoleBinding(clientset client.Interfac
407407
Labels: util.ComponentLabel,
408408
},
409409
Subjects: []rbacv1.Subject{
410-
rbacv1.Subject{
410+
{
411411
Kind: rbacv1.ServiceAccountKind,
412412
Name: serviceAccountName,
413413
Namespace: namespace,

pkg/crinit/standalone/standalone_test.go

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -298,7 +298,7 @@ func TestCreateService(t *testing.T) {
298298
},
299299
Status: v1.NodeStatus{
300300
Addresses: []v1.NodeAddress{
301-
v1.NodeAddress{
301+
{
302302
Type: v1.NodeExternalIP,
303303
Address: "200.0.0.1",
304304
},
@@ -353,7 +353,7 @@ func TestCreateService(t *testing.T) {
353353
createAction := action.(clientgotesting.CreateAction)
354354
svc := createAction.GetObject().(*v1.Service)
355355
if svc.Spec.Type == v1.ServiceTypeLoadBalancer {
356-
svc.Status.LoadBalancer.Ingress = []v1.LoadBalancerIngress{v1.LoadBalancerIngress{IP: loadBalancerAddress, Hostname: loadBalancerHostname}}
356+
svc.Status.LoadBalancer.Ingress = []v1.LoadBalancerIngress{{IP: loadBalancerAddress, Hostname: loadBalancerHostname}}
357357
return false, svc, nil
358358
}
359359
return false, nil, nil
@@ -434,7 +434,7 @@ func TestGetClusterNodeIPs(t *testing.T) {
434434
},
435435
Status: v1.NodeStatus{
436436
Addresses: []v1.NodeAddress{
437-
v1.NodeAddress{
437+
{
438438
Type: v1.NodeExternalIP,
439439
Address: "200.0.0.1",
440440
},
@@ -448,7 +448,7 @@ func TestGetClusterNodeIPs(t *testing.T) {
448448
},
449449
Status: v1.NodeStatus{
450450
Addresses: []v1.NodeAddress{
451-
v1.NodeAddress{
451+
{
452452
Type: v1.NodeInternalIP,
453453
Address: "10.0.0.1",
454454
},
@@ -462,11 +462,11 @@ func TestGetClusterNodeIPs(t *testing.T) {
462462
},
463463
Status: v1.NodeStatus{
464464
Addresses: []v1.NodeAddress{
465-
v1.NodeAddress{
465+
{
466466
Type: v1.NodeExternalIP,
467467
Address: "200.0.0.2",
468468
},
469-
v1.NodeAddress{
469+
{
470470
Type: v1.NodeInternalIP,
471471
Address: "10.0.0.2",
472472
},

0 commit comments

Comments
 (0)