-
Notifications
You must be signed in to change notification settings - Fork 65
🌱 Update to catalogd v0.26.0 and update e2e tests #1237
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -231,7 +231,7 @@ func TestClusterExtensionInstallRegistry(t *testing.T) { | |
Catalog: &ocv1alpha1.CatalogSource{ | ||
PackageName: "prometheus", | ||
Selector: metav1.LabelSelector{ | ||
MatchLabels: map[string]string{"olm.operatorframework.io/name": extensionCatalog.Name}, | ||
MatchLabels: map[string]string{"olm.operatorframework.io/metadata.name": extensionCatalog.Name}, | ||
}, | ||
}, | ||
}, | ||
|
@@ -548,7 +548,7 @@ func TestClusterExtensionInstallReResolvesWhenCatalogIsPatched(t *testing.T) { | |
Selector: metav1.LabelSelector{ | ||
MatchExpressions: []metav1.LabelSelectorRequirement{ | ||
{ | ||
Key: "olm.operatorframework.io/name", | ||
Key: "olm.operatorframework.io/metadata.name", | ||
Operator: metav1.LabelSelectorOpIn, | ||
Values: []string{extensionCatalog.Name}, | ||
}, | ||
|
@@ -652,7 +652,7 @@ func TestClusterExtensionInstallReResolvesWhenNewCatalog(t *testing.T) { | |
Catalog: &ocv1alpha1.CatalogSource{ | ||
PackageName: "prometheus", | ||
Selector: metav1.LabelSelector{ | ||
MatchLabels: map[string]string{"olm.operatorframework.io/name": extensionCatalog.Name}, | ||
MatchLabels: map[string]string{"olm.operatorframework.io/metadata.name": extensionCatalog.Name}, | ||
}, | ||
}, | ||
}, | ||
|
@@ -713,8 +713,8 @@ func TestClusterExtensionInstallReResolvesWhenNewCatalog(t *testing.T) { | |
assert.Contains(ct, cond.Message, "resolved to") | ||
assert.Equal(ct, | ||
&ocv1alpha1.ClusterExtensionResolutionStatus{Bundle: &ocv1alpha1.BundleMetadata{ | ||
Name: "prometheus-operator.1.2.0", | ||
Version: "1.2.0", | ||
Name: "prometheus-operator.2.0.0", | ||
Version: "2.0.0", | ||
Comment on lines
+716
to
+717
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The original test seemed wrong. The catalog is updated to v2.0, but it remains as 1.2.0? That doesn't seem right. With the latest changes this now seems to be behaving as expected. |
||
}}, | ||
clusterExtension.Status.Resolution, | ||
) | ||
|
@@ -734,7 +734,7 @@ func TestClusterExtensionInstallReResolvesWhenManagedContentChanged(t *testing.T | |
Catalog: &ocv1alpha1.CatalogSource{ | ||
PackageName: "prometheus", | ||
Selector: metav1.LabelSelector{ | ||
MatchLabels: map[string]string{"olm.operatorframework.io/name": extensionCatalog.Name}, | ||
MatchLabels: map[string]string{"olm.operatorframework.io/metadata.name": extensionCatalog.Name}, | ||
}, | ||
}, | ||
}, | ||
|
@@ -806,7 +806,7 @@ func TestClusterExtensionRecoversFromInitialInstallFailedWhenFailureFixed(t *tes | |
Catalog: &ocv1alpha1.CatalogSource{ | ||
PackageName: "prometheus", | ||
Selector: metav1.LabelSelector{ | ||
MatchLabels: map[string]string{"olm.operatorframework.io/name": extensionCatalog.Name}, | ||
MatchLabels: map[string]string{"olm.operatorframework.io/metadata.name": extensionCatalog.Name}, | ||
}, | ||
}, | ||
}, | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -41,11 +41,13 @@ func TestMain(m *testing.M) { | |
// createTestCatalog will create a new catalog on the test cluster, provided | ||
// the context, catalog name, and the image reference. It returns the created catalog | ||
// or an error if any errors occurred while creating the catalog. | ||
// Note that catalogd will automatically create the label: | ||
// | ||
// "olm.operatorframework.io/metadata.name": name | ||
func createTestCatalog(ctx context.Context, name string, imageRef string) (*catalogd.ClusterCatalog, error) { | ||
catalog := &catalogd.ClusterCatalog{ | ||
ObjectMeta: metav1.ObjectMeta{ | ||
Name: name, | ||
Labels: map[string]string{"olm.operatorframework.io/name": name}, | ||
Comment on lines
-47
to
-48
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This label is now added automatically by v0.26.0 of catalogd |
||
Name: name, | ||
}, | ||
Spec: catalogd.ClusterCatalogSpec{ | ||
Source: catalogd.CatalogSource{ | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The deployment is updated with the latest cert secret, so this will wait for the rollout to complete, and the next step will ensure that it's ready.