diff --git a/staging/src/k8s.io/client-go/dynamic/fake/simple.go b/staging/src/k8s.io/client-go/dynamic/fake/simple.go index ee44c129f95..5d0a6f69f2a 100644 --- a/staging/src/k8s.io/client-go/dynamic/fake/simple.go +++ b/staging/src/k8s.io/client-go/dynamic/fake/simple.go @@ -388,7 +388,6 @@ func (c *dynamicResourceClient) List(ctx context.Context, opts metav1.ListOption list := &unstructured.UnstructuredList{} list.SetRemainingItemCount(entireList.GetRemainingItemCount()) - list.SetSelfLink(entireList.GetSelfLink()) list.SetResourceVersion(entireList.GetResourceVersion()) list.SetContinue(entireList.GetContinue()) list.GetObjectKind().SetGroupVersionKind(listGVK) diff --git a/staging/src/k8s.io/client-go/dynamic/fake/simple_test.go b/staging/src/k8s.io/client-go/dynamic/fake/simple_test.go index 567951a580d..e74b6ff0414 100644 --- a/staging/src/k8s.io/client-go/dynamic/fake/simple_test.go +++ b/staging/src/k8s.io/client-go/dynamic/fake/simple_test.go @@ -180,7 +180,6 @@ func Test_ListKind(t *testing.T) { "metadata": map[string]interface{}{ "continue": "", "resourceVersion": "", - "selfLink": "", }, }, Items: []unstructured.Unstructured{ @@ -336,7 +335,6 @@ func TestListWithUnstructuredObjectsAndTypedScheme(t *testing.T) { expectedList.SetGroupVersionKind(listGVK) expectedList.SetResourceVersion("") // by product of the fake setting resource version expectedList.SetContinue("") - expectedList.SetSelfLink("") expectedList.Items = append(expectedList.Items, u) if diff := cmp.Diff(expectedList, list); diff != "" { @@ -366,7 +364,6 @@ func TestListWithNoFixturesAndTypedScheme(t *testing.T) { expectedList.SetGroupVersionKind(listGVK) expectedList.SetResourceVersion("") // by product of the fake setting resource version expectedList.SetContinue("") - expectedList.SetSelfLink("") if diff := cmp.Diff(expectedList, list); diff != "" { t.Fatal("unexpected diff (-want, +got): ", diff) @@ -400,7 +397,6 @@ func TestListWithNoScheme(t *testing.T) { expectedList.SetGroupVersionKind(listGVK) expectedList.SetResourceVersion("") // by product of the fake setting resource version expectedList.SetContinue("") - expectedList.SetSelfLink("") expectedList.Items = append(expectedList.Items, u) if diff := cmp.Diff(expectedList, list); diff != "" { @@ -444,7 +440,6 @@ func TestListWithTypedFixtures(t *testing.T) { expectedList.SetGroupVersionKind(listGVK) expectedList.SetResourceVersion("") // by product of the fake setting resource version expectedList.SetContinue("") - expectedList.SetSelfLink("") expectedList.Items = []unstructured.Unstructured{u} if diff := cmp.Diff(expectedList, list); diff != "" {