Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pkg/controller/operators/olm/operator_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4030,7 +4030,7 @@ func TestUpdates(t *testing.T) {
csvsToSync = syncCSVs(csvsToSync, deletedCSVs(e.shouldBe))
current = csvsToSync[e.whenIn.name]
fmt.Printf("waiting for (when) %s to be %s\n", e.whenIn.name, e.whenIn.phase)
time.Sleep(1 * time.Millisecond)
time.Sleep(1 * time.Second)
}

// sync the other csvs until they're in the expected status
Expand Down
18 changes: 12 additions & 6 deletions test/e2e/subscription_e2e_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2597,14 +2597,20 @@ var _ = Describe("Subscription", func() {
err = magicCatalog.UpdateCatalog(context.Background(), provider)
Expect(err).To(BeNil())

By("waiting for the subscription to have v0.3.0 installed with a Package deprecated condition")
sub, err = fetchSubscription(crc, generatedNamespace.GetName(), subName, subscriptionHasCondition(
operatorsv1alpha1.SubscriptionPackageDeprecated,
corev1.ConditionTrue,
"",
"olm.package/test-package: test-package has been deprecated. Please switch to another-package."))
By("waiting for the subscription to have v0.3.0 installed")
sub, err = fetchSubscription(crc, generatedNamespace.GetName(), subName, subscriptionHasCurrentCSV("example-operator.v0.3.0"))
Expect(err).Should(BeNil())

By("waiting for the subscription to have v0.3.0 installed with a Package deprecated condition")
sub, err = fetchSubscription(crc, generatedNamespace.GetName(), subName,
subscriptionHasCondition(
operatorsv1alpha1.SubscriptionPackageDeprecated,
corev1.ConditionTrue,
"",
"olm.package/test-package: test-package has been deprecated. Please switch to another-package.",
),
)

By("checking for the deprecated conditions")
By(`Operator is deprecated at only Package and Channel levels`)
packageCondition := sub.Status.GetCondition(operatorsv1alpha1.SubscriptionPackageDeprecated)
Expand Down