@@ -20,11 +20,13 @@ import (
2020 "context"
2121 "os"
2222 "path/filepath"
23+ "testing"
2324 "time"
2425
2526 // Import all Kubernetes client auth plugins (e.g. Azure, GCP, OIDC, etc.)
2627 // to ensure that exec-entrypoint and run can make use of them.
27- argoapi "github.com/argoproj-labs/argocd-operator/api/v1beta1"
28+ argov1alpha1api "github.com/argoproj-labs/argocd-operator/api/v1alpha1"
29+ argov1beta1api "github.com/argoproj-labs/argocd-operator/api/v1beta1"
2830 argocdprovisioner "github.com/argoproj-labs/argocd-operator/controllers/argocd"
2931 monitoringv1 "github.com/coreos/prometheus-operator/pkg/apis/monitoring/v1"
3032 . "github.com/onsi/ginkgo"
@@ -87,6 +89,12 @@ const (
8789 interval = time .Millisecond * 250
8890)
8991
92+ func TestAPIs (t * testing.T ) {
93+
94+ RegisterFailHandler (Fail )
95+ RunSpecs (t , "Controller Suite" )
96+ }
97+
9098var _ = BeforeSuite (func () {
9199 logf .SetLogger (zap .New (zap .WriteTo (GinkgoWriter ), zap .UseDevMode (true )))
92100
@@ -110,7 +118,8 @@ var _ = BeforeSuite(func() {
110118 Expect (err ).NotTo (HaveOccurred ())
111119
112120 Expect (routev1 .AddToScheme (scheme .Scheme )).NotTo (HaveOccurred ())
113- Expect (argoapi .AddToScheme (scheme .Scheme )).NotTo (HaveOccurred ())
121+ Expect (argov1alpha1api .AddToScheme (scheme .Scheme )).NotTo (HaveOccurred ())
122+ Expect (argov1beta1api .AddToScheme (scheme .Scheme )).NotTo (HaveOccurred ())
114123 Expect (monitoringv1 .AddToScheme (scheme .Scheme )).NotTo (HaveOccurred ())
115124 Expect (operatorsv1 .AddToScheme (scheme .Scheme )).NotTo (HaveOccurred ())
116125 Expect (operatorsv1alpha1 .AddToScheme (scheme .Scheme )).NotTo (HaveOccurred ())
@@ -119,7 +128,6 @@ var _ = BeforeSuite(func() {
119128 Expect (configv1 .AddToScheme (scheme .Scheme )).NotTo (HaveOccurred ())
120129 Expect (templatev1 .AddToScheme (scheme .Scheme )).NotTo (HaveOccurred ())
121130 Expect (appsv1 .AddToScheme (scheme .Scheme )).NotTo (HaveOccurred ())
122-
123131 //+kubebuilder:scaffold:scheme
124132
125133 k8sClient , err = client .New (cfg , client.Options {Scheme : scheme .Scheme })
0 commit comments