diff --git a/pkg/api/testing/serialization_test.go b/pkg/api/testing/serialization_test.go index b3865203a21..ba6d1c1ea9f 100644 --- a/pkg/api/testing/serialization_test.go +++ b/pkg/api/testing/serialization_test.go @@ -170,7 +170,7 @@ var nonRoundTrippableTypes = sets.NewString( var commonKinds = []string{"Status", "ListOptions", "DeleteOptions", "ExportOptions", "GetOptions", "CreateOptions", "UpdateOptions", "PatchOptions"} // TestCommonKindsRegistered verifies that all group/versions registered with -// the testapi package have the common kinds. +// the legacyscheme package have the common kinds. func TestCommonKindsRegistered(t *testing.T) { gvs := map[schema.GroupVersion]bool{} for gvk := range legacyscheme.Scheme.AllKnownTypes() { @@ -213,7 +213,7 @@ func TestCommonKindsRegistered(t *testing.T) { } // TestRoundTripTypes applies the round-trip test to all round-trippable Kinds -// in all of the API groups registered for test in the testapi package. +// in all of the API groups registered for test in the legacyscheme package. func TestRoundTripTypes(t *testing.T) { seed := rand.Int63() fuzzer := fuzzer.FuzzerFor(FuzzerFuncs, rand.NewSource(seed), legacyscheme.Codecs) diff --git a/pkg/apis/core/install/install_test.go b/pkg/apis/core/install/install_test.go index adc0c84e903..eec495baf0b 100644 --- a/pkg/apis/core/install/install_test.go +++ b/pkg/apis/core/install/install_test.go @@ -51,8 +51,6 @@ func TestResourceVersioner(t *testing.T) { func TestCodec(t *testing.T) { pod := internal.Pod{} - // We do want to use package registered rather than testapi here, because we - // want to test if the package install and package registered work as expected. data, err := runtime.Encode(legacyscheme.Codecs.LegacyCodec(schema.GroupVersion{Group: "", Version: "v1"}), &pod) if err != nil { t.Fatalf("unexpected error: %v", err) diff --git a/staging/publishing/import-restrictions.yaml b/staging/publishing/import-restrictions.yaml index d033a68c983..c9b96c82fbf 100644 --- a/staging/publishing/import-restrictions.yaml +++ b/staging/publishing/import-restrictions.yaml @@ -16,7 +16,6 @@ # Main goal: pkg/apis should be as self-contained as possible. - k8s.io/kubernetes/pkg/apis/apps - k8s.io/kubernetes/pkg/api/legacyscheme - - k8s.io/kubernetes/pkg/api/testapi - k8s.io/api/apps/v1 ignoredSubTrees: - "./pkg/apis/core/validation"