Skip to content

Commit

Permalink
FIX: istio e2e
Browse files Browse the repository at this point in the history
Kuadrant only expects one kuadrant CR on the cluster. Recent changes enforces the creation of only one authorino. This enforcement was causing the tests to fail as it was creating a second kuadrant CR that would never go to a ready state.

Signed-off-by: Jim Fitzpatrick <jfitzpat@redhat.com>
  • Loading branch information
Boomatang committed Sep 25, 2024
1 parent 5da981d commit f82f1fa
Showing 1 changed file with 5 additions and 13 deletions.
18 changes: 5 additions & 13 deletions tests/istio/kuadrant_controller_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ import (
var _ = Describe("Kuadrant controller on istio", func() {
var (
testNamespace string
kuadrantName = "local"
testTimeOut = SpecTimeout(2 * time.Minute)
afterEachTimeOut = NodeTimeout(3 * time.Minute)
)
Expand All @@ -32,19 +31,12 @@ var _ = Describe("Kuadrant controller on istio", func() {
tests.DeleteNamespace(ctx, testClient(), testNamespace)
}, afterEachTimeOut)

Context("when default kuadrant CR is created", func() {
Context("when test suite kuadrant CR exists on cluster", func() {
It("Status is ready", func(ctx SpecContext) {
kuadrantCR := &kuadrantv1beta1.Kuadrant{
TypeMeta: metav1.TypeMeta{
Kind: "Kuadrant",
APIVersion: kuadrantv1beta1.GroupVersion.String(),
},
ObjectMeta: metav1.ObjectMeta{
Name: kuadrantName,
Namespace: testNamespace,
},
}
Expect(testClient().Create(ctx, kuadrantCR)).ToNot(HaveOccurred())
kuadrantList := &kuadrantv1beta1.KuadrantList{}
Expect(testClient().List(ctx, kuadrantList)).ToNot(HaveOccurred())
Expect(len(kuadrantList.Items)).To(Equal(1))
kuadrantCR := &kuadrantList.Items[0]

Eventually(func(g Gomega) {
kObj := &kuadrantv1beta1.Kuadrant{}
Expand Down

0 comments on commit f82f1fa

Please sign in to comment.