Sitelet https://github.com/kubernetes/kops/pull/18455/files
Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 6 additions & 11 deletions nodeup/pkg/model/kube_proxy_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,8 @@ import (
"k8s.io/kops/pkg/apis/kops"
kopsmodel "k8s.io/kops/pkg/apis/kops/model"
"k8s.io/kops/pkg/apis/nodeup"
"k8s.io/kops/pkg/flagbuilder"
"k8s.io/kops/upup/pkg/fi"
"k8s.io/kops/util/pkg/architectures"
"k8s.io/kops/util/pkg/exec"

v1 "k8s.io/api/core/v1"
"k8s.io/apimachinery/pkg/api/resource"
Expand All @@ -48,14 +46,6 @@ func TestKubeProxyBuilder_buildPod(t *testing.T) {
KubeProxy: &kubeProxy,
}

flags, _ := flagbuilder.BuildFlagsList(&kubeProxy)

flags = append(flags, []string{
"--kubeconfig=/var/lib/kube-proxy/kubeconfig",
"--oom-score-adj=-998",
`--resource-container=""`,
}...)

type fields struct {
NodeupModelContext *NodeupModelContext
}
Expand Down Expand Up @@ -96,7 +86,7 @@ func TestKubeProxyBuilder_buildPod(t *testing.T) {
v1.ResourceCPU: *resource.NewScaledQuantity(30, resource.Milli),
},
},
Command: exec.WithTee("/usr/local/bin/kube-proxy", sortedStrings(flags), "/var/log/kube-proxy.log"),
Command: []string{"/go-runner"},
},
},
},
Expand Down Expand Up @@ -147,6 +137,11 @@ func TestKubeProxyBuilder_buildPod(t *testing.T) {
if !reflect.DeepEqual(got.Spec.Containers[0].Resources, tt.want.Spec.Containers[0].Resources) {
t.Errorf("KubeProxyBuilder.buildPod() Resources = %v, want %v", got.Spec.Containers[0].Resources, tt.want.Spec.Containers[0].Resources)
}

// compare pod spec container command
if !reflect.DeepEqual(got.Spec.Containers[0].Command, tt.want.Spec.Containers[0].Command) {
t.Errorf("KubeProxyBuilder.buildPod() Command = %v, want %v", got.Spec.Containers[0].Command, tt.want.Spec.Containers[0].Command)
}
})
}
}
Expand Down
35 changes: 0 additions & 35 deletions util/pkg/exec/exec.go

This file was deleted.

49 changes: 0 additions & 49 deletions util/pkg/exec/exec_test.go

This file was deleted.

Loading