mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-22 19:31:44 +00:00
fix static check failure in pkg/controller/disruption and pkg/controller/namespace/deletion
This commit is contained in:
parent
3d8317ae91
commit
53aff819e0
@ -2,9 +2,7 @@ cluster/images/etcd-version-monitor
|
||||
cluster/images/etcd/migrate
|
||||
pkg/controller/daemon
|
||||
pkg/controller/deployment
|
||||
pkg/controller/disruption
|
||||
pkg/controller/garbagecollector
|
||||
pkg/controller/namespace/deletion
|
||||
pkg/controller/nodeipam
|
||||
pkg/controller/podautoscaler
|
||||
pkg/controller/podgc
|
||||
|
@ -639,12 +639,9 @@ func TestReplicationController(t *testing.T) {
|
||||
// about the RC. This is a known bug. TODO(mml): file issue
|
||||
ps.VerifyPdbStatus(t, pdbName, 0, 0, 0, 0, map[string]metav1.Time{})
|
||||
|
||||
pods := []*v1.Pod{}
|
||||
|
||||
for i := int32(0); i < 3; i++ {
|
||||
pod, _ := newPod(t, fmt.Sprintf("foobar %d", i))
|
||||
updatePodOwnerToRc(t, pod, rc)
|
||||
pods = append(pods, pod)
|
||||
pod.Labels = labels
|
||||
add(t, dc.podStore, pod)
|
||||
dc.sync(pdbName)
|
||||
@ -680,12 +677,9 @@ func TestStatefulSetController(t *testing.T) {
|
||||
// about the SS. This is a known bug. TODO(mml): file issue
|
||||
ps.VerifyPdbStatus(t, pdbName, 0, 0, 0, 0, map[string]metav1.Time{})
|
||||
|
||||
pods := []*v1.Pod{}
|
||||
|
||||
for i := int32(0); i < 3; i++ {
|
||||
pod, _ := newPod(t, fmt.Sprintf("foobar %d", i))
|
||||
updatePodOwnerToSs(t, pod, ss)
|
||||
pods = append(pods, pod)
|
||||
pod.Labels = labels
|
||||
add(t, dc.podStore, pod)
|
||||
dc.sync(pdbName)
|
||||
|
@ -162,7 +162,7 @@ func (d *namespacedResourcesDeleter) initOpCache() {
|
||||
if len(resources) == 0 {
|
||||
klog.Fatalf("Unable to get any supported resources from server: %v", err)
|
||||
}
|
||||
deletableGroupVersionResources := []schema.GroupVersionResource{}
|
||||
|
||||
for _, rl := range resources {
|
||||
gv, err := schema.ParseGroupVersion(rl.GroupVersion)
|
||||
if err != nil {
|
||||
@ -183,7 +183,6 @@ func (d *namespacedResourcesDeleter) initOpCache() {
|
||||
d.opCache.setNotSupported(operationKey{operation: op, gvr: gvr})
|
||||
}
|
||||
}
|
||||
deletableGroupVersionResources = append(deletableGroupVersionResources, gvr)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user