From 2b1b1adad0c6ea974eab0792d13b49679a0e66de Mon Sep 17 00:00:00 2001 From: Triona Doyle Date: Tue, 13 Aug 2024 12:55:03 +0100 Subject: [PATCH] empty --- test/e2e/suite_test.go | 14 +++++++++++--- test/nondefaulte2e/suite_test.go | 13 ++++++++++--- 2 files changed, 21 insertions(+), 6 deletions(-) diff --git a/test/e2e/suite_test.go b/test/e2e/suite_test.go index 4d59ff9c0..4b5b95a43 100644 --- a/test/e2e/suite_test.go +++ b/test/e2e/suite_test.go @@ -20,11 +20,13 @@ import ( "context" "os" "path/filepath" + "testing" "time" // Import all Kubernetes client auth plugins (e.g. Azure, GCP, OIDC, etc.) // to ensure that exec-entrypoint and run can make use of them. - argoapi "github.com/argoproj-labs/argocd-operator/api/v1beta1" + argov1alpha1api "github.com/argoproj-labs/argocd-operator/api/v1alpha1" + argov1beta1api "github.com/argoproj-labs/argocd-operator/api/v1beta1" argocdprovisioner "github.com/argoproj-labs/argocd-operator/controllers/argocd" monitoringv1 "github.com/coreos/prometheus-operator/pkg/apis/monitoring/v1" . "github.com/onsi/ginkgo" @@ -87,6 +89,12 @@ const ( interval = time.Millisecond * 250 ) +func TestAPIs(t *testing.T) { + + RegisterFailHandler(Fail) + RunSpecs(t, "Controller Suite") +} + var _ = BeforeSuite(func() { logf.SetLogger(zap.New(zap.WriteTo(GinkgoWriter), zap.UseDevMode(true))) @@ -110,7 +118,8 @@ var _ = BeforeSuite(func() { Expect(err).NotTo(HaveOccurred()) Expect(routev1.AddToScheme(scheme.Scheme)).NotTo(HaveOccurred()) - Expect(argoapi.AddToScheme(scheme.Scheme)).NotTo(HaveOccurred()) + Expect(argov1alpha1api.AddToScheme(scheme.Scheme)).NotTo(HaveOccurred()) + Expect(argov1beta1api.AddToScheme(scheme.Scheme)).NotTo(HaveOccurred()) Expect(monitoringv1.AddToScheme(scheme.Scheme)).NotTo(HaveOccurred()) Expect(operatorsv1.AddToScheme(scheme.Scheme)).NotTo(HaveOccurred()) Expect(operatorsv1alpha1.AddToScheme(scheme.Scheme)).NotTo(HaveOccurred()) @@ -119,7 +128,6 @@ var _ = BeforeSuite(func() { Expect(configv1.AddToScheme(scheme.Scheme)).NotTo(HaveOccurred()) Expect(templatev1.AddToScheme(scheme.Scheme)).NotTo(HaveOccurred()) Expect(appsv1.AddToScheme(scheme.Scheme)).NotTo(HaveOccurred()) - //+kubebuilder:scaffold:scheme k8sClient, err = client.New(cfg, client.Options{Scheme: scheme.Scheme}) diff --git a/test/nondefaulte2e/suite_test.go b/test/nondefaulte2e/suite_test.go index f0968bbc1..d749cccd2 100644 --- a/test/nondefaulte2e/suite_test.go +++ b/test/nondefaulte2e/suite_test.go @@ -21,11 +21,13 @@ import ( "os" "path/filepath" "strings" + "testing" "time" // Import all Kubernetes client auth plugins (e.g. Azure, GCP, OIDC, etc.) // to ensure that exec-entrypoint and run can make use of them. - argoapi "github.com/argoproj-labs/argocd-operator/api/v1beta1" + argov1alpha1api "github.com/argoproj-labs/argocd-operator/api/v1alpha1" + argov1beta1api "github.com/argoproj-labs/argocd-operator/api/v1beta1" argocdprovisioner "github.com/argoproj-labs/argocd-operator/controllers/argocd" monitoringv1 "github.com/coreos/prometheus-operator/pkg/apis/monitoring/v1" . "github.com/onsi/ginkgo" @@ -71,6 +73,11 @@ const ( interval = time.Millisecond * 250 ) +func TestAPIs(t *testing.T) { + RegisterFailHandler(Fail) + RunSpecs(t, "Controller Suite") +} + var _ = BeforeSuite(func() { logf.SetLogger(zap.New(zap.WriteTo(GinkgoWriter), zap.UseDevMode(true))) @@ -94,7 +101,6 @@ var _ = BeforeSuite(func() { Expect(err).NotTo(HaveOccurred()) Expect(routev1.AddToScheme(scheme.Scheme)).NotTo(HaveOccurred()) - Expect(argoapi.AddToScheme(scheme.Scheme)).NotTo(HaveOccurred()) Expect(monitoringv1.AddToScheme(scheme.Scheme)).NotTo(HaveOccurred()) Expect(operatorsv1.AddToScheme(scheme.Scheme)).NotTo(HaveOccurred()) Expect(operatorsv1alpha1.AddToScheme(scheme.Scheme)).NotTo(HaveOccurred()) @@ -103,7 +109,8 @@ var _ = BeforeSuite(func() { Expect(configv1.AddToScheme(scheme.Scheme)).NotTo(HaveOccurred()) Expect(templatev1.AddToScheme(scheme.Scheme)).NotTo(HaveOccurred()) Expect(appsv1.AddToScheme(scheme.Scheme)).NotTo(HaveOccurred()) - + Expect(argov1alpha1api.AddToScheme(scheme.Scheme)).NotTo(HaveOccurred()) + Expect(argov1beta1api.AddToScheme(scheme.Scheme)).NotTo(HaveOccurred()) //+kubebuilder:scaffold:scheme k8sClient, err = client.New(cfg, client.Options{Scheme: scheme.Scheme})