Skip to content

Commit

Permalink
empty
Browse files Browse the repository at this point in the history
  • Loading branch information
trdoyle81 committed Aug 13, 2024
1 parent 1f42107 commit 2b1b1ad
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 6 deletions.
14 changes: 11 additions & 3 deletions test/e2e/suite_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand Down Expand Up @@ -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)))

Expand All @@ -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())
Expand All @@ -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})
Expand Down
13 changes: 10 additions & 3 deletions test/nondefaulte2e/suite_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand Down Expand Up @@ -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)))

Expand All @@ -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())
Expand All @@ -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})
Expand Down

0 comments on commit 2b1b1ad

Please sign in to comment.