diff --git a/pkg/model/resource/utils.go b/pkg/model/resource/utils.go index 3d8b858c8c4..fa012d570eb 100644 --- a/pkg/model/resource/utils.go +++ b/pkg/model/resource/utils.go @@ -56,17 +56,6 @@ func APIPackagePath(repo, group, version string, multiGroup bool) string { return path.Join(repo, "api", version) } -// APIPackagePathLegacy returns the default path -func APIPackagePathLegacy(repo, group, version string, multiGroup bool) string { - if multiGroup { - if group != "" { - return path.Join(repo, "apis", group, version) - } - return path.Join(repo, "apis", version) - } - return path.Join(repo, "api", version) -} - // RegularPlural returns a default plural form when none was specified func RegularPlural(singular string) string { return flect.Pluralize(strings.ToLower(singular)) diff --git a/pkg/model/resource/utils_test.go b/pkg/model/resource/utils_test.go index 9e1451a3217..85149225025 100644 --- a/pkg/model/resource/utils_test.go +++ b/pkg/model/resource/utils_test.go @@ -50,23 +50,6 @@ var _ = Describe("APIPackagePath", func() { ) }) -var _ = Describe("APIPackagePathLegacy", func() { - const ( - repo = "github.com/kubernetes-sigs/kubebuilder" - group = "group" - version = "v1" - ) - - DescribeTable("should work", - func(repo, group, version string, multiGroup bool, p string) { - Expect(APIPackagePathLegacy(repo, group, version, multiGroup)).To(Equal(p)) - }, - Entry("single group setup", repo, group, version, false, path.Join(repo, "api", version)), - Entry("multiple group setup", repo, group, version, true, path.Join(repo, "apis", group, version)), - Entry("multiple group setup with empty group", repo, "", version, true, path.Join(repo, "apis", version)), - ) -}) - var _ = DescribeTable("RegularPlural should return the regular plural form", func(singular, plural string) { Expect(RegularPlural(singular)).To(Equal(plural)) }, Entry("basic singular", "firstmate", "firstmates"), diff --git a/test/e2e/utils/test_context.go b/test/e2e/utils/test_context.go index d9c561edc5f..c726e21f826 100644 --- a/test/e2e/utils/test_context.go +++ b/test/e2e/utils/test_context.go @@ -126,8 +126,7 @@ func (t *TestContext) makePrometheusOperatorURL() string { return fmt.Sprintf(prometheusOperatorURL, prometheusOperatorVersion) } -// InstallCertManager installs the cert manager bundle. If hasv1beta1CRs is true, -// the legacy version (which uses v1alpha2 CRs) is installed. +// InstallCertManager installs the cert manager bundle. func (t *TestContext) InstallCertManager() error { url := t.makeCertManagerURL() if _, err := t.Kubectl.Apply(false, "-f", url, "--validate=false"); err != nil {